Quantum variational Monte Carlo tools for research workflows.
Project description
qvmc
qvmc is a research-oriented Python library for quantum variational Monte Carlo workflows.
It packages the reusable core of this repository into an importable library with:
- restricted Boltzmann machine wavefunction models
- classical sampling helpers for spin systems
- Pauli operator construction and connection utilities
- a lightweight NumPy Adam optimizer
- an optional Qiskit backend for quantum-inspired proposal sampling
Installation
Install the core package:
pip install qvmc
Install the optional Qiskit backend:
pip install "qvmc[qiskit]"
For local development from this repository:
pip install -e ".[test]"
Quickstart
import numpy as np
from qvmc import RBM, SpinOperator
spin = SpinOperator(n_qubits=2)
hamiltonian = -spin.z(0) * spin.z(1) - 0.5 * spin.x(0) - 0.5 * spin.x(1)
rbm = RBM(N=2, M=2, seed=7)
energy = rbm.energy_exact(hamiltonian)
print(np.real(energy))
Package layout
qvmc.models: RBM-based variational modelsqvmc.sampling: classical sampling and probability helpersqvmc.operators: Pauli algebra and spin-operator utilitiesqvmc.optim: optimization helpersqvmc.backends.qiskit: optional Qiskit integration
Documentation
Sphinx docs live in docs/ and are structured around:
- installation and quickstart
- conceptual overview of the core workflow
- API reference
- Qiskit backend guide
- examples that replace the old script-style entrypoints
Build them locally with:
sphinx-build -b html docs docs/_build/html
Examples
Examples live in examples/ and are import-first workflows rather than command-line scripts:
examples/core_ground_state_workflow.pyexamples/qiskit_sampling_demo.py
Development validation
Recommended local validation steps:
python -m pytest
python -m build
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file qvmc-0.1.0.tar.gz.
File metadata
- Download URL: qvmc-0.1.0.tar.gz
- Upload date:
- Size: 18.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8a976c5f9b41c0d07bdf3df8c40961912c248b9fe656873268a59b18e5421aa5
|
|
| MD5 |
104734d617a3dee411a6a33d7fd78172
|
|
| BLAKE2b-256 |
50766dc60a33343d414463cf1c6fbed68b31e4b60544b2c19928dfaed85bee02
|
Provenance
The following attestation bundles were made for qvmc-0.1.0.tar.gz:
Publisher:
workflow.yaml on vinitX/Quantum-Sampling
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
qvmc-0.1.0.tar.gz -
Subject digest:
8a976c5f9b41c0d07bdf3df8c40961912c248b9fe656873268a59b18e5421aa5 - Sigstore transparency entry: 1339327008
- Sigstore integration time:
-
Permalink:
vinitX/Quantum-Sampling@0d981d0042d2aad7167219fd8cb6c7595b751cec -
Branch / Tag:
refs/heads/main - Owner: https://github.com/vinitX
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
workflow.yaml@0d981d0042d2aad7167219fd8cb6c7595b751cec -
Trigger Event:
workflow_dispatch
-
Statement type:
File details
Details for the file qvmc-0.1.0-py3-none-any.whl.
File metadata
- Download URL: qvmc-0.1.0-py3-none-any.whl
- Upload date:
- Size: 20.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f5186b99a7009b8b50f88d85594ccc9166a252ece8b8c09d7bda2f5aaae23c86
|
|
| MD5 |
25629efba44f11081e112703264d2a9f
|
|
| BLAKE2b-256 |
afd4adecf6273fd38612607aa529427394e4eb653ebcbd60b026a41f55b66e16
|
Provenance
The following attestation bundles were made for qvmc-0.1.0-py3-none-any.whl:
Publisher:
workflow.yaml on vinitX/Quantum-Sampling
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
qvmc-0.1.0-py3-none-any.whl -
Subject digest:
f5186b99a7009b8b50f88d85594ccc9166a252ece8b8c09d7bda2f5aaae23c86 - Sigstore transparency entry: 1339327009
- Sigstore integration time:
-
Permalink:
vinitX/Quantum-Sampling@0d981d0042d2aad7167219fd8cb6c7595b751cec -
Branch / Tag:
refs/heads/main - Owner: https://github.com/vinitX
-
Access:
private
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
workflow.yaml@0d981d0042d2aad7167219fd8cb6c7595b751cec -
Trigger Event:
workflow_dispatch
-
Statement type: