arcade.api
High-level convenience API for ARCADE.
Functions
|
Run multiple classifiers and compare results. |
|
Return a multi-line description of a registered classifier. |
|
Print a human-readable data-quality summary to stdout. |
|
Load and prepare readout data for classification (data stage). |
- arcade.api.load(path, num_qubits, *, num_levels=2, format='auto', **kwargs)[source]
Load and prepare readout data for classification (data stage).
Prefer YAML +
arcade.run()for full bake-offs. Useload()when you want an in-memory bundle forcompare()or custom scripts.- Parameters:
path (
str|Path) – Path to data file (HDF5, NPY, NPZ, or pickle).num_qubits (
int) – Number of qubits in the data.num_levels (
int) – Energy levels per qubit (default2).format (
str) – File format or"auto"for detection.**kwargs (
Any) – Extradata:config fields (e.g.hdf5_keys,demodulation,multiplexed,qubit_bit_order).
- Return type:
- Returns:
Prepared data dict with traces, labels, splits, and related stage outputs.
- Raises:
arcade.config.ArcadeConfigError – Invalid combined config.
FileNotFoundError – path does not exist (via loader).
- arcade.api.compare(data, classifiers=None, *, num_qubits=None, num_levels=2, sweep=True, hardware=True, report=False, output_dir='./output', **kwargs)[source]
Run multiple classifiers and compare results.
For production zoo runs, prefer
arcade run configs/….yamlso demod, filters, and report sections stay in one file.compare()is the compact Python helper.- Parameters:
data (
dict[str,Any] |str|Path) – Prepared dict fromload(), or a path to a data file.classifiers (
list[str] |None) – Registry names.Nonedefaults to["threshold", "svm", "fnn"].num_qubits (
int|None) – Required when data is a file path.num_levels (
int) – Levels per qubit (default2).sweep (
bool) – Enable readout-duration sweep.hardware (
bool) – Enable analytical FPGA resource estimation.report (
bool) – Generate a summary PDF/HTML report when supported.output_dir (
str) – Output directory for plots / reports.**kwargs (
Any) – Merged into the top-level config dict when data is a path (advanced; prefer a YAML file for complex recipes).
- Return type:
- Returns:
PipelineResultswhen available, otherwise a plain results dict withdata/classify/hardwarekeys.- Raises:
ValueError – File-path data without num_qubits.
- arcade.api.explore(data, *, num_qubits=None)[source]
Print a human-readable data-quality summary to stdout.
Shows trace shapes, label histogram, split sizes, and whether transition detection ran. Intended for interactive debugging (also via
arcade explore).