Repository: pytorch/vision

Issue:
Links in documentation are out-of-date after master->main renaming
### 📚 The doc issue

The default brunch has been renamed to "main" but "master" is still being referenced in docs. For example:
https://github.com/pytorch/vision/blob/96f6e0a117d5c56f7e0237851dbb96144ebb110b/torchvision/transforms/transforms.py#L86
Beyond documentation, we should consider replacing "master" in code with "primary" or "main", for example:
https://github.com/pytorch/vision/blob/7947fc8fb38b1d3a2aca03f22a2e6a3caa63f2a0/references/classification/utils.py#L189-L191

### Suggest a potential alternative/fix

Replace "master" with "main" in links to torchvision repo.


Discussion:

Resolving patch:
diff --git a/gallery/plot_video_api.py b/gallery/plot_video_api.py
--- a/gallery/plot_video_api.py
+++ b/gallery/plot_video_api.py
@@ -35,7 +35,7 @@
 
 # Download the sample video
 download_url(
-    "https://github.com/pytorch/vision/blob/master/test/assets/videos/WUzgd7C1pWA.mp4?raw=true",
+    "https://github.com/pytorch/vision/blob/main/test/assets/videos/WUzgd7C1pWA.mp4?raw=true",
     ".",
     "WUzgd7C1pWA.mp4"
 )
@@ -187,26 +187,26 @@ def example_read_video(video_object, start=0, end=None, read_video=True, read_au
 # Download the videos
 from torchvision.datasets.utils import download_url
 download_url(
-    "https://github.com/pytorch/vision/blob/master/test/assets/videos/WUzgd7C1pWA.mp4?raw=true",
+    "https://github.com/pytorch/vision/blob/main/test/assets/videos/WUzgd7C1pWA.mp4?raw=true",
     "./dataset/1", "WUzgd7C1pWA.mp4"
 )
 download_url(
-    "https://github.com/pytorch/vision/blob/master/test/assets/videos/RATRACE_wave_f_nm_np1_fr_goo_37.avi?raw=true",
+    "https://github.com/pytorch/vision/blob/main/test/assets/videos/RATRACE_wave_f_nm_np1_fr_goo_37.avi?raw=true",
     "./dataset/1",
     "RATRACE_wave_f_nm_np1_fr_goo_37.avi"
 )
 download_url(
-    "https://github.com/pytorch/vision/blob/master/test/assets/videos/SOX5yA1l24A.mp4?raw=true",
+    "https://github.com/pytorch/vision/blob/main/test/assets/videos/SOX5yA1l24A.mp4?raw=true",
     "./dataset/2",
     "SOX5yA1l24A.mp4"
 )
 download_url(
-    "https://github.com/pytorch/vision/blob/master/test/assets/videos/v_SoccerJuggling_g23_c01.avi?raw=true",
+    "https://github.com/pytorch/vision/blob/main/test/assets/videos/v_SoccerJuggling_g23_c01.avi?raw=true",
     "./dataset/2",
     "v_SoccerJuggling_g23_c01.avi"
 )
 download_url(
-    "https://github.com/pytorch/vision/blob/master/test/assets/videos/v_SoccerJuggling_g24_c01.avi?raw=true",
+    "https://github.com/pytorch/vision/blob/main/test/assets/videos/v_SoccerJuggling_g24_c01.avi?raw=true",
     "./dataset/2",
     "v_SoccerJuggling_g24_c01.avi"
 )
diff --git a/torchvision/transforms/transforms.py b/torchvision/transforms/transforms.py
--- a/torchvision/transforms/transforms.py
+++ b/torchvision/transforms/transforms.py
@@ -83,7 +83,7 @@ class ToTensor:
         Because the input image is scaled to [0.0, 1.0], this transformation should not be used when
         transforming target image masks. See the `references`_ for implementing the transforms for image masks.
 
-    .. _references: https://github.com/pytorch/vision/tree/master/references/segmentation
+    .. _references: https://github.com/pytorch/vision/tree/main/references/segmentation
     """
 
     def __call__(self, pic):


Test patch: