Open sridhar9999 opened 4 years ago
Make sure you have followed the Windows Installation Guide, especially the part where they set the PYTHONPATH.
The PYTHONPATH will allow python to see FSGAN and face_detection_dsfd as imports.
It is a required step. If this doesn't fix your issue I am happy to help!
I have same problem on colab
Traceback (most recent call last): File "face_swap_images2images.py", line 11, in <module> import fsgan.data.landmark_transforms as landmark_transforms ModuleNotFoundError: No module named 'fsgan'
import sys sys.path += ['/content/projects']
doesnt work for me my sys.path
['', '/env/python', '/usr/lib/python36.zip', '/usr/lib/python3.6', '/usr/lib/python3.6/lib-dynload', '/usr/local/lib/python3.6/dist-packages', '/usr/lib/python3/dist-packages', '/usr/local/lib/python3.6/dist-packages/IPython/extensions', '/root/.ipython', '/usr/local/lib/python3.7/site-packages', '/content/projects']
I had the same problem and I fixed it with this answer: https://stackoverflow.com/questions/16913086/ubuntu-add-directory-to-python-path
By making a .bash_profile
file in my home directory (linux) and adding these lines to it
PYTHONPATH=$PYTHONPATH:/data/dev/projects
EXPORT $PYTHONPATH
projects\fsgan\inference>python swap.py D:\deepfake\data\s.mp4 -t D:\deepfake\data\t.mp4 -o D:\deepfake\data\ssssssss.mp4 Traceback (most recent call last): File "swap.py", line 25, in
from fsgan.preprocess.preprocess_video import VideoProcessBase, base_parser
ModuleNotFoundError: No module named 'fsgan'
(base) D:\deepfake\data\dev\projects\fsgan\inference>
when i run the code it gives me error like this any help
same thing showing on colab too