Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Supported by

No such file or directory error for images in the file pool

Hello,


I want to present 6 rectangles on the canvas so that they do not overlap each other, and then the photos that will appear in the same position as these rectangles. 5 of these photos will come from one list and 1 from another list. But the code I wrote is not working. Even though I have added the photos to the file pool, I am getting the photo not found error. What would be the reason? Thanks in advance.


Kind regards,


Error code:

  File "C:\Program Files (x86)\OpenSesame\Lib\site-packages\libopensesame\inline_script.py", line 92, in prepare

   self.workspace._exec(self.cprepare)

  File "C:\Program Files (x86)\OpenSesame\Lib\site-packages\libopensesame\base_python_workspace.py", line 124, in _exec

   exec(bytecode, self._globals)

  Inline script, line 62, in <module>

  File "C:\Program Files (x86)\OpenSesame\Lib\site-packages\PIL\Image.py", line 2809, in open

   fp = builtins.open(filename, "rb")

FileNotFoundError: [Errno 2] No such file or directory: 'high_1.jpg'

Comments

  • Hi @bssengul,

    It is not clear frmo your description what the issue may be (not sure what you mena by lists, or example). You may want to check that the jpg filename you are calling is spelled exactly as the filename (case sensitive). Can you upload your task to this forum?

    Fabrice.

    Buy Me A Coffee

  • Hey, thank you for your reply. It was a kind of coding error. I handled it.


    Thank you so much!

    Best regards,

    Beril.

Sign In or Register to comment.