Distributed Quantum Computing (DQC): a QASM3 workbench to simulate split execution over a mesh of nodes (one chunk per QPU).
- Create and activate a virtual environment:
python3 -m venv .venv
. .venv/bin/activate- Install dependencies:
python -m pip install -r requirements.txt- Run the app from the repository root:
python main.pyAlternative entrypoint:
python -m appRun full tests with a hard timeout below 5 minutes:
timeout 280s python -m pytest -qRun one focused test module:
python -m pytest -q tests/test_pipeline_regressions.pyRun one specific regression test:
python -m pytest -q tests/test_runtime_source_coherence_regression.py- Start from the project root so relative paths resolve consistently.
- Built-in examples are under
qasm/. - Split-save artifacts are written under
qasm/split/<example-name>/. - The rewritten dump saved as
*.dqc.qasmis expected to match the live Rewritten view for the active rule selection.
app/pipeline.py: headless rewrite/analyze/execute logic (rules, split/teleport analysis, graph data, AER runtime).app/widgets.py: Qt widgets for code views, graphs, circuit rendering, and diagnostics display.app/main_window_clean.py: top-level UI wiring (menus, actions, refresh pipeline, runtime orchestration).app/main_window.py: compatibility shim re-exporting the main window API.
Rule execution model:
- Conditional rules run in numeric order.
- Rule
0bypasses conditional rules. - Unconditional rules
98and99run after conditional rules. - Downstream consumers (Rewritten view, runtime, circuit, graphs) are designed to use the same rewritten source.
These are the highest-signal tests for core app behavior:
tests/test_pipeline_regressions.py: rewrite pipeline order, fallbacks, and core transformations.tests/test_runtime_source_coherence_regression.py: runtime must consume the same rewritten source shown in UI paths.tests/test_save_split_dump_regression.py: saved*.dqc.qasmmust match Rewritten view and reject internal-only markers.tests/test_rewrite_spans.py: rewrite span mapping and coloring anchors across rule interactions.tests/test_rule11_measurement_consistency_regression.py: rule #11 split-generated teleportation measurement coherence.tests/test_chunk_edge_label_centering_regression.py: chunk dependency edge-label placement stability.