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

OSError: [Errno 22] Invalid argument #16

Closed
GreatBruceYoung opened this issue Jul 3, 2020 · 1 comment
Closed

OSError: [Errno 22] Invalid argument #16

GreatBruceYoung opened this issue Jul 3, 2020 · 1 comment

Comments

@GreatBruceYoung
Copy link

Traceback (most recent call last): File "main.py", line 312, in <module> display=viz) File "C:\Users\yang6\PycharmProjects\DeepHyperX\models.py", line 1059, in train save_model(net, camel_to_snake(str(net.__class__.__name__)), data_loader.dataset.name, epoch=e, metric=abs(metric)) File "C:\Users\yang6\PycharmProjects\DeepHyperX\models.py", line 1068, in save_model torch.save(model.state_dict(), model_dir + filename + '.pth') File "C:\Users\yang6\Anaconda3\envs\DeepHyperX\lib\site-packages\torch\serialization.py", line 260, in save return _with_file_like(f, "wb", lambda f: _save(obj, f, pickle_module, pickle_protocol)) File "C:\Users\yang6\Anaconda3\envs\DeepHyperX\lib\site-packages\torch\serialization.py", line 183, in _with_file_like f = open(f, mode) **OSError: [Errno 22] Invalid argument: './checkpoints/hamida_et_al/PaviaU/2020-07-03 10:52:46.094626_epoch2_0.78.pth'**

I am very confused about this error. How to solve it?

@zhuwenxaing
Copy link

did you run this project in widows? if so, please check there is a space in the path './checkpoints/hamida_et_al/PaviaU/2020-07-03 10:52:46.094626_epoch2_0.78.pth'.

@nshaud nshaud closed this as completed Oct 12, 2020
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