You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Remove dangling comma from save/load example (#3593)
The tutorial currently loads a tuple of shape `(1,)` into `model`, which
appears to be a typo:
```python
model = torch.load('model.pth', weights_only=False),
```
This PR removes the comma so that `model` is actually a `Module`.
Co-authored-by: Svetlana Karslioglu <[email protected]>
# .. note:: This approach uses Python `pickle <https://docs.python.org/3/library/pickle.html>`_ module when serializing the model, thus it relies on the actual class definition to be available when loading the model.
0 commit comments