Skip to content

🐍 Geometric Computer Vision Library for Spatial AI

Fix bug preventing sample wise augmentations (#1761)

Ashwin Nair66fd3b01bc3a
diff --git a/kornia/augmentation/container/utils.py b/kornia/augmentation/container/utils.py
index 7d4c1214c..469f40a81 100644
--- a/kornia/augmentation/container/utils.py
+++ b/kornia/augmentation/container/utils.py
@@ -100,7 +100,7 @@ class ApplyInverseImpl(ApplyInverseInterface):
# If any inputs need to be transformed.
if mat is not None and to_apply is not None and to_apply.sum() != 0 and input.numel() > 0:
- input[to_apply] = cls.apply_func(mat, input[to_apply])
+ input[to_apply] = cls.apply_func(mat[to_apply], input[to_apply])
return input, label