NNNNAI / VGGFace2-HQ

A high resolution face dataset for face editing purpose
Other
407 stars 32 forks source link

Could not load library cudnn_ops_infer64_8.dll #2

Closed bmc84 closed 2 years ago

bmc84 commented 2 years ago

Hi,

Command: python scripts/crop_align_vggface2_FFHQalign.py --input_dir /in --output_dir_ffhqalign /out --mode ffhq --crop_size 256

Gives error: _Could not load library cudnn_ops_infer64_8.dll. Error code 126 Please make sure cudnn_ops_infer648.dll is in your library path!

cudnn_ops_infer64_8.dll is definitely there. I cloned my SimSwap environment, then "pip install"ed the extra requirements.

Any idea why this does not work?

NNNNAI commented 2 years ago

Did you install the onnxruntime-gpu? The problem may be caused by the failure to install onnxruntime-gpu. Try pip uninstall onnxruntime-gpu first, and then run the command again to check whether the operation succeeds.

bmc84 commented 2 years ago

Ok thanks it seems to work now.

It finds 3 images in my IN folder. but then in the OUT folder, it creates 3 folders with the names of the input files, but nothing is in them?

image

NNNNAI commented 2 years ago

Becasuse crop_align_vggface2_FFHQalign.py is designed for VGGface2. What this code expects is that the folder you copy to --input_dir should have many subfolders, each with many pictures. The code will process all the images in the subfolders. But you don't have any subfolders in your case. You can do this by creating a new folder in IN folder, putting all three images in the new folder, and then leaving the command line unchanged.

bmc84 commented 2 years ago

Ok.

I now have IN\SUB_FOLDER and IN\SUB_FOLDER_2 each with 3 images: image

I then run command: python scripts/crop_align_vggface2_FFHQalign.py --input_dir in --output_dir_ffhqalign out --mode ffhq --crop_size 256

image

but in OUT folder, there are no files image

Why would this be? The faces are definitely "detectable" - they were found & generated by SimSwap.

NNNNAI commented 2 years ago

Is the the height and width of images in IN subfolder both bigger than 250?

NNNNAI commented 2 years ago

Insert "print(image_file)" at the line 30 of crop_align_vggface2_FFHQalign.py, and let me see the log in the terminal.

NNNNAI commented 2 years ago

I found the problem, try this new crop_align_vggface2_FFHQalign.py. And it should work now. crop_align_vggface2_FFHQalign.zip

bmc84 commented 2 years ago

It works now! Thank you so much.