Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[NOMERGE] drop in transforms v2 into the v1 tests #7159
base: main
Are you sure you want to change the base?
[NOMERGE] drop in transforms v2 into the v1 tests #7159
Changes from 29 commits
0305a4d
7e032ad
4d670ef
99bc85f
d0affa2
3864496
23655f4
d185946
5f2978d
44aac11
3f3ad5b
136f7e0
c1c626a
df081f9
8bd6e3c
3ec22ef
1194a01
132c1cd
892b50b
4688a38
739ac02
95baeab
4915482
057bca5
e747ba4
fbc0497
f6592f4
4e0ae59
cd19f40
2b218ec
729bd72
6c803e0
1b58362
a4e8838
699529a
a3b7cc5
3749cad
adfdb4d
b54257c
2dfff2b
6768182
dd5a564
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right now it should be
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@vfdev-5 and I discussed offline and our answer is no. As explained in #6517,
fill=None
andfill=0
is not the same. However, some v1 transforms (the three highlighted here) simply coerceNone
into0
:vision/torchvision/transforms/transforms.py
Lines 1338 to 1339 in 55d3ba6
AFAIK this behavior is undocumented. In v2 we pass through
None
values:vision/torchvision/transforms/v2/_utils.py
Lines 56 to 61 in 55d3ba6
Note that in both cases,
fill=None
is not the default valuevision/torchvision/transforms/transforms.py
Line 1321 in 55d3ba6
vision/torchvision/transforms/v2/_geometry.py
Line 333 in 55d3ba6
So v1 is silently ignoring user input, while v2 doesn't.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right now, this assertion should be