AliaksandrSiarohin / first-order-model

This repository contains the source code for the paper First Order Motion Model for Image Animation
https://aliaksandrsiarohin.github.io/first-order-model-website/
MIT License
14.55k stars 3.22k forks source link

ModuleNotFoundError: No module named 'demo' #274

Open hemisemidemipresent opened 4 years ago

hemisemidemipresent commented 4 years ago

at the Create a model and load checkpoints cell, when ran this error occurred:

ModuleNotFoundError                       Traceback (most recent call last)
<ipython-input-2-dbd18151b569> in <module>()
----> 1 from demo import load_checkpoints
      2 generator, kp_detector = load_checkpoints(config_path='config/vox-256.yaml', 
      3                             checkpoint_path='/content/gdrive/My Drive/first-order-motion-model/vox-cpk.pth.tar')

ModuleNotFoundError: No module named 'demo'

---------------------------------------------------------------------------
NOTE: If your import is failing due to a missing package, you can
manually install dependencies using either !pip or !apt.

To view examples of installing some common dependencies, click the
"Open Examples" button below.
---------------------------------------------------------------------------

there is a demo.py file though, so how would you fix this?

AliaksandrSiarohin commented 4 years ago

You did not run all preciding cells, so you are in a wrong folder.

prostoziom321 commented 4 years ago

How is it. .Png file loaded .mp4 loaded. vox-cpk.pth.tar is named "firs-order-motion-model". This usually happens when the page is reloaded.

ModuleNotFoundError Traceback (most recent call last)

in () ----> 1 from demo import load_checkpoints 2 generator, kp_detector = load_checkpoints(config_path='config/vox-256.yaml', 3 checkpoint_path='/content/gdrive/My Drive/first-order-motion-model/vox-cpk.pth.tar') ModuleNotFoundError: No module named 'demo' --------------------------------------------------------------------------- NOTE: If your import is failing due to a missing package, you can manually install dependencies using either !pip or !apt. To view examples of installing some common dependencies, click the "Open Examples" button below. ---------------------------------------------------------------------------
allexradu commented 3 years ago

I've got this error when I was using improperly configured pycharm. The error wasn't in my code, it was in the IDE because I haven't updated the configuration settings, and the evirement variables where: "PYTHONUNBUFFERED=1;DJANGO_SETTINGS_MODULE=demo.settings"