We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8878e03 commit d8043a9Copy full SHA for d8043a9
torchvision/models/detection/transform.py
@@ -40,7 +40,7 @@ def _resize_image_and_masks(
40
if fixed_size is not None:
41
size = [fixed_size[1], fixed_size[0]]
42
else:
43
- if torch.jit.is_scripting():
+ if torch.jit.is_scripting() or torchvision._is_tracing():
44
min_size = torch.min(im_shape).to(dtype=torch.float32)
45
max_size = torch.max(im_shape).to(dtype=torch.float32)
46
self_min_size_f = float(self_min_size)
0 commit comments