Platforms and Devices¶
The platform passed to the Golden Harness selects both the PyPTO backend and
the simpler runtime target.
| CLI value | PyPTO backend | Execution target | Device argument |
|---|---|---|---|
a2a3sim |
Ascend910B |
A2/A3 simulator | No physical NPU is selected |
a2a3 |
Ascend910B |
Ascend 910B/C NPU | Usually one integer device ID |
a5sim |
Ascend950 |
A5 simulator | No physical NPU is selected |
a5 |
Ascend950 |
Ascend 950 NPU | Usually one integer device ID |
The mapping is enforced by
golden.runner._backend_for_platform. An unknown
platform fails instead of silently choosing a default backend.
Architecture is not the platform¶
uname -m is used during installation to select a PTOAS release asset for the
host CPU architecture. It does not determine whether a script uses a
simulator or a real NPU.
Choose execution explicitly:
PYTHONPATH="$PWD" \
python examples/beginner/hello_world.py -p a2a3sim
PYTHONPATH="$PWD" \
python examples/beginner/hello_world.py -p a2a3 -d 0
The current CI makes the same distinction: simulator jobs do not source CANN, while real-device jobs source CANN and verify the NPU before execution.
Inspect each entry point¶
The beginner examples accept:
Do not generalize that device shape to every model. A distributed program can
require a comma-separated device set and an explicit world-size argument.
Some large programs are marked # ci: no-sim, or take a compile-only path on
a simulator.
Always inspect the selected file:
What CI coverage means¶
For selected runnable changes, pull-request CI exercises:
a2a3simanda5simin the simulator matrix, unless the file opts out;a2a3on a real NPU, including declared multi-card allocations.
Additional scheduled jobs are configured for broader model and A5-device cases. A CLI choice means an entry point accepts the target; it does not by itself prove that every path in that program is validated on the target. Consult the Examples page for the stated coverage of a particular example, and the Models pages for what each model tree implements.
Shared device hosts¶
On a shared machine, do not choose an apparently idle device by probing and then racing another user. Use the site's device allocator or scheduler and pass the allocated ID or ID set to the kernel.
For a direct device shell:
The repository CI uses task-submit to allocate devices, but that service is
infrastructure-specific and is not required by PyPTO-Lib itself.