Thank you! We'll be in touch ASAP.
Something went wrong, please try again or contact us directly at contact@dagshub.com
Deci-AI:master
deci-ai:feature/sg-000_connect_to_lab
import torch import unittest from super_gradients.training.datasets.data_augmentation import RandomErase class RandomEraseTest(unittest.TestCase): def test_random_erase(self): dummy_input = torch.randn(1, 3, 32, 32) one_erase = RandomErase(probability=0, value='1.') self.assertEqual(one_erase.p, 0) self.assertEqual(one_erase.value, 1.) one_erase(dummy_input) rndm_erase = RandomErase(probability=0, value='random') self.assertEqual(rndm_erase.value, 'random') rndm_erase(dummy_input) if __name__ == '__main__': unittest.main()
Press p or to see the previous file or, n or to see the next file