Skip to content

Commit

Permalink
Merge pull request #189 from entropicalabs/dev
Browse files Browse the repository at this point in the history
Dev
  • Loading branch information
vishal-ph authored Feb 23, 2023
2 parents 63ee40e + 78f2c59 commit e1c904a
Show file tree
Hide file tree
Showing 121 changed files with 12,166 additions and 6,678 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/test_dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ jobs:
run: |
source env/bin/activate
ipython kernel install --name "env" --user
python -m pytest -v -m 'not (qpu or api)' --cov --cov-report=xml:coverage.xml
python -m pytest -v -m 'not (qpu or api or docker_aws)' --cov --cov-report=xml:coverage.xml
- name: Upload coverage reports to Codecov with GitHub Action
uses: codecov/codecov-action@v3
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test_main_linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ jobs:
run: |
source env/bin/activate
ipython kernel install --name "env" --user
python -m pytest -v -m 'not (qpu or api)'
python -m pytest -v -m 'not (qpu or api or docker_aws)'
- name: Upload coverage reports to Codecov with GitHub Action
uses: codecov/codecov-action@v3
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test_main_macos.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,4 +56,4 @@ jobs:
run: |
source env/bin/activate
ipython kernel install --user --name "env"
python -m pytest -v -m 'not (qpu or api)'
python -m pytest -v -m 'not (qpu or api or docker_aws)'
2 changes: 1 addition & 1 deletion .github/workflows/test_main_windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,4 +68,4 @@ jobs:
run: |
.\env\Scripts\Activate.ps1
ipython kernel install --name "env" --user
python -m pytest -v -m 'not (qpu or api)'
python -m pytest -v -m 'not (qpu or api or docker_aws)'
8 changes: 7 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -132,4 +132,10 @@ dmypy.json
/.idea/

# Mac Stuff
*.DS_Store
*.DS_Store

# Braket files
braket-job*/

# Visual Studio code
.vscode/
39 changes: 39 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,42 @@
## Version v0.1.1 (February 23rd, 2023)

This release brings the following new features:
* The ability to plug in custom qubit routing solutions for QAOA circuits.
* AWS managed jobs are now supported through OpenQAOA

## What's Changed

* Refactor
* The new `GateMapLabel` introduces an updated and a more consistent way to label QAOA gates in the circuit.
* New Features
* OpenQAOA now supports specifying custom qubit routing algorithms in an expected format in the QAOA workflow. This is implemented in https://github.com/entropicalabs/openqaoa/pull/179


## Version v0.1.0 (February 17th, 2023)

This release brings major changes to the structure of OpenQAOA.
This is OpenQAOA's first major release! V0.1.0 contains many new features and quite a few **breaking changes** :)

**notice**: the license has been changed from `apache 2.0` to `MIT`

## What's Changed

* Refactor
* The code underwent a considerable refactoring effort. The most noticeable change is in the new `openqaoa-core` and other library plugins in the form `openqaoa-xyz`.
* Refactor of the result objects for RQAOA / QAOA by @raulconchello in https://github.com/entropicalabs/openqaoa/pull/122
* New Features
* New backend: OpenQAOA is now compatible with Azure by @shahidee44 in https://github.com/entropicalabs/openqaoa/pull/167
* New circuit Ansatz: now OQ allows for the Alternating Operator Ansatz by @shahidee44 in https://github.com/entropicalabs/openqaoa/pull/85
* New backend: analytical formula for p=1 by @kidiki in https://github.com/entropicalabs/openqaoa/pull/147
* Shot Adaptative optimizers by @raulconchello in https://github.com/entropicalabs/openqaoa/pull/123
* Supporting PennyLane optimizers by @raulconchello in https://github.com/entropicalabs/openqaoa/pull/101
* JSON dumps methods for RQAOA / QAOA by @raulconchello in https://github.com/entropicalabs/openqaoa/pull/122
* Bug fixes
* Bugfix: QPU qubit overflow by @shahidee44 in https://github.com/entropicalabs/openqaoa/pull/108
* fix: Spelling of Oxford Quantum Circuits by @christianbmadsen in https://github.com/entropicalabs/openqaoa/pull/141
* Bugfix vanishing RQAOA instances after elimination by @kidiki in https://github.com/entropicalabs/openqaoa/pull/158


## Version v0.0.4 (November 14th, 2022)

This release brings improvements to RQAOA workflow and AWS authentication, and a bugfix to TSP problem class.
Expand Down
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,12 @@
[![Documentation Status](https://readthedocs.org/projects/el-openqaoa/badge/?version=latest)](https://el-openqaoa.readthedocs.io/en/latest/?badge=latest) <!-- Readthedocs -->
[![PyPI version](https://badge.fury.io/py/openqaoa.svg)](https://badge.fury.io/py/openqaoa) <!-- PyPI -->
[![arXiv](https://img.shields.io/badge/arXiv-2210.08695-<COLOR>.svg)](https://arxiv.org/abs/2210.08695) <!-- arXiv -->
[![License](https://img.shields.io/badge/%F0%9F%AA%AA%20license-Apache%20License%202.0-lightgrey)](LICENSE.md)<!-- License -->
[![License](https://img.shields.io/pypi/l/openqaoa)](LICENSE.md)<!-- License -->
[![Contributor Covenant](https://img.shields.io/badge/Contributor%20Covenant-2.1-4baaaa.svg)](CODE_OF_CONDUCT.md)<!-- Covenant Code of conduct -->
[![Downloads](https://pepy.tech/badge/openqaoa)](https://pepy.tech/project/openqaoa)
[![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/entropicalabs/openqaoa.git/main?labpath=%2Fexamples)
[![Discord](https://img.shields.io/discord/991258119525122058)](https://discord.gg/ana76wkKBd)
[![Website](https://img.shields.io/badge/OpenQAOA-Website-blueviolet)](https://openqaoa.entropicalabs.com/)
</div>

# OpenQAOA
Expand All @@ -23,6 +25,8 @@ A multi-backend python library for quantum optimization using QAOA on Quantum co

Please, consider [joining our discord](https://discord.gg/ana76wkKBd) if you want to be part of our community and participate in the OpenQAOA's development.

Check out OpenQAOA website [https://openqaoa.entropicalabs.com/](https://openqaoa.entropicalabs.com/)

## Installation instructions

You can install the latest version of OpenQAOA directly from PyPi. First, create a virtual environment with python3.8+ and then simply pip install openqaoa with the following command
Expand Down
46 changes: 25 additions & 21 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Configuration file for the Sphinx documentation builder.
# Configuration file for the Sphinx documentation builder.
#
# This file only contains a selection of the most common options. For a full
# list see the documentation:
Expand All @@ -11,27 +11,27 @@
# documentation root, use os.path.abspath to make it absolute, like shown here.
#
# import mock

# MOCK_MODULES = ['matplotlib', 'matplotlib.pyplot', 'numpy', 'scipy', 'networkx']
# for mod_name in MOCK_MODULES:
# sys.modules[mod_name] = mock.Mock()

import os
import sys

# sys.path.insert(0, os.path.abspath('.'))
# sys.path.insert(0, os.path.abspath("../../"))
sys.path.insert(0, os.path.abspath('../..'))
sys.path.insert(0, os.path.abspath("../.."))
print(sys.path)

# from openqaoa.qaoa_parameters.baseparams import shapedArray



# -- Project information -----------------------------------------------------

project = 'OpenQAOA'
copyright = '2022, Entropica Labs'
author = 'Entropica Labs'
project = "OpenQAOA"
copyright = "2022, Entropica Labs"
author = "Entropica Labs"


# -- General configuration ---------------------------------------------------
Expand All @@ -40,44 +40,48 @@
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
# ones.
extensions = [
'sphinx.ext.todo',
'sphinx.ext.viewcode',
'sphinx.ext.autodoc',
"sphinx.ext.todo",
"sphinx.ext.viewcode",
"sphinx.ext.autodoc",
"sphinx.ext.napoleon",
"sphinx_autodoc_typehints",
"sphinx.ext.mathjax",
"IPython.sphinxext.ipython_console_highlighting",
"nbsphinx",
"sphinx.ext.intersphinx"
"sphinx.ext.intersphinx",
]

# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
templates_path = ["_templates"]

# List of patterns, relative to source directory, that match files and
# directories to ignore when looking for source files.
# This pattern also affects html_static_path and html_extra_path.
exclude_patterns = ['.docs/source/notebooks/community_tutorials/*', '.docs/source/notebooks/X_dumping_data.ipynb']
exclude_patterns = [
".docs/source/notebooks/community_tutorials/*",
".docs/source/notebooks/X_dumping_data.ipynb",
]

intersphinx_mapping = {'python': ('https://docs.python.org/3', None),
'numpy': ('https://numpy.org/doc/1.23', None),
'np': ('https://numpy.org/doc/1.23', None),
'scipy': ('https://docs.scipy.org/doc/scipy-1.8.1', None)}
intersphinx_mapping = {
"python": ("https://docs.python.org/3", None),
"numpy": ("https://numpy.org/doc/1.23", None),
"np": ("https://numpy.org/doc/1.23", None),
"scipy": ("https://docs.scipy.org/doc/scipy-1.8.1", None),
}


# Exclude broken python docs
# see https://stackoverflow.com/questions/11417221/sphinx-autodoc-gives-warning-pyclass-reference-target-not-found-type-warning
nitpick_ignore = [('py:class', 'type')]

nitpick_ignore = [("py:class", "type")]


# -- Options for HTML output -------------------------------------------------

# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
#
html_theme = 'sphinx_rtd_theme'
html_logo = '../../.github/images/Entropica_logo.png'
html_theme = "sphinx_rtd_theme"
html_logo = "../../.github/images/Entropica_logo.png"
# html_favicon ='favicon.ico'

# Add any paths that contain custom static files (such as style sheets) here,
Expand Down
479 changes: 225 additions & 254 deletions examples/01_workflows_example.ipynb

Large diffs are not rendered by default.

858 changes: 696 additions & 162 deletions examples/03_qaoa_on_qpus.ipynb

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion examples/04_qaoa_variational_parameters.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -689,7 +689,7 @@
"kernelspec": {
"display_name": "Python 3 (ipykernel)",
"language": "python",
"name": "python3"
"name": "oq_reviews"
},
"language_info": {
"codemirror_mode": {
Expand Down
Loading

0 comments on commit e1c904a

Please sign in to comment.