Skip to content

Commit 8976eda

Browse files
committed
print qnn graph
1 parent 47c2f2e commit 8976eda

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

examples/models/llama/export_llama_lib.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -800,6 +800,11 @@ def _export_llama(args) -> LLMEdgeManager: # noqa: C901
800800
# pyre-fixme[16]: Module `backends` has no attribute `qualcomm`.
801801
canonicalize_program(builder.edge_manager.exported_program())
802802

803+
print("lfq: exported program after to_backend, graph_module")
804+
print(builder.edge_manager.exported_program().graph_module)
805+
print("lfq: exported program after to_backend, print_readable")
806+
print(builder.edge_manager.exported_program().graph_module.print_readable())
807+
803808
builder = builder.to_executorch()
804809

805810
if args.profile_memory:

extension/llm/export/builder.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -193,6 +193,7 @@ def export(self) -> "LLMEdgeManager":
193193
dynamic_shapes=dynamic_shape,
194194
strict=True,
195195
)
196+
print("lfq: exported_module ", exported_module.graph_module)
196197
else:
197198
logging.info("Exporting with:")
198199
logging.info(f"inputs: {self.example_inputs}")

0 commit comments

Comments
 (0)