Skip to content

Commit 0663377

Browse files
authored
properly deprecate legacy implementation -- bis (#5391)
* More deprecations * update message * typo
1 parent 93c85bb commit 0663377

File tree

2 files changed

+4
-3
lines changed

2 files changed

+4
-3
lines changed

torchvision/datasets/voc.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,8 @@ def __init__(
8080
if year == "2007-test":
8181
if image_set == "test":
8282
warnings.warn(
83-
"Acessing the test image set of the year 2007 with year='2007-test' is deprecated. "
83+
"Accessing the test image set of the year 2007 with year='2007-test' is deprecated "
84+
"since 0.12 and will be removed in 0.14. "
8485
"Please use the combination year='2007' and image_set='test' instead."
8586
)
8687
year = "2007"

torchvision/models/mobilenetv3.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -29,8 +29,8 @@ def __init__(self, input_channels: int, squeeze_factor: int = 4):
2929
self.relu = self.activation
3030
delattr(self, "activation")
3131
warnings.warn(
32-
"This SqueezeExcitation class is deprecated and will be removed in future versions. "
33-
"Use torchvision.ops.misc.SqueezeExcitation instead.",
32+
"This SqueezeExcitation class is deprecated since 0.12 and will be removed in 0.14. "
33+
"Use torchvision.ops.SqueezeExcitation instead.",
3434
FutureWarning,
3535
)
3636

0 commit comments

Comments
 (0)