From 0a7edd2df86dd16623009553cd76185a36e6fb06 Mon Sep 17 00:00:00 2001 From: Hao Zhang Date: Mon, 11 Aug 2025 01:02:38 +0800 Subject: [PATCH] Add a dim=0 and a rank=0 case for test of update mask. --- tests/update_mask_test.py | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/tests/update_mask_test.py b/tests/update_mask_test.py index 7118fc0..84ea25f 100644 --- a/tests/update_mask_test.py +++ b/tests/update_mask_test.py @@ -6,6 +6,21 @@ @pytest.fixture(params=[ + ( + (), + (), + torch.randn([], dtype=torch.float32), + ), + ( + (False, True), + ((2, 2), (0, 2)), + torch.randn([4, 2], dtype=torch.float32), + ), + ( + (False, True), + ((2, 2), (0, 0)), + torch.randn([4, 0], dtype=torch.float32), + ), ( (True, False), ((2, 2), (3, 1)),