diff --git a/tests/test_models/test_editors/test_stylegan3/test_stylegan3_utils.py b/tests/test_models/test_editors/test_stylegan3/test_stylegan3_utils.py index 4e906daaf2..b995f0baae 100644 --- a/tests/test_models/test_editors/test_stylegan3/test_stylegan3_utils.py +++ b/tests/test_models/test_editors/test_stylegan3/test_stylegan3_utils.py @@ -16,6 +16,13 @@ def test_integer_transformation(): print(z.shape) print(m.shape) + # cover more lines + t = torch.zeros(2) + z, m = apply_integer_translation(x, t[0], t[1]) + + t = torch.ones(2) * 2 + z, m = apply_integer_translation(x, t[0], t[1]) + def test_fractional_translation(): x = torch.randn(1, 3, 16, 16) @@ -24,6 +31,13 @@ def test_fractional_translation(): print(z.shape) print(m.shape) + # cover more lines + t = torch.zeros(2) + z, m = apply_fractional_translation(x, t[0], t[1]) + + t = torch.ones(2) * 2 + z, m = apply_fractional_translation(x, t[0], t[1]) + @pytest.mark.skipif( digit_version(TORCH_VERSION) < digit_version('1.8.0'),