ommx-dwave-adapter
Provides an adapter to translate between OMMX and D-Wave samplers.
Currently only implements an adapter to LeapHybridCQMSampler.
Usage
ommx-dwave-adapter can be installed from PyPI as follows:
pip install ommx-dwave-adapter
An example usage of the LeapHybridCQMSampler through this adapter:
from ommx_dwave_adapter import OMMXLeapHybridCQMAdapter
from ommx.v1 import Instance, DecisionVariable
x1 = DecisionVariable.integer(1, lower=0, upper=5)
ommx_instance = Instance.from_components(
decision_variables=[x1],
objective=x1,
constraints=[],
sense=Instance.MINIMIZE,
)
# Create `ommx.v1.SampleSet` through `diwave.system.LeapHybridCQMSampler`
# Your Leap token can be set through configuration file, environment variable,
# or passed with a `token` parameter.
ommx_sampleset = OMMLeapHybridCQMAdapter.sample(ommx_instance)
print(ommx_sampleset)
Metadata
Release files for ommx-dwave-adapter 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| ommx_dwave_adapter-0.1.1.tar.gz | 109.4 kB | Details |
Release files / ommx_dwave_adapter-0.1.1.tar.gz
| Download URL | ommx_dwave_adapter-0.1.1.tar.gz |
|---|---|
| Size | 109.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b8cb5f3a782114cc5d0a3308e430c6088274932c7c75f2099ab6648505f36500
|
|
BLAKE2b-256 checksum How to use checksums |
c7ec4a571fc4570939fd34532b8d511798dbce0d760c90a13caca0ef09183319
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.12.9
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jul 31, 2025.
Transparency log