|
27 | 27 | AmbiguousDimOrderError, |
28 | 28 | MemoryFormatOpsPassTestUtils, |
29 | 29 | MemoryFormatTestSet, |
30 | | - PropagateToCloneChannelsLastModule, |
31 | 30 | PropagateToCopyChannalsLastModule, |
32 | | - SimpleCloneChannelsLastModule, |
33 | | - SimpleCloneContiguousModule, |
34 | 31 | SimpleEmptyChannelLastModule, |
35 | 32 | SimpleEmptyContiguoustModule, |
36 | 33 | SimpleToCopyChannelsLastModule, |
@@ -94,36 +91,6 @@ def test_op_empty_replacement_contiguous(self) -> None: |
94 | 91 | ), |
95 | 92 | ) |
96 | 93 |
|
97 | | - def test_op_clone_replacement_contiguous(self) -> None: |
98 | | - model = SimpleCloneContiguousModule() |
99 | | - MemoryFormatOpsPassTestUtils.memory_format_test_runner( |
100 | | - self, |
101 | | - MemoryFormatTestSet( |
102 | | - module=model.eval(), |
103 | | - op=torch.ops.aten.clone.default, |
104 | | - sample_input=( |
105 | | - torch.randn((3, 4, 5, 6)).to(memory_format=torch.channels_last), |
106 | | - ), |
107 | | - target_memory_format=torch.contiguous_format, |
108 | | - _load_for_executorch_from_buffer=_load_for_executorch_from_buffer, |
109 | | - ), |
110 | | - ) |
111 | | - |
112 | | - def test_op_clone_replacement_channels_last(self) -> None: |
113 | | - model = SimpleCloneChannelsLastModule() |
114 | | - MemoryFormatOpsPassTestUtils.memory_format_test_runner( |
115 | | - self, |
116 | | - MemoryFormatTestSet( |
117 | | - module=model.eval(), |
118 | | - op=torch.ops.aten.clone.default, |
119 | | - sample_input=( |
120 | | - torch.randn((3, 4, 5, 6)).to(memory_format=torch.contiguous_format), |
121 | | - ), |
122 | | - target_memory_format=torch.channels_last, |
123 | | - _load_for_executorch_from_buffer=_load_for_executorch_from_buffer, |
124 | | - ), |
125 | | - ) |
126 | | - |
127 | 94 | def test_op_dim_order_update(self) -> None: |
128 | 95 | MemoryFormatOpsPassTestUtils.memory_format_test_runner( |
129 | 96 | self, |
@@ -161,25 +128,6 @@ def test_op_dim_order_propagation(self) -> None: |
161 | 128 | check_unambiguous_dim_order=True, |
162 | 129 | ) |
163 | 130 |
|
164 | | - def test_op_clone_dim_order_propagation(self) -> None: |
165 | | - MemoryFormatOpsPassTestUtils.memory_format_test_runner( |
166 | | - self, |
167 | | - MemoryFormatTestSet( |
168 | | - module=PropagateToCloneChannelsLastModule().eval(), |
169 | | - op=torch.ops.aten.clone.default, |
170 | | - sample_input=( |
171 | | - torch.rand_like( |
172 | | - torch.zeros([2, 2, 2, 2]), |
173 | | - dtype=torch.float32, |
174 | | - memory_format=torch.contiguous_format, |
175 | | - ), |
176 | | - ), |
177 | | - target_memory_format=torch.channels_last, |
178 | | - _load_for_executorch_from_buffer=_load_for_executorch_from_buffer, |
179 | | - ), |
180 | | - check_unambiguous_dim_order=True, |
181 | | - ) |
182 | | - |
183 | 131 | def test_op_dim_order_propagation_ambiguous(self) -> None: |
184 | 132 | try: |
185 | 133 | MemoryFormatOpsPassTestUtils.memory_format_test_runner( |
|
0 commit comments