Skip to content

Commit c629200

Browse files
authored
Update getting-started.md
1 parent 08887a6 commit c629200

File tree

1 file changed

+7
-11
lines changed

1 file changed

+7
-11
lines changed

docs/source/llm/getting-started.md

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -660,19 +660,15 @@ edge_config = get_xnnpack_edge_compile_config()
660660
# Convert to edge dialect and lower to XNNPack.
661661
edge_manager = to_edge_transform_and_lower(traced_model, partitioner = [XnnpackPartitioner()], compile_config = edge_config)
662662
et_program = edge_manager.to_executorch()
663-
```
664-
665-
Finally, ensure that the runner links against the `xnnpack_backend` target in CMakeLists.txt.
666663

664+
with open("nanogpt.pte", "wb") as file:
665+
file.write(et_program.buffer)
667666
```
668-
add_executable(nanogpt_runner main.cpp)
669-
target_link_libraries(
670-
nanogpt_runner
671-
PRIVATE
672-
executorch
673-
extension_module_static # Provides the Module class
674-
optimized_native_cpu_ops_lib # Provides baseline cross-platform kernels
675-
xnnpack_backend) # Provides the XNNPACK CPU acceleration backend
667+
668+
Then run:
669+
```bash
670+
python export_nanogpt.py
671+
./cmake-out/nanogpt_runner
676672
```
677673

678674
For more information, see [Quantization in ExecuTorch](../quantization-overview.md).

0 commit comments

Comments
 (0)