Skip to main content

Enables the formulation of nonlinear models for industrial optimization problems.

Project description

https://img.shields.io/pypi/v/dwave-optimization.svg https://img.shields.io/pypi/pyversions/dwave-optimization.svg https://circleci.com/gh/dwavesystems/dwave-optimization.svg?style=svg

dwave-optimization

dwave-optimization enables the formulation of nonlinear models for industrial optimization problems. The package includes:

  • A class for nonlinear models used by the Leap service’s quantum-classical hybrid nonlinear-program solver.

  • Model generators for common optimization problems.

Example Usage

The flow-shop scheduling problem is a variant of the renowned job-shop scheduling optimization problem. Given n jobs to schedule on m machines, with specified processing times for each job per machine, minimize the makespan (the total length of the schedule for processing all the jobs). For every job, the i-th operation is executed on the i-th machine. No machine can perform more than one operation simultaneously.

This small example builds a model for optimizing the schedule for processing two jobs on three machines.

from dwave.optimization.generators import flow_shop_scheduling

processing_times = [[10, 5, 7], [20, 10, 15]]
model = flow_shop_scheduling(processing_times=processing_times)

For explanations of the terminology, see the Ocean glossary.

See the documentation for more examples.

Installation

Installation from PyPI:

pip install dwave-optimization

During package development, it is often convenient to use an editable install. See meson-python’s editable installs for more details.

pip install -r requirements.txt
pip install --no-build-isolation --config-settings=editable-verbose=true --editable .

Testing

All code should be thoroughly tested and all pull requests should include tests.

To run the Python tests, first install the package using an editable install as described above. The tests can then be run with unittest.

python -m unittest

To run the C++ tests, first install the project dependencies, then setup a meson build directory. You must configure the build as a debug build for the tests to run.

pip install -r requirements.txt
meson setup build -Dbuildtype=debug

You can then run the tests using meson’s test framework.

meson test -Cbuild

License

Released under the Apache License 2.0. See LICENSE file.

Contributing

Ocean’s contributing guide has guidelines for contributing to Ocean packages.

dwave-optimization includes some formatting customization in the .clang-format and setup.cfg files.

Release Notes

dwave-optimization makes use of reno to manage its release notes.

When making a contribution to dwave-optimization that will affect users, create a new release note file by running

reno new your-short-descriptor-here

You can then edit the file created under releasenotes/notes/. Remove any sections not relevant to your changes. Commit the file along with your changes.

See reno’s user guide for details.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dwave_optimization-0.6.2.tar.gz (281.4 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

dwave_optimization-0.6.2-cp313-cp313-win_amd64.whl (1.2 MB view details)

Uploaded CPython 3.13Windows x86-64

dwave_optimization-0.6.2-cp313-cp313-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl (3.6 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.24+ x86-64manylinux: glibc 2.28+ x86-64

dwave_optimization-0.6.2-cp313-cp313-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl (3.5 MB view details)

Uploaded CPython 3.13manylinux: glibc 2.24+ ARM64manylinux: glibc 2.28+ ARM64

dwave_optimization-0.6.2-cp313-cp313-macosx_11_0_arm64.whl (1.2 MB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

dwave_optimization-0.6.2-cp313-cp313-macosx_10_13_x86_64.whl (1.4 MB view details)

Uploaded CPython 3.13macOS 10.13+ x86-64

dwave_optimization-0.6.2-cp312-cp312-win_amd64.whl (1.2 MB view details)

Uploaded CPython 3.12Windows x86-64

dwave_optimization-0.6.2-cp312-cp312-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl (3.6 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.24+ x86-64manylinux: glibc 2.28+ x86-64

dwave_optimization-0.6.2-cp312-cp312-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl (3.5 MB view details)

Uploaded CPython 3.12manylinux: glibc 2.24+ ARM64manylinux: glibc 2.28+ ARM64

dwave_optimization-0.6.2-cp312-cp312-macosx_11_0_arm64.whl (1.2 MB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

dwave_optimization-0.6.2-cp312-cp312-macosx_10_13_x86_64.whl (1.4 MB view details)

Uploaded CPython 3.12macOS 10.13+ x86-64

dwave_optimization-0.6.2-cp311-cp311-win_amd64.whl (1.2 MB view details)

Uploaded CPython 3.11Windows x86-64

dwave_optimization-0.6.2-cp311-cp311-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl (3.7 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.24+ x86-64manylinux: glibc 2.28+ x86-64

dwave_optimization-0.6.2-cp311-cp311-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl (3.6 MB view details)

Uploaded CPython 3.11manylinux: glibc 2.24+ ARM64manylinux: glibc 2.28+ ARM64

dwave_optimization-0.6.2-cp311-cp311-macosx_11_0_arm64.whl (1.3 MB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

dwave_optimization-0.6.2-cp311-cp311-macosx_10_13_x86_64.whl (1.4 MB view details)

Uploaded CPython 3.11macOS 10.13+ x86-64

dwave_optimization-0.6.2-cp310-cp310-win_amd64.whl (1.2 MB view details)

Uploaded CPython 3.10Windows x86-64

dwave_optimization-0.6.2-cp310-cp310-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl (3.6 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.24+ x86-64manylinux: glibc 2.28+ x86-64

dwave_optimization-0.6.2-cp310-cp310-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl (3.5 MB view details)

Uploaded CPython 3.10manylinux: glibc 2.24+ ARM64manylinux: glibc 2.28+ ARM64

dwave_optimization-0.6.2-cp310-cp310-macosx_11_0_arm64.whl (1.3 MB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

dwave_optimization-0.6.2-cp310-cp310-macosx_10_13_x86_64.whl (1.4 MB view details)

Uploaded CPython 3.10macOS 10.13+ x86-64

dwave_optimization-0.6.2-cp39-cp39-win_amd64.whl (1.2 MB view details)

Uploaded CPython 3.9Windows x86-64

dwave_optimization-0.6.2-cp39-cp39-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl (3.6 MB view details)

Uploaded CPython 3.9manylinux: glibc 2.24+ x86-64manylinux: glibc 2.28+ x86-64

dwave_optimization-0.6.2-cp39-cp39-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl (3.5 MB view details)

Uploaded CPython 3.9manylinux: glibc 2.24+ ARM64manylinux: glibc 2.28+ ARM64

dwave_optimization-0.6.2-cp39-cp39-macosx_11_0_arm64.whl (1.3 MB view details)

Uploaded CPython 3.9macOS 11.0+ ARM64

dwave_optimization-0.6.2-cp39-cp39-macosx_10_13_x86_64.whl (1.4 MB view details)

Uploaded CPython 3.9macOS 10.13+ x86-64

File details

Details for the file dwave_optimization-0.6.2.tar.gz.

File metadata

  • Download URL: dwave_optimization-0.6.2.tar.gz
  • Upload date:
  • Size: 281.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.22

File hashes

Hashes for dwave_optimization-0.6.2.tar.gz
Algorithm Hash digest
SHA256 d1e42bbf2ee9b47d0d4775388adcee981ea6d03242e4d9f4832ef5e84504c469
MD5 f64dd5ada629d0dbf71d2f833bd5d140
BLAKE2b-256 52a82b450118861e3b6a3325a78e4852be1d84bc049abeeea2f11ddb305b4098

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp313-cp313-win_amd64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 e5ee66960a08740ceb108a6851674bfcd0e4569c6a865abca3dc5bb472b62909
MD5 0698b1a39034101898ddf0af6481b9e9
BLAKE2b-256 80b3870b044ff0d7715d5262dcb3b21f6526354c468493b7f94749564ee96b3d

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp313-cp313-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp313-cp313-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 98fcda687d6706b72aec65525a9cc9f4b4b89fa89ff19136714d04784fa91f2d
MD5 5a20dad3bcc301059b07bbb48bc7c0c8
BLAKE2b-256 a819dffcd4a39b901fabf77b77305049eb21d8f260a68f1ffcb05a1e9d83f949

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp313-cp313-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp313-cp313-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 2f7b8bb07decc20bc32fc5114e2fa3638e50074cb828cab2d72b1dff867bac82
MD5 931763e80803981657e1a6f5a983953f
BLAKE2b-256 13b33c00f27dc52c854706cac0b4fe449ae3bc018cc29fad7a4a1afcd1ca46c5

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 85c250f9bc3eda64c11432c71dfef22b77e9f0ed28e5146f28b1cafef15de20a
MD5 072f0b9f4905d6d010b15b4f7ce3d08a
BLAKE2b-256 ae1e836d1f3f8c437001b7cdd58d04a886b2a9993a31f4a50970fc43332cd722

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp313-cp313-macosx_10_13_x86_64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp313-cp313-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 4dea52b550a1e0067a5da6015b886a944efd54a8d42f9c18626dc8c961446a92
MD5 08ce6b233a37497a7a304ad1a2dedfee
BLAKE2b-256 ff9862ab2763cf9ae3854305e0ce286d66a48a479f52f44982e7404a49894eb4

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 0b856abe5a4f4327de69fa371eb0f6a1f4a62a6978192d48b64d2ef189df6822
MD5 5f41aaf27abfb347fd07da5c409133e9
BLAKE2b-256 75d111e3a32c2be6cbba7e0db472ab5e145c76da1caf7dfc5b188905b67d241f

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp312-cp312-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp312-cp312-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 8e85f54f680ddaaf7fd22639647e37b0efbe7b2fe41425b8f58401073e72404d
MD5 1feccb578b5ad3e4a96fb6660a88a42d
BLAKE2b-256 e7723799371c3e2f09f4e988aebce5bc6c6054cd484f5c34fbc52a7d9de9cb46

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp312-cp312-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp312-cp312-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 88a98ce1ea90316b618da3d368db3695e7ea197aa92269917bb124d66fff804e
MD5 2c7f62def427c03601e8dea3bc5aadd1
BLAKE2b-256 cd8be4d08528c06b1be25ed13f6ae8fd9c61fdafbc02daae1250a38b26a89c8d

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 225791232cd49a8821885f343ad86eda517a569cf7729ac79f51f16c3eb59953
MD5 f53d80b9c9f40cf77429f3aa51efc8dd
BLAKE2b-256 802377abe548fa5b91d702c60218ca804c5888aa41cf0f165ed2008057f420e0

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp312-cp312-macosx_10_13_x86_64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp312-cp312-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 6393ffaf4a9de5c0434b0498a5b766648346c5a779560eea230e447c2f3ebe8b
MD5 a611bb1fff8ac63a1a133413871151da
BLAKE2b-256 9af00385186f7f8d6ede91b084b4256bffb58d4d72ae61bd695a08df772069b2

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 7d7aac4ca76b51279ee2ff6b68064d350b77569ef4939a7f7e16ee39a2d74457
MD5 91f6756f23bac56a292f0fed2d0222ec
BLAKE2b-256 bc5241d65b7660433a4d883960074665571c5ebf7bab974848f4380d402dc600

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp311-cp311-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp311-cp311-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 a49864cab993ef396ecfea4edd014068cf6cef0ebbcb41dff5fb148bb46ba62e
MD5 90a33a9f4d302857ec14f7472ec563a6
BLAKE2b-256 fd8a95b207aed503a455748e4b28e39186fd57a8bca906ad809478509fbb193e

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp311-cp311-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp311-cp311-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 477dd7c2620e3633942dd10726163332c2d0726b3ca83ad8df01bf7147ad64e2
MD5 014e1ce8be8381653d662b609fb26723
BLAKE2b-256 9426b7df9dca936ddfe8af6c06934ff16db573c7724e831736908bc7c8827215

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 6415a531160dec804c32af5bcf8c8e4291d1a24a1ac0e936d5f148177140eb3f
MD5 8e38ebdeb7b4fe30d37b8a3aad0d21bb
BLAKE2b-256 99a478f3ac3670489ff557b313db34337f47d90a0ba398a293aa22fd48268424

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp311-cp311-macosx_10_13_x86_64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp311-cp311-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 7dc0b1d8bed238efc3b97b802e42602d1ab5582b2652e13aede14c4b0850f2d2
MD5 9580d38516aede95c03189646c40f7f0
BLAKE2b-256 9905aa8ad8bb7dd5f02353e1c668614cfbc77436a7ebaf2a26082ad177ddb64b

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 bf0bfdac565ec90368759b64169d68a75c6997998993b0867835494419039d27
MD5 a6245acb12de0631e15563c6b777a11a
BLAKE2b-256 1facea148adea706fc51dd0e26b431bae5aedb0c3a614d3af4f92f91e89e12bb

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp310-cp310-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp310-cp310-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 7498529a3f6c0872351d2a8662f111a7df8c02eb740abc64e532499fa7a2ae76
MD5 ace05a416a73b5278170fb5c524efe47
BLAKE2b-256 62ae94444581a05c8badc3b795d2e89d467a698164257e418ffb1ed7b788ef15

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp310-cp310-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp310-cp310-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 4151813c7beae981510449ab658284e4a62ede2230ac402e2d2a65918d7b048c
MD5 c87d003627238b482db6fbc9baef3d44
BLAKE2b-256 4152b08f4053898eda9904f9eb068854f3d132a187c716f8fcedbbe9da8bde6f

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 5158d73e95f733da632b5e114f731d5c842fe5500beec0c5789256e43182be4c
MD5 38a205f768a8bd8a2adf705e8b1c2ec6
BLAKE2b-256 b4294a33d562a05e569438589201b18cd3dca5f248e8e2d3d8a367f9ce8534c1

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp310-cp310-macosx_10_13_x86_64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp310-cp310-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 3aa282183976767c062517cd9cdb35c4551e14a769629cf288fd0d1f04df3131
MD5 47d1fbf2d333fe359a87be46a3ece439
BLAKE2b-256 dac2c635bc9dc6a47eb96279c232136896c180a4e10d665f0ebd91c05e1b0a48

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp39-cp39-win_amd64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 629ac9a3f1c2120e3f62f61b572751742d2eb7422decee1552c8ef6c563e1ddc
MD5 3e8a40498b98b4b2490d8e8ed8d57126
BLAKE2b-256 6fb5e4ad9eb0de2e2903a9c36121336f5e95f6c26413615ada92897df49ee2bd

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp39-cp39-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp39-cp39-manylinux_2_24_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 b879cd341ea7e467941c8b1dbed7472de2ecb94351ce7742d3756ec18c067e81
MD5 cc81a746a67f5445cbbe889839c6c834
BLAKE2b-256 75ff118e701bf3a6412f3b415a0fca3688efa7721c98c51321687c112c5f7a17

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp39-cp39-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp39-cp39-manylinux_2_24_aarch64.manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 81ff324ac4750316426ec6cdb0ef4a267743ec2a4b60dc83c99043de11f8b7d2
MD5 34ed2c87778b7a2a226b8655b5009f47
BLAKE2b-256 7e3402ab747e9e79cc22f48a60f74ccd8924350c5fc64f8c3e0be0a77536eb07

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp39-cp39-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp39-cp39-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 1d65b59b5e4f9444a16f1b9b6f015567454f5f0cd506c70d52a79c1582b22138
MD5 91d59e9dcc62a873bf3925711ef62a65
BLAKE2b-256 d313ceab5b5ad5fa334a3e9866026b9b0bb8a79a3ef149fc44deb9cbf2a31aac

See more details on using hashes here.

File details

Details for the file dwave_optimization-0.6.2-cp39-cp39-macosx_10_13_x86_64.whl.

File metadata

File hashes

Hashes for dwave_optimization-0.6.2-cp39-cp39-macosx_10_13_x86_64.whl
Algorithm Hash digest
SHA256 562a9d988f719e151972acf42ac26ea799c7787ea32dbcc5b56e6846f06c5c0c
MD5 3ffa4004e67bf071ed0258e5199e7fa7
BLAKE2b-256 457e8fc3b379ffb643e2d860f7a378ce27224cb5b74fdb398ae4433d761142e4

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page