You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It would be good to be able to register custom transform kernels in v2.function.
Motivation, pitch
If I want to register the transform's kernel, which is incompatible with built-in torchvision transforms and the functional API, and which uses built-in tv_tensor classes, it will be blocked by checking if it is from built-in function.
馃殌 The feature
It would be good to be able to register custom transform kernels in
v2.function
.Motivation, pitch
If I want to register the transform's kernel, which is incompatible with built-in torchvision transforms and the functional API, and which uses built-in tv_tensor classes, it will be blocked by checking if it is from built-in function.
vision/torchvision/transforms/v2/functional/_utils.py
Lines 77 to 84 in 6a9b549
vision/torchvision/transforms/v2/functional/_utils.py
Lines 92 to 93 in 6a9b549
It would be more flexible if registering incompatible custom transform kernel is possible.
Alternatives
I tried to use
@F._utils._register_kernel_internal
instead, and it works.But I think it could not be a safe way.
Additional context
No response
The text was updated successfully, but these errors were encountered: