From b0aea68f68ac61d2fc0644f429a5336ea3e715b5 Mon Sep 17 00:00:00 2001 From: Claudio Fantacci Date: Sat, 22 Aug 2026 04:42:35 -0700 Subject: [PATCH] Improve `test_pad_to_size_chw_values` test This is mostly to make static type analyzers happy. FUTURE_COPYBARA_INTEGRATE_REVIEW=https://github.com/google-deepmind/dm_pix/pull/118 from v1shay:agent/random-flip-up-down-channel-axis f145fcb210191670bbe3a8a901b8058bfd93d970 PiperOrigin-RevId: 968970525 --- dm_pix/_src/augment_test.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/dm_pix/_src/augment_test.py b/dm_pix/_src/augment_test.py index d41ffb2..7554157 100644 --- a/dm_pix/_src/augment_test.py +++ b/dm_pix/_src/augment_test.py @@ -590,6 +590,8 @@ def test_pad_to_size_chw_values(self): result = augment.pad_to_size( image, target_height=3, target_width=3, channel_axis=0 ) + self.assertNotIsInstance(result, np.bool_) + self.assertNotIsInstance(result, np.number) self.assertEqual(result.shape, (1, 3, 3)) np.testing.assert_array_equal(result[0, 1, 1], 1.0) np.testing.assert_array_equal(result[0, 0, :], 0.0)