Skip to content

Commit e70dd50

Browse files
author
ssjia
committed
Update on "[ET-VK] Implementation of to_dim_order_copy"
Title says it all! Previously, to_dim_order_copy was handled by removing the op. However, this is not possible if the op is modifying the dtype of the original tensor, so these instances of the op would be skipped by the partitioner. This diff adds an implementation dtype conversion, which allows to_dim_order_copy to be lowered. Differential Revision: [D86340341](https://our.internmc.facebook.com/intern/diff/D86340341/) [ghstack-poisoned]
2 parents e33a210 + 0d33060 commit e70dd50

File tree

1 file changed

+0
-12
lines changed

1 file changed

+0
-12
lines changed

backends/vulkan/test/test_vulkan_delegate.py

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -11,20 +11,14 @@
1111
from typing import Tuple
1212

1313
import executorch.backends.vulkan.test.utils as test_utils
14-
1514
import torch
16-
1715
from executorch.backends.transforms.convert_dtype_pass import I64toI32
18-
1916
from executorch.backends.vulkan.partitioner.vulkan_partitioner import VulkanPartitioner
20-
2117
from executorch.backends.vulkan.vulkan_preprocess import VulkanBackend
22-
2318
from executorch.backends.xnnpack.quantizer.xnnpack_quantizer import (
2419
get_symmetric_quantization_config,
2520
XNNPACKQuantizer,
2621
)
27-
2822
from executorch.exir import (
2923
EdgeCompileConfig,
3024
EdgeProgramManager,
@@ -36,11 +30,8 @@
3630
)
3731
from executorch.extension.pytree import tree_flatten
3832
from torch.export import Dim, export, ExportedProgram
39-
4033
from torchao.quantization.granularity import PerGroup
41-
4234
from torchao.quantization.pt2e.quantize_pt2e import convert_pt2e, prepare_pt2e
43-
4435
from torchao.quantization.pt2e.quantizer import Quantizer
4536
from torchao.quantization.quant_api import IntxWeightOnlyConfig, quantize_
4637
from torchao.utils import unwrap_tensor_subclass
@@ -69,9 +60,6 @@ def lower_module(
6960
edge_program = to_edge_transform_and_lower(
7061
program,
7162
compile_config=edge_compile_config,
72-
transform_passes=[
73-
I64toI32(edge_compile_config._skip_dim_order),
74-
],
7563
partitioner=[VulkanPartitioner(compile_options)],
7664
)
7765

0 commit comments

Comments
 (0)