Skip to content

Add batched GPU simulator and release 0.2.0 - #1

Merged
VesterlundCoder merged 1 commit into
mainfrom
release-0.2.0
Oct 27, 2026
Merged

VesterlundCoder merged 1 commit into
mainfrom
release-0.2.0

Conversation

@VesterlundCoder

Copy link
Copy Markdown
Contributor

Summary

Prepares westquant-cudaq 0.2.0 with the batched GPU simulator for dataset generation (westquant_cudaq.batched).

  • westquant_cudaq.batched: state-vector simulation of thousands of small circuits (about 2–24 qubits) per batch, on NumPy (CPU) or CuPy (GPU). Supports Pauli-trajectory noise, readout error, shots and Parquet output with provenance. See docs/BATCHED.md.
  • wq-batch command (run, plan, bench) and Slurm scripts for A100 clusters in scripts/hpc/.
  • westquant_cudaq.py becomes the package westquant_cudaq/. The only change to the former module is __version__ plus a lazy __getattr__ for batched, so import westquant_cudaq stays dependency-free. The 0.1.0 tests are moved to tests/ unchanged and still pass.
  • New extras: batched (numpy, qiskit, pyarrow) and gpu (cupy-cuda12x).
  • Added CHANGELOG 0.2.0, bumped CITATION.cff to 0.2.0, and added CI: tests.yml plus the same test-gated publish.yml as the other WestQuant repos.
    • Note: PyPI Trusted Publishing has to be registered for WestQuantOpen/westquant-cudaq / publish.yml / environment pypi before a release can upload. 0.1.0 was uploaded manually.

Test plan

  • 19 tests pass locally on Python 3.12 (CPU/NumPy path): the batched tests against Qiskit Statevector and the density-matrix reference, plus all 0.1.0 tests
  • pip check clean with [test,batched]
  • wheel + sdist built, twine check --strict passes
  • CPU bench (512 circuits, depth 20): 8 599 / 712 / 55 circuits/s at 4 / 8 / 12 qubits, vs 116 / 87 / 34 for Qiskit Statevector
  • GPU path: run sbatch scripts/hpc/bench_a100.sbatch on the cluster (not available here)
  • Tests workflow green on this PR

Generated with Devin

Adds a throughput-oriented simulator for dataset generation: thousands of
small circuits per batch, one batched matrix product per gate step, on NumPy
or CuPy, with Pauli-trajectory noise, readout error, shots and Parquet output.

- New westquant_cudaq.batched package, wq-batch CLI and Slurm/A100 scripts.
- The module becomes a package; the 0.1.0 API and its tests are unchanged.
- Optional extras batched and gpu; plain import stays dependency-free.
- Add tests.yml and a test-gated Trusted Publishing publish.yml (the repo
  had no CI and 0.1.0 was uploaded manually).

Generated with [Devin](https://devin.ai)

Co-Authored-By: Devin <158243242+devin-ai-integration[bot]@users.noreply.github.com>
@VesterlundCoder
VesterlundCoder merged commit f72d44f into main Oct 27, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant