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

关于模型保存的问题 #32

Closed
mengyuan97 opened this issue Jul 14, 2021 · 3 comments
Closed

关于模型保存的问题 #32

mengyuan97 opened this issue Jul 14, 2021 · 3 comments
Labels
good first issue Good for newcomers see README.md Didn't follow the README.md

Comments

@mengyuan97
Copy link

作者您好!
在复现您的代码时,我发现之后最后3个epoch的model被保存,想请教您一下,如何能保存每个cycle的训练模型呢?

@mengyuan97
Copy link
Author

作者您好!
在复现您的代码时,我发现之后最后3个epoch的model被保存,想请教您一下,如何能保存每个cycle的训练模型呢?

此外还想请教一下,您config中test其实使用的是trainval的数据,用于计算不确定度。那么在使用tools/test.py进行测试的时候,是否就需要更改test为真正的测试集才行?

@yuantn
Copy link
Owner

yuantn commented Jul 15, 2021

作者您好!
在复现您的代码时,我发现之后最后3个epoch的model被保存,想请教您一下,如何能保存每个cycle的训练模型呢?

你好!

目前这套代码是可以保存每个 cycle 的训练模型的,其中 这里 提供了一个示例输出文件夹的网盘链接,你可以看一下。

如果你是想保存每个 epoch 的模型,你可以在 tools/train.py 中每个 epoch 训练结束时使用 torch.save() 函数进行保存。


Hello there!

At present, this repository can save the trained model for each cycle. Here is a link to the cloud drive of an example output folder, you can have a look .

If you want to save the model for each epoch, you can use the torch.save() function to save it at the end of each training epoch in tools/train.py.

@yuantn
Copy link
Owner

yuantn commented Jul 15, 2021

作者您好!
在复现您的代码时,我发现之后最后3个epoch的model被保存,想请教您一下,如何能保存每个cycle的训练模型呢?

此外还想请教一下,您config中test其实使用的是trainval的数据,用于计算不确定度。那么在使用tools/test.py进行测试的时候,是否就需要更改test为真正的测试集才行?

不是的,在这个代码中,我们测试时使用的是 test 集,但在 config 中使用的是 data.val 的部分。你可以看一下 这里


No, in this repository, we use the test set for test, but we use data.val in config. You can have a look here.

@yuantn yuantn added good first issue Good for newcomers see README.md Didn't follow the README.md labels Jul 16, 2021
@yuantn yuantn closed this as completed Aug 18, 2021
yuantn added a commit that referenced this issue Sep 17, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers see README.md Didn't follow the README.md
Projects
None yet
Development

No branches or pull requests

2 participants