From bbbb97e4634460a056be70829607b73412a53e80 Mon Sep 17 00:00:00 2001 From: pytorchbot Date: Mon, 13 Jan 2025 11:34:48 +0000 Subject: [PATCH] 2025-01-13 nightly release (06a925c32b49fd0455e265097fa7ca623cec4154) --- docs/source/models.rst | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/docs/source/models.rst b/docs/source/models.rst index 53e8d87609e..d0096aaf854 100644 --- a/docs/source/models.rst +++ b/docs/source/models.rst @@ -172,7 +172,11 @@ Most pre-trained models can be accessed directly via PyTorch Hub without having model = torch.hub.load("pytorch/vision", "resnet50", weights="IMAGENET1K_V2") # Option 2: passing weights param as enum - weights = torch.hub.load("pytorch/vision", "get_weight", weights="ResNet50_Weights.IMAGENET1K_V2") + weights = torch.hub.load( + "pytorch/vision", + "get_weight", + weights="ResNet50_Weights.IMAGENET1K_V2", + ) model = torch.hub.load("pytorch/vision", "resnet50", weights=weights) You can also retrieve all the available weights of a specific model via PyTorch Hub by doing: