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

关于train_k_fold_cross_val.py的问题 #216

Open
justonli opened this issue Sep 16, 2022 · 1 comment
Open

关于train_k_fold_cross_val.py的问题 #216

justonli opened this issue Sep 16, 2022 · 1 comment

Comments

@justonli
Copy link

您好,我在运行train_k_fold_cross_val.py时,显示在 self.model.load_state_dict(torch.load(best_model_path))那里

报错AttributeError: 'NoneType' object has no attribute 'seek'. You can only torch.load from a file that is seekable. Please pre-load the data into a buffer like io.BytesIO and try to load from it instead.

我是换成自己数据集后运行报错的,使用原本的数据集时不会报错
我考虑过是为自己数据集的问题,但是在train.py里使用自己的数据集并不会报错,所以我想问下我要怎么解决这个报错问题呢,是新手所以不太懂怎样解决
谢谢

@whateverdude66
Copy link

请问解决了吗?我也遇到这个问题了,如果解决了能告知一下吗?谢谢!

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

2 participants