MCPcopy Create free account
hub / github.com/Kaggle/docker-python / test_grayscale_torch

Method test_grayscale_torch

tests/test_kornia.py:15–19  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

13 self.assertEqual(img_t.shape, (3, 1, 1))
14
15 def test_grayscale_torch(self):
16 img_rgb = torch.rand(2, 3, 4, 5)
17 img_gray = kornia.color.rgb_to_grayscale(img_rgb)
18
19 self.assertEqual(img_gray.shape, (2, 1, 4, 5))

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected