Commit 3c811bc
authored
Save multiple checkpoints per epoch (#509)
<!-- markdownlint-disable -->
PLEASE FILL IN THE PR DESCRIPTION HERE ENSURING ALL CHECKLIST ITEMS (AT
THE BOTTOM) HAVE BEEN CONSIDERED.
## Purpose
Save multiple checkpoints per epoch
<!--- Why your changes are needed -->
## Description
updated `checkpoint_freq` to float, setting it to 0.5 would mean save
twice per epoch to the same directory by overwriting. We skip the last
saving right before validation since it's handled separately. (Or should
it?) When checkpoint_freq > 1 it should be an int and we save per
multiple epochs.
<!--- High-level concise summary of changes -->
## Related Issue
<!--- Link related issue if applicable -->
#493
## Tests
Tested locally with an example.
<!--- Please describe in detail how you tested your changes. -->
I have filled in:
- [x] The purpose of the PR, such as "Fix some issue (link existing
issues this PR will resolve)".
- [x] The test plan/results, such as providing test command and pasting
the results.
- [ ] (Optional) The necessary documentation update.
- [x] I (a human) have written or reviewed the code in this pr to the
best of my ability.
---------
Signed-off-by: shanjiaz <zsjwpianpian@gmail.com>1 parent 2979b8a commit 3c811bc
2 files changed
Lines changed: 36 additions & 11 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
383 | 383 | | |
384 | 384 | | |
385 | 385 | | |
386 | | - | |
387 | | - | |
388 | | - | |
389 | | - | |
390 | | - | |
| 386 | + | |
| 387 | + | |
| 388 | + | |
| 389 | + | |
| 390 | + | |
| 391 | + | |
| 392 | + | |
| 393 | + | |
| 394 | + | |
| 395 | + | |
391 | 396 | | |
392 | 397 | | |
393 | 398 | | |
| |||
632 | 637 | | |
633 | 638 | | |
634 | 639 | | |
635 | | - | |
636 | | - | |
| 640 | + | |
| 641 | + | |
| 642 | + | |
637 | 643 | | |
638 | 644 | | |
639 | 645 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| 32 | + | |
32 | 33 | | |
33 | 34 | | |
34 | 35 | | |
| |||
44 | 45 | | |
45 | 46 | | |
46 | 47 | | |
47 | | - | |
| 48 | + | |
48 | 49 | | |
49 | 50 | | |
50 | 51 | | |
| |||
191 | 192 | | |
192 | 193 | | |
193 | 194 | | |
194 | | - | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
195 | 202 | | |
196 | 203 | | |
197 | 204 | | |
| |||
229 | 236 | | |
230 | 237 | | |
231 | 238 | | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
232 | 248 | | |
233 | 249 | | |
234 | 250 | | |
| |||
271 | 287 | | |
272 | 288 | | |
273 | 289 | | |
274 | | - | |
| 290 | + | |
| 291 | + | |
275 | 292 | | |
276 | 293 | | |
277 | 294 | | |
| |||
294 | 311 | | |
295 | 312 | | |
296 | 313 | | |
297 | | - | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
298 | 317 | | |
299 | 318 | | |
300 | 319 | | |
| |||
0 commit comments