From b3e96d23332e7149009e8bfa854f4aca82e51631 Mon Sep 17 00:00:00 2001 From: Ethan Ng Date: Tue, 29 Jul 2025 10:20:12 -0700 Subject: [PATCH] Replace export_for_training with export (#12963) Summary: export_for_training will be deprecated soon, swap with export Differential Revision: D79097629 --- backends/cadence/aot/compiler_funcs.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/backends/cadence/aot/compiler_funcs.py b/backends/cadence/aot/compiler_funcs.py index 00653bc925b..5d5523ba31d 100644 --- a/backends/cadence/aot/compiler_funcs.py +++ b/backends/cadence/aot/compiler_funcs.py @@ -35,9 +35,9 @@ def trace( decomp_table = torch.export.default_decompositions() # pyre-fixme[6]: For 1st argument expected `Dict[typing.Callable[..., typing.Any remove_decompositions(decomp_table, ops_to_keep) - program = torch.export.export_for_training( - model, inputs, strict=strict - ).run_decompositions(decomp_table) + program = torch.export.export(model, inputs, strict=strict).run_decompositions( + decomp_table + ) return program