High level application module for solving combinatorial optimisation problems with Qibo
Project description
Qiboopt
Qiboopt is a plugin to Qibo for solving combinatorial optimization problems.
Documentation
For the complete documentation on qiboopt, please refer to qiboopt.
Minimum working example
This repository can create QAOA circuits given a QUBO. For certain applications such as maximum independent set and traveling salesman problem, more functionalities have been coded to prepare the QUBO faster.
For example, to construct a Maximal Independent Set problem instance as a QUBO and solving it using QAOA:
import networkx as nx
from qiboopt.combinatorial.combinatorial import MIS
# Defining the problem, and converting it to a QUBO
G = nx.Graph()
G.add_edges_from([(0, 1), (1, 2), (2, 0)])
mis = MIS(G)
penalty = 10
qp = mis.penalty_method(penalty) # qp is a QUBO class in qiboopt
# Train 2 layers of regular QAOA
gammas = [0.1, 0.2]
betas = [0.3, 0.4]
output = qp.train_QAOA(gammas=gammas, betas=betas)
print(output)
Contact
To get in touch with the community and the developers, consider joining the Qibo workspace on Matrix:
If you have a question about the project, contact us at 📫.
Contributing
Contributions, issues and feature requests are welcome.
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 qiboopt-0.1.0.tar.gz.
File metadata
- Download URL: qiboopt-0.1.0.tar.gz
- Upload date:
- Size: 20.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9eb149077a2fdce6dee2461f2b5c439620bfdd0745e53bf99e3c05970e306914
|
|
| MD5 |
c162dca1cdd441cdb55e587117fcb16d
|
|
| BLAKE2b-256 |
d15d345ab1676a7c639db874fc67e71321c0539ad69ef6de7dc0b8e92fcf4ac1
|
File details
Details for the file qiboopt-0.1.0-py3-none-any.whl.
File metadata
- Download URL: qiboopt-0.1.0-py3-none-any.whl
- Upload date:
- Size: 22.0 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
918888d51931e560525daf4b0dab56e1bb6420718be644b512a8a5752b9b3d76
|
|
| MD5 |
62842fcdbddcf1ddfc5557059197a792
|
|
| BLAKE2b-256 |
136a7df239932f984f15f215c1af4ffe0b42ce98e88f822454584f3d4ad5a278
|