Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
vision
Commits
43030cb2
"vscode:/vscode.git/clone" did not exist on "2da2f1945ce5567e27d45df43acd4f65108d5c25"
Unverified
Commit
43030cb2
authored
Jul 03, 2023
by
Philip Meier
Committed by
GitHub
Jul 03, 2023
Browse files
remove center unsetting if expand=True (#7715)
parent
71968bc4
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
0 additions
and
2 deletions
+0
-2
torchvision/transforms/v2/functional/_geometry.py
torchvision/transforms/v2/functional/_geometry.py
+0
-2
No files found.
torchvision/transforms/v2/functional/_geometry.py
View file @
43030cb2
...
@@ -921,7 +921,6 @@ def rotate_image_pil(
...
@@ -921,7 +921,6 @@ def rotate_image_pil(
if
center
is
not
None
and
expand
:
if
center
is
not
None
and
expand
:
warnings
.
warn
(
"The provided center argument has no effect on the result if expand is True"
)
warnings
.
warn
(
"The provided center argument has no effect on the result if expand is True"
)
center
=
None
return
_FP
.
rotate
(
return
_FP
.
rotate
(
image
,
angle
,
interpolation
=
pil_modes_mapping
[
interpolation
],
expand
=
expand
,
fill
=
fill
,
center
=
center
image
,
angle
,
interpolation
=
pil_modes_mapping
[
interpolation
],
expand
=
expand
,
fill
=
fill
,
center
=
center
...
@@ -938,7 +937,6 @@ def rotate_bounding_box(
...
@@ -938,7 +937,6 @@ def rotate_bounding_box(
)
->
Tuple
[
torch
.
Tensor
,
Tuple
[
int
,
int
]]:
)
->
Tuple
[
torch
.
Tensor
,
Tuple
[
int
,
int
]]:
if
center
is
not
None
and
expand
:
if
center
is
not
None
and
expand
:
warnings
.
warn
(
"The provided center argument has no effect on the result if expand is True"
)
warnings
.
warn
(
"The provided center argument has no effect on the result if expand is True"
)
center
=
None
return
_affine_bounding_box_with_expand
(
return
_affine_bounding_box_with_expand
(
bounding_box
,
bounding_box
,
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment