os Path "FileNotFoundError: [Errno 2] No such file or directory:"

Question:

I’m trying to open files from this path C:UsersUsuarioLlamasllamas-pythonface but I’m getting FileNotFoundError: [Errno 2] No such file or directory:

  im1 = Image.open(f' ./llamas-python/face/{face_files[item["Face"]]}.png').convert('RGBA')

Any helpĀ”?

Asked By: dp Audiovisual

||

Answers:

Try something like

im1 = Image.open(f'.\llamas-python\face\{face_files[item["Face"]]}.png').convert('RGBA')
Answered By: Gabriele Iovino
Categories: questions Tags: , ,
Answers are sorted by their score. The answer accepted by the question owner as the best is marked with
at the top-right corner.