inr-gan
inr-gan copied to clipboard
`ModuleNotFoundError` when importing modules in `src`.
Hi. thank you for your great work.
As you intended, src/infra/launch_local.py
changes the directory to experiments/my_experiment
and trains the model. However, I encountered ModuleNotFoundError
at line 24
and line 25
in src/training/training_loop.py
. After I changed the lines, everything goes fine. The problem kept occurring even when I added experiments/my_experiment
to sys.path
. I wonder that this problem didn't occur in your case.
Thanks again and stay safe.
Best Wishes, Lee
Hi, Lee! Could you please tell how exactly you change the lines 24
and 25
? Do you change them by removing the src
prefix? I.e., from:
import src.legacy
from src.metrics import metric_main
to:
import legacy
from metrics import metric_main
?
This looks like a problem with PYTHON_PATH
. Does this problem occur when you launch the training via src/infra/launch_local.py
or when you launch/relaunch it manually after the directory had been already created?
Yes, it's correct. It occurs when I run the training via python src/infra/launch_local.py
as in README.md
.