From 0897636b26da30ca77ee180950957bec2af4a53b Mon Sep 17 00:00:00 2001 From: Ethan Ng Date: Mon, 1 Dec 2025 18:31:45 -0800 Subject: [PATCH] Call prepare_traced_pt2 instead of prepare_pt2 in get_fake_quant_model Summary: avoids tracing twice Differential Revision: D88103722 --- backends/cadence/aot/compiler.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backends/cadence/aot/compiler.py b/backends/cadence/aot/compiler.py index 69882218bf5..d19abf222b8 100644 --- a/backends/cadence/aot/compiler.py +++ b/backends/cadence/aot/compiler.py @@ -183,7 +183,7 @@ def get_fake_quant_model( logging.info(program.graph.print_tabular()) # Get prepared graph module - prepared_gm = prepare_pt2(model, inputs, quantizer, dump_graphs=dump_graphs) + prepared_gm = prepare_traced_pt2(program, quantizer, dump_graphs=dump_graphs) # Calibrate # If no calibration data is provided, use the inputs