Skip to content

Commit

Permalink
Merge #1762
Browse files Browse the repository at this point in the history
1762: Doc update (saving.md): removed outdated info; Typo fix. r=DhairyaLGandhi a=NightMachinary



Co-authored-by: NightMachinary <[email protected]>
  • Loading branch information
bors[bot] and NightMachinery authored Nov 7, 2021
2 parents ea26f45 + 9b716fc commit 1c6edbc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ One of the best ways to contribute is by looking at issues labeled ["help wanted

## Good First Issues

While there are not many right now, we do have a section for ["good for issues"](https://github.com/FluxML/Flux.jl/labels/good%20first%20issue). As mentioned above, if any of these seem interesting but there is no clear next step in your mind, please feel free to ask for a suggested step. Often times in open source, issues labeled as "good first issue" actually take some back and forth between maintainers and contributors before the issues is ready to be tackled by a new contributor.
While there are not many right now, we do have a section for ["good first issues"](https://github.com/FluxML/Flux.jl/labels/good%20first%20issue). As mentioned above, if any of these seem interesting but there is no clear next step in your mind, please feel free to ask for a suggested step. Often times in open source, issues labeled as "good first issue" actually take some back and forth between maintainers and contributors before the issues is ready to be tackled by a new contributor.

## Model Zoo

Expand Down
8 changes: 1 addition & 7 deletions docs/src/saving.md
Original file line number Diff line number Diff line change
Expand Up @@ -118,10 +118,4 @@ revert to an older copy of the model if it starts to overfit.
@save "model-$(now()).bson" model loss = testloss()
```

You can even store optimiser state alongside the model, to resume training
exactly where you left off.

```julia
opt = ADAM()
@save "model-$(now()).bson" model opt
```
Note that to resume a model's training, you might need to restore other stateful parts of your training loop. Possible examples are stateful optimizers (which usually utilize an `IdDict` to store their state, which is not automatically handled by `BSON`), and the randomness used to partition the original data into the training and validation sets.

0 comments on commit 1c6edbc

Please sign in to comment.