Skip to content

Commit

Permalink
Merge branch 'main' into please_dont_modify_this_branch_unless_you_ar…
Browse files Browse the repository at this point in the history
…e_just_merging_with_main_
  • Loading branch information
NicolasHug authored May 30, 2024
2 parents 311d448 + b0f9f7b commit a861bab
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions torchvision/transforms/v2/functional/_geometry.py
Original file line number Diff line number Diff line change
Expand Up @@ -194,7 +194,7 @@ def resize(
# according to our benchmarks on eager, non-AVX CPUs should still prefer u8->f32->interpolate->u8 path for bilinear
def _do_native_uint8_resize_on_cpu(interpolation: InterpolationMode) -> bool:
if interpolation == InterpolationMode.BILINEAR:
if torch._dynamo.is_compiling():
if torch.compiler.is_compiling():
return True
else:
return "AVX2" in torch.backends.cpu.get_cpu_capability()
Expand Down Expand Up @@ -525,7 +525,7 @@ def _get_inverse_affine_matrix(


def _compute_affine_output_size(matrix: List[float], w: int, h: int) -> Tuple[int, int]:
if torch._dynamo.is_compiling() and not torch.jit.is_scripting():
if torch.compiler.is_compiling() and not torch.jit.is_scripting():
return _compute_affine_output_size_python(matrix, w, h)
else:
return _compute_affine_output_size_tensor(matrix, w, h)
Expand Down

0 comments on commit a861bab

Please sign in to comment.