Raise TypeError instead of ValueError for invalid types (#38660)
* Raise TypeError instead of ValueError for invalid types. * Removed un-necessary changes. * Resolved conflicts * Code quality * Fix failing tests. * Fix failing tests.
This commit is contained in:
@@ -246,7 +246,7 @@ class ImageTransformsTester(unittest.TestCase):
|
||||
|
||||
# Test that exception is raised if inputs are incorrect
|
||||
# Not a numpy array image
|
||||
with self.assertRaises(ValueError):
|
||||
with self.assertRaises(TypeError):
|
||||
normalize(5, 5, 5)
|
||||
|
||||
# Number of mean values != number of channels
|
||||
|
||||
Reference in New Issue
Block a user