Unverified Commit 0daffad3 authored by Philip Meier's avatar Philip Meier Committed by GitHub
Browse files

Cleanup for e2e gallery example for transforms v2 (#7318)

parent 31a4ef9f
...@@ -62,6 +62,7 @@ sphinx_gallery_conf = { ...@@ -62,6 +62,7 @@ sphinx_gallery_conf = {
"gallery_dirs": "auto_examples", # path to where to save gallery generated output "gallery_dirs": "auto_examples", # path to where to save gallery generated output
"backreferences_dir": "gen_modules/backreferences", "backreferences_dir": "gen_modules/backreferences",
"doc_module": ("torchvision",), "doc_module": ("torchvision",),
"remove_config_comments": True,
} }
napoleon_use_ivar = True napoleon_use_ivar = True
......
""" """
================================================== ==================================================
transforms v2: End-to-end object detection example Transforms v2: End-to-end object detection example
================================================== ==================================================
Object detection is not supported out of the box by ``torchvision.transforms`` v1, since it only supports images. Object detection is not supported out of the box by ``torchvision.transforms`` v1, since it only supports images.
...@@ -20,7 +20,6 @@ import torch.utils.data ...@@ -20,7 +20,6 @@ import torch.utils.data
import torchvision import torchvision
# sphinx_gallery_thumbnail_number = -1
def show(sample): def show(sample):
import matplotlib.pyplot as plt import matplotlib.pyplot as plt
...@@ -125,6 +124,7 @@ dataset = datasets.wrap_dataset_for_transforms_v2(dataset) ...@@ -125,6 +124,7 @@ dataset = datasets.wrap_dataset_for_transforms_v2(dataset)
torch.manual_seed(3141) torch.manual_seed(3141)
sample = dataset[0] sample = dataset[0]
# sphinx_gallery_thumbnail_number = 2
show(sample) show(sample)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment