Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

In train.py file #35

Open
atul2oct opened this issue Nov 4, 2020 · 9 comments
Open

In train.py file #35

atul2oct opened this issue Nov 4, 2020 · 9 comments

Comments

@atul2oct
Copy link

atul2oct commented Nov 4, 2020

Hello
You have done excellent and impressive work. Actually, I am new in machine learning and I was trying to run the code but I was facing problems. It would be grateful if you help me
my specs- i5 8300h , gtx 1050m ti 4 gb, ram 8 gb currently i am using this code on windows 10
if want to re-train a model using market 1501 dataset
error-
C:\Users\ATUL\Desktop\Python\Spatial-Temporal-Re-identification-master\model.py:14: UserWarning: nn.init.kaiming_normal is now deprecated in favor of nn.init.kaiming_normal_.
init.kaiming_normal(m.weight.data, a=0, mode='fan_out')
C:\Users\ATUL\Desktop\Python\Spatial-Temporal-Re-identification-master\model.py:15: UserWarning: nn.init.constant is now deprecated in favor of nn.init.constant_.
init.constant(m.bias.data, 0.0)
C:\Users\ATUL\Desktop\Python\Spatial-Temporal-Re-identification-master\model.py:17: UserWarning: nn.init.normal is now deprecated in favor of nn.init.normal_.
init.normal(m.weight.data, 1.0, 0.02)
C:\Users\ATUL\Desktop\Python\Spatial-Temporal-Re-identification-master\model.py:18: UserWarning: nn.init.constant is now deprecated in favor of nn.init.constant_.
init.constant(m.bias.data, 0.0)
C:\Users\ATUL\Desktop\Python\Spatial-Temporal-Re-identification-master\model.py:23: UserWarning: nn.init.normal is now deprecated in favor of nn.init.normal_.
init.normal(m.weight.data, std=0.001)
C:\Users\ATUL\Desktop\Python\Spatial-Temporal-Re-identification-master\model.py:24: UserWarning: nn.init.constant is now deprecated in favor of nn.init.constant_.
init.constant(m.bias.data, 0.0)
net output size:
torch.Size([8, 751])
0
[Resize(size=(288, 144), interpolation=PIL.Image.BICUBIC), RandomCrop(size=(256, 128), padding=None), RandomHorizontalFlip(p=0.5), ToTensor(), Normalize(mean=[0.485, 0.456, 0.406], std=[0.229, 0.224, 0.225]), <random_erasing.RandomErasing object at 0x000001CD467C78B0>]

Traceback (most recent call last):
File "", line 1, in
File "C:\Users\ATUL\Anaconda3\lib\multiprocessing\spawn.py", line 116, in spawn_main
exitcode = _main(fd, parent_sentinel)
File "C:\Users\ATUL\Anaconda3\lib\multiprocessing\spawn.py", line 125, in _main
prepare(preparation_data)
File "C:\Users\ATUL\Anaconda3\lib\multiprocessing\spawn.py", line 236, in prepare
_fixup_main_from_path(data['init_main_from_path'])
File "C:\Users\ATUL\Anaconda3\lib\multiprocessing\spawn.py", line 287, in _fixup_main_from_path
main_content = runpy.run_path(main_path,
File "C:\Users\ATUL\Anaconda3\lib\runpy.py", line 265, in run_path
return _run_module_code(code, init_globals, run_name,
File "C:\Users\ATUL\Anaconda3\lib\runpy.py", line 97, in _run_module_code
_run_code(code, mod_globals, init_globals,
File "C:\Users\ATUL\Anaconda3\lib\runpy.py", line 87, in _run_code
exec(code, run_globals)
File "C:\Users\ATUL\Desktop\Python\Spatial-Temporal-Re-identification-master\train_market.py", line 20, in
from model import ft_net, ft_net_dense, PCB
ModuleNotFoundError: No module named 'model'

@Wanggcong
Copy link
Owner

---ModuleNotFoundError: No module named 'model'
-- Check if you import the model.

@atul2oct
Copy link
Author

atul2oct commented Nov 5, 2020

---ModuleNotFoundError: No module named 'model'
-- Check if you import the model.

i don't change any code.
does module 'model' have to be download? and what is path dir for model?
model folder is empty
i have executed prepare.py successfully that created dataset now i am tring to run train file
i have installed pytorch using " conda install pytorch torchvision torchaudio cudatoolkit=10.2 -c pytorch "
what else are required to download?
i have just started learning deep learning appreciated for your support

@atul2oct
Copy link
Author

atul2oct commented Nov 5, 2020 via email

@Wanggcong
Copy link
Owner

---ModuleNotFoundError: No module named 'model'
-- Check if you import the model.

i don't change any code.
does module 'model' have to be download? and what is path dir for model?
model folder is empty
i have executed prepare.py successfully that created dataset now i am tring to run train file
i have installed pytorch using " conda install pytorch torchvision torchaudio cudatoolkit=10.2 -c pytorch "
what else are required to download?
i have just started learning deep learning appreciated for your support

This error is caused by python, not deep learning. First, you have to check if there exists a "model.py" file in your folder. If yes, you may try both python2 and python 3.

@atul2oct
Copy link
Author

atul2oct commented Nov 6, 2020 via email

@atul2oct
Copy link
Author

atul2oct commented Nov 6, 2020 via email

@atul2oct
Copy link
Author

atul2oct commented Nov 6, 2020 via email

@Wanggcong
Copy link
Owner

I am sorry that I really do not know your questions and the corresponding solutions.

@KarimBashamutala
Copy link

---ModuleNotFoundError: No module named 'model' -- Check if you import the model.

Modulation rrp code ^8.
Modulation rpc code ^9.
Modulation crp.
Error.
Data.
...gc.
...in. __
...cr.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants