update readme
parent
2f9d3dcaa1
commit
85a9bb2d40
|
@ -173,6 +173,8 @@ param_groups = [
|
|||
# that has two components (base and classifier). Modify the code to adapt to your model.
|
||||
optimizer = torch.optim.Adam(param_groups, lr=args.lr, weight_decay=args.weight_decay)
|
||||
```
|
||||
Of course, you can pass `model.classifier.parameters()` to optimizer if you only need to train the classifier (in this case, setting the `requires_grad` wrt the base model to false will be more efficient).
|
||||
|
||||
|
||||
## References
|
||||
[1] [He et al. Deep Residual Learning for Image Recognition. CVPR 2016.](https://arxiv.org/abs/1512.03385)<br />
|
||||
|
|
Loading…
Reference in New Issue