prototypical-networks icon indicating copy to clipboard operation
prototypical-networks copied to clipboard

ModuleNotFoundError: No module named 'protonets.utils'

Open Chibuikem709 opened this issue 5 years ago • 3 comments

Hello!

I am trying to replicate this experiment, but when I run the following command: python scripts/train/few_shot/run_train.py --data.cuda --log.exp_dir results

I get the following error:

Traceback (most recent call last): File "scripts/train/few_shot/run_train.py", line 3, in <module> from train import main File "/gpfs/data/lcrawfo1/cnwizu/PythonSandbox/prototypical-networks-master/scripts/train/few_shot/train.py", line 16, in <module> import protonets.utils.data as data_utils ModuleNotFoundError: No module named 'protonets.utils'

I followed the readme exactly. What is the solution?

Thanks in advance!

Chibuikem709 avatar Oct 10 '19 04:10 Chibuikem709

Hello!

I am trying to replicate this experiment, but when I run the following command: python scripts/train/few_shot/run_train.py --data.cuda --log.exp_dir results

I get the following error:

Traceback (most recent call last): File "scripts/train/few_shot/run_train.py", line 3, in <module> from train import main File "/gpfs/data/lcrawfo1/cnwizu/PythonSandbox/prototypical-networks-master/scripts/train/few_shot/train.py", line 16, in <module> import protonets.utils.data as data_utils ModuleNotFoundError: No module named 'protonets.utils'

I followed the readme exactly. What is the solution?

Thanks in advance!

I think you may need to edit the setup.py file: change the command line "packages=['protonets']" into "packages=['protonets', 'protonets.utils', 'protonets.data', 'protonets.models']"

SherryWang00 avatar Nov 28 '19 07:11 SherryWang00

I am meeting the same problem, have you solved it?

Ha0Tang avatar Dec 27 '19 17:12 Ha0Tang

I am meeting the same problem, have you solved it?

Yeah,,, I made it work by editting the setup.py file: change the command line "packages=['protonets']" into "packages=['protonets', 'protonets.utils', 'protonets.data', 'protonets.models']".

SherryWang00 avatar Dec 29 '19 04:12 SherryWang00