-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Reorganize docs * Better handle dynamic dispatch * Apply my suggestions from code review * Move `generate_ansatz_from_circuit` doc to ansatz_generation page * Fix title overline * Remove root doc page --------- Co-authored-by: Jim Garrison <[email protected]> Co-authored-by: Jim Garrison <[email protected]>
- Loading branch information
1 parent
20c65c9
commit d0f790a
Showing
15 changed files
with
186 additions
and
84 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
{# | ||
We show all the class's methods and attributes on the same page. By default, we document | ||
all methods, including those defined by parent classes. | ||
-#} | ||
|
||
{{ objname | escape | underline }} | ||
|
||
.. currentmodule:: {{ module }} | ||
|
||
.. autoclass:: {{ objname }} | ||
:no-members: | ||
:no-inherited-members: | ||
:no-special-members: | ||
:show-inheritance: | ||
|
||
{% block attributes_summary %} | ||
{% if attributes %} | ||
.. rubric:: Attributes | ||
{% for item in attributes %} | ||
.. autoattribute:: {{ item }} | ||
{%- endfor %} | ||
{% endif %} | ||
{% endblock -%} | ||
|
||
{% block methods_summary %} | ||
{% set wanted_methods = (methods | reject('==', '__init__') | list) %} | ||
{% if wanted_methods %} | ||
.. rubric:: Methods | ||
{% for item in wanted_methods %} | ||
.. automethod:: {{ item }} | ||
{%- endfor %} | ||
{% endif %} | ||
{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,22 @@ | ||
.. _ansatz_generation: | ||
|
||
################# | ||
Ansatz Generation | ||
################# | ||
#################################################################### | ||
Ansatz generation (:mod:`qiskit_addon_aqc_tensor.ansatz_generation`) | ||
#################################################################### | ||
|
||
.. automodule:: qiskit_addon_aqc_tensor.ansatz_generation | ||
:no-members: | ||
:no-inherited-members: | ||
:no-special-members: | ||
:no-special-members: | ||
|
||
.. currentmodule:: qiskit_addon_aqc_tensor.ansatz_generation | ||
|
||
.. autosummary:: | ||
:toctree: ../stubs/ | ||
:nosignatures: | ||
|
||
AnsatzBlock | ||
OneQubitAnsatzBlock | ||
TwoQubitAnsatzBlock | ||
ZXZ | ||
KAK | ||
|
||
.. autofunction:: generate_ansatz_from_circuit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,12 @@ | ||
.. _aqctensor: | ||
|
||
.. module:: qiskit_addon_aqc_tensor | ||
|
||
======================== | ||
AQC-Tensor API Reference | ||
======================== | ||
========================================= | ||
``qiskit-addon-aqc-tensor`` API Reference | ||
========================================= | ||
|
||
.. toctree:: | ||
:maxdepth: 1 | ||
|
||
ansatz_generation | ||
objective | ||
simulation | ||
simulation-aer | ||
simulation-quimb |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,12 @@ | ||
.. _objective: | ||
|
||
################## | ||
Objective Function | ||
################## | ||
################################################################ | ||
Objective function(s) (:mod:`qiskit_addon_aqc_tensor.objective`) | ||
################################################################ | ||
|
||
.. automodule:: qiskit_addon_aqc_tensor.objective | ||
:no-members: | ||
:no-inherited-members: | ||
:no-special-members: | ||
|
||
.. currentmodule:: qiskit_addon_aqc_tensor.objective | ||
|
||
.. autoclass:: OneMinusFidelity |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
###################################################################### | ||
Aer simulation backend (:mod:`qiskit_addon_aqc_tensor.simulation.aer`) | ||
###################################################################### | ||
|
||
.. automodule:: qiskit_addon_aqc_tensor.simulation.aer | ||
:no-members: | ||
:no-inherited-members: | ||
:no-special-members: | ||
|
||
.. autosummary:: | ||
:toctree: ../stubs/ | ||
:nosignatures: | ||
|
||
QiskitAerMPS | ||
QiskitAerSimulationSettings | ||
|
||
Functions | ||
========= | ||
|
||
.. autofunction:: is_aer_available |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
########################################################################## | ||
Quimb simulation backend (:mod:`qiskit_addon_aqc_tensor.simulation.quimb`) | ||
########################################################################## | ||
|
||
.. automodule:: qiskit_addon_aqc_tensor.simulation.quimb | ||
:no-members: | ||
:no-inherited-members: | ||
:no-special-members: | ||
|
||
.. autosummary:: | ||
:toctree: ../stubs/ | ||
:nosignatures: | ||
|
||
QuimbCircuitFactory | ||
QuimbSimulator | ||
QiskitQuimbConversionContext | ||
|
||
Functions | ||
========= | ||
|
||
.. autofunction:: is_quimb_available | ||
.. autofunction:: qiskit_ansatz_to_quimb | ||
.. autofunction:: recover_parameters_from_quimb | ||
.. autofunction:: tnoptimizer_objective_kwargs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,35 @@ | ||
.. _simulation: | ||
|
||
######################### | ||
Tensor Network Simulation | ||
######################### | ||
##################################################################### | ||
Tensor network simulation (:mod:`qiskit_addon_aqc_tensor.simulation`) | ||
##################################################################### | ||
|
||
.. automodule:: qiskit_addon_aqc_tensor.simulation | ||
:no-members: | ||
:no-inherited-members: | ||
:no-special-members: | ||
|
||
.. currentmodule:: qiskit_addon_aqc_tensor.simulation | ||
|
||
Available backends | ||
================== | ||
|
||
* :mod:`qiskit_addon_aqc_tensor.simulation.aer` | ||
* :mod:`qiskit_addon_aqc_tensor.simulation.quimb` | ||
|
||
Functions | ||
========= | ||
|
||
The following functions provide a common interface that can be used with any supported backend. Regardless of which backend you use, you will invoke these functions as a common interface. | ||
|
||
In each function below, the documentation shows every distinct implementation available for that function. The addon will choose which implementation to use based on the types of the arguments that you provide. (This paradigm is called "multiple dispatch".) | ||
|
||
.. autofunction:: tensornetwork_from_circuit | ||
.. autofunction:: apply_circuit_to_state | ||
.. autofunction:: compute_overlap | ||
|
||
Abstract classes | ||
================ | ||
|
||
These are abstract classes, implemented by each backend. | ||
|
||
.. autoclass:: TensorNetworkState | ||
.. autoclass:: TensorNetworkSimulationSettings |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.