π Geometric Computer Vision Library for Spatial AI
Python artificial-intelligencecomputer-visiondeep-learninghacktoberfestimage-processingmachine-learningneural-networkpythonpytorchroboticsspatial-ai
Add gradcheck for RandomVerticalFlip (#3476)
Soumita Dasb0900e482c53
diff --git a/tests/augmentation/test_augmentation.py b/tests/augmentation/test_augmentation.pyindex 564c894b7..1173f908a 100644--- a/tests/augmentation/test_augmentation.py+++ b/tests/augmentation/test_augmentation.py@@ -1214,6 +1214,11 @@ class TestRandomVerticalFlip(BaseTester):input[..., input_coordinates[0, 1, :], input_coordinates[0, 0, :]],)+ @pytest.mark.slow+ def test_gradcheck(self, device):+ input = torch.rand((3, 3), device=device, dtype=torch.float64)+ self.gradcheck(RandomVerticalFlip(p=1.0), (input,))+class TestColorJiggle(BaseTester):# TODO: improve and implement more meaningful smoke tests e.g check for a consistent