From 7406523eea69c3595ef1c8059d77362cc643424e Mon Sep 17 00:00:00 2001 From: Qicheng Ma Date: Wed, 16 Oct 2024 13:10:11 -0700 Subject: [PATCH] Enable quantization as default for XNNPack for previous failing models (#6242) Summary: Since master has migrated aot_compiler to use to_edge_transform_and_lower in a previous change https://github.com/pytorch/executorch/pull/6026, quantization XNNPack options can be enabled by default for the following models: - Quantized ViT - Quantized Mobilebert - Quantized Emformer Predict - Quantized Emformer Transcribe Reviewed By: digantdesai Differential Revision: D64081319 --- examples/xnnpack/__init__.py | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/examples/xnnpack/__init__.py b/examples/xnnpack/__init__.py index 81404dcf6b7..d8de9f6a36e 100644 --- a/examples/xnnpack/__init__.py +++ b/examples/xnnpack/__init__.py @@ -4,6 +4,8 @@ # This source code is licensed under the BSD-style license found in the # LICENSE file in the root directory of this source tree. +# pyre-unsafe + from dataclasses import dataclass @@ -24,14 +26,14 @@ class XNNPACKOptions(object): "mv3": XNNPACKOptions(True, True), "resnet18": XNNPACKOptions(True, True), "resnet50": XNNPACKOptions(True, True), - "vit": XNNPACKOptions(False, True), # T161242362 + "vit": XNNPACKOptions(True, True), "w2l": XNNPACKOptions(True, True), "edsr": XNNPACKOptions(True, True), - "mobilebert": XNNPACKOptions(False, True), # T197452682 + "mobilebert": XNNPACKOptions(True, True), "llama2": XNNPACKOptions(False, True), "emformer_join": XNNPACKOptions(True, True), - "emformer_predict": XNNPACKOptions(False, True), # T197457838 - "emformer_transcribe": XNNPACKOptions(False, True), # T197449765 + "emformer_predict": XNNPACKOptions(True, True), + "emformer_transcribe": XNNPACKOptions(True, True), }