diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 328d57b7..0aee96a2 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -5,7 +5,7 @@ We follow the general Qiskit contribution guidelines, which can be found in the Qiskit documentation: -https://qiskit.org/documentation/contributing_to_qiskit.html +https://github.com/Qiskit/qiskit/blob/main/CONTRIBUTING.md ## Contributing to Qiskit Algorithms @@ -61,8 +61,7 @@ please ensure that: to see the changes formatted output is as expected. You will find an index.html file in `docs\_build\html` and you can navigate from there. - Please note that the CI will run a spell check on the docstrings, as the text will - become part of the online [API Documentation](https://qiskit.org/documentation/). + Please note that the CI will run a spell check on the docstrings. You can run `make spell` locally to check the spelling, though you would need to [install pyenchant](https://pyenchant.github.io/pyenchant/install.html) and be using diff --git a/docs/getting_started.rst b/docs/getting_started.rst index 749588d5..8401e1d3 100644 --- a/docs/getting_started.rst +++ b/docs/getting_started.rst @@ -8,7 +8,7 @@ Installation ============ Qiskit Algorithms depends on the main Qiskit package which has its own -`Qiskit Getting Started `__ detailing the +`Qiskit installation instructions `__ detailing the installation options for Qiskit and its supported environments/platforms. You should refer to that first, before focusing on the additional installation instructions specific to Qiskit Algorithms. @@ -35,7 +35,7 @@ See :ref:`optional_installs` for more information. Since Qiskit Algorithms depends on Qiskit, and its latest changes may require new or changed features of Qiskit, you should first follow Qiskit's `"Install from source"` instructions - here `Qiskit Getting Started `__ + `here `__ .. raw:: html diff --git a/docs/tutorials/01_algorithms_introduction.ipynb b/docs/tutorials/01_algorithms_introduction.ipynb index e9fda19c..093d61f3 100644 --- a/docs/tutorials/01_algorithms_introduction.ipynb +++ b/docs/tutorials/01_algorithms_introduction.ipynb @@ -83,7 +83,7 @@ "\n", "Algorithms rely on the primitives to evaluate expectation values or sample circuits. The primitives can be based on a simulator or real device and can be used interchangeably in the algorithms, as they all implement the same interface.\n", "\n", - "In the VQE, we have to evaluate expectation values, so for example we can use the [qiskit.primitives.Estimator](https://qiskit.org/documentation/stubs/qiskit.primitives.Estimator.html) which is shipped with the default Qiskit installation." + "In the VQE, we have to evaluate expectation values, so for example we can use the [qiskit.primitives.Estimator](https://docs.quantum.ibm.com/api/qiskit/qiskit.primitives.Estimator) which is shipped with the default Qiskit installation." ] }, { @@ -101,7 +101,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "This estimator uses an exact, statevector simulation to evaluate the expectation values. We can also use a shot-based and noisy simulators or real backends instead. For more information of the simulators you can check out [Qiskit Aer](https://qiskit.github.io/qiskit-aer/apidocs/aer_primitives.html) and for the actual hardware [Qiskit IBM Runtime](https://qiskit.org/documentation/partners/qiskit_ibm_runtime/).\n", + "This estimator uses an exact, statevector simulation to evaluate the expectation values. We can also use a shot-based and noisy simulators or real backends instead. For more information of the simulators you can check out [Qiskit Aer](https://qiskit.github.io/qiskit-aer/apidocs/aer_primitives.html) and for the actual hardware [Qiskit IBM Runtime](https://docs.quantum.ibm.com/api/qiskit-ibm-runtime).\n", "\n", "With all the ingredients ready, we can now instantiate the VQE:" ] @@ -211,7 +211,7 @@ "\n", "To close off let's also change the estimator primitive inside the a VQE. Maybe you're satisfied with the simulation results and now want to use a shot-based simulator, or run on hardware!\n", "\n", - "In this example we're changing to a shot-based estimator, still using Qiskit's reference primitive. However, you could replace the primitive by e.g. Qiskit Aer's estimator ([qiskit_aer.primitives.Estimator](https://qiskit.github.io/qiskit-aer/stubs/qiskit_aer.primitives.Estimator.html#qiskit_aer.primitives.Estimator)) or even a real backend ([qiskit_ibm_runtime.Estimator](https://qiskit.org/documentation/partners/qiskit_ibm_runtime/stubs/qiskit_ibm_runtime.Estimator.html#qiskit_ibm_runtime.Estimator)).\n", + "In this example we're changing to a shot-based estimator, still using Qiskit's reference primitive. However, you could replace the primitive by e.g. Qiskit Aer's estimator ([qiskit_aer.primitives.Estimator](https://qiskit.github.io/qiskit-aer/stubs/qiskit_aer.primitives.Estimator.html#qiskit_aer.primitives.Estimator)) or even a real backend ([qiskit_ibm_runtime.Estimator](https://docs.quantum.ibm.com/api/qiskit-ibm-runtime/qiskit_ibm_runtime.Estimator)).\n", "\n", "For noisy loss functions, the SPSA optimizer typically performs well, so we also update the optimizer. See also the [noisy VQE tutorial](03_vqe_simulation_with_noise.ipynb) for more details on shot-based and noisy simulations." ] diff --git a/docs/tutorials/02_vqe_advanced_options.ipynb b/docs/tutorials/02_vqe_advanced_options.ipynb index d354f35f..d217b9eb 100644 --- a/docs/tutorials/02_vqe_advanced_options.ipynb +++ b/docs/tutorials/02_vqe_advanced_options.ipynb @@ -59,7 +59,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "The next step is to instantiate the `Estimator` of choice for the evaluation of expectation values within `VQE`. For simplicity, you can select the [qiskit.primitives.Estimator](https://qiskit.org/documentation/stubs/qiskit.primitives.Estimator.html#qiskit.primitives.Estimator) that comes as part of Qiskit." + "The next step is to instantiate the `Estimator` of choice for the evaluation of expectation values within `VQE`. For simplicity, you can select the [qiskit.primitives.Estimator](https://docs.quantum.ibm.com/api/qiskit/qiskit.primitives.Estimator) that comes as part of Qiskit." ] }, { diff --git a/docs/tutorials/03_vqe_simulation_with_noise.ipynb b/docs/tutorials/03_vqe_simulation_with_noise.ipynb index d3676da2..9aea68f7 100644 --- a/docs/tutorials/03_vqe_simulation_with_noise.ipynb +++ b/docs/tutorials/03_vqe_simulation_with_noise.ipynb @@ -15,7 +15,7 @@ "cell_type": "markdown", "metadata": {}, "source": [ - "The algorithm of choice is once again VQE, where the task consists on finding the minimum (ground state) energy of a Hamiltonian. As shown in previous tutorials, VQE takes in a qubit operator as input. Here, you will take a set of Pauli operators that were originally computed by Qiskit Nature for the H2 molecule, using the [SparsePauliOp](https://qiskit.org/documentation/stubs/qiskit.quantum_info.SparsePauliOp.html#sparsepauliop) class." + "The algorithm of choice is once again VQE, where the task consists on finding the minimum (ground state) energy of a Hamiltonian. As shown in previous tutorials, VQE takes in a qubit operator as input. Here, you will take a set of Pauli operators that were originally computed by Qiskit Nature for the H2 molecule, using the [SparsePauliOp](https://docs.quantum.ibm.com/api/qiskit/qiskit.quantum_info.SparsePauliOp) class." ] }, { @@ -396,7 +396,7 @@ "source": [ "You can notice that, while the noiseless simulation's result is closer to the exact reference value, there is still some difference. This is due to the sampling noise, introduced by limiting the number of shots to 1024. A larger number of shots would decrease this sampling error and close the gap between these two values.\n", "\n", - "As for the noise introduced by real devices (or simulated noise models), it could be tackled through a wide variety of error mitigation techniques. The [Qiskit Runtime Primitives](https://qiskit.org/documentation/partners/qiskit_ibm_runtime/) have enabled error mitigation through the `resilience_level` option. This option is currently available for remote simulators and real backends accessed via the Runtime Primitives, you can consult [this tutorial](https://qiskit.org/documentation/partners/qiskit_ibm_runtime/tutorials/Error-Suppression-and-Error-Mitigation.html) for further information." + "As for the noise introduced by real devices (or simulated noise models), it could be tackled through a wide variety of error mitigation techniques. The [Qiskit Runtime Primitives](https://docs.quantum.ibm.com/api/qiskit-ibm-runtime) have enabled error mitigation through the `resilience_level` option. This option is currently available for remote simulators and real backends accessed via the Runtime Primitives, you can consult [this documentation](https://docs.quantum.ibm.com/run/configure-error-mitigation) for further information." ] }, { diff --git a/docs/tutorials/06_grover.ipynb b/docs/tutorials/06_grover.ipynb index dfd3259c..79f0c855 100644 --- a/docs/tutorials/06_grover.ipynb +++ b/docs/tutorials/06_grover.ipynb @@ -6,7 +6,7 @@ "source": [ "# Grover's Algorithm and Amplitude Amplification\n", "\n", - "Grover's algorithm is one of the most famous quantum algorithms introduced by Lov Grover in 1996 \\[1\\]. It has initially been proposed for unstructured search problems, i.e. for finding a marked element in a unstructured database. However, Grover's algorithm is now a subroutine to several other algorithms, such as Grover Adaptive Search \\[2\\]. For the details of Grover's algorithm, please see [Grover's Algorithm](https://learn.qiskit.org/course/ch-algorithms/grovers-algorithm) in the Qiskit textbook.\n", + "Grover's algorithm is one of the most famous quantum algorithms introduced by Lov Grover in 1996 \\[1\\]. It has initially been proposed for unstructured search problems, i.e. for finding a marked element in a unstructured database. However, Grover's algorithm is now a subroutine to several other algorithms, such as Grover Adaptive Search \\[2\\]. For the details of Grover's algorithm, please see [Grover's Algorithm](https://github.com/Qiskit/textbook/blob/main/notebooks/ch-algorithms/grover.ipynb) in the Qiskit textbook.\n", "\n", "Qiskit implements Grover's algorithm in the `Grover` class. This class also includes the generalized version, Amplitude Amplification \\[3\\], and allows setting individual iterations and other meta-settings to Grover's algorithm.\n", "\n", diff --git a/docs/tutorials/10_pvqd.ipynb b/docs/tutorials/10_pvqd.ipynb index fd48fe49..b669286c 100644 --- a/docs/tutorials/10_pvqd.ipynb +++ b/docs/tutorials/10_pvqd.ipynb @@ -14,7 +14,7 @@ "\\theta_{n+1} = \\theta_n + \\arg\\min_{\\delta\\theta} 1 - |\\langle\\phi(\\theta_n + \\delta\\theta)|e^{-i\\Delta_t H}|\\phi(\\theta_n)\\rangle|^2,\n", "$$\n", "\n", - "where $e^{-i\\Delta_t H}$ is calculated with a Trotter expansion (using e.g. the [PauliEvolutionGate](https://qiskit.org/documentation/stubs/qiskit.circuit.library.PauliEvolutionGate.html) in Qiskit!).\n", + "where $e^{-i\\Delta_t H}$ is calculated with a Trotter expansion (using e.g. the [PauliEvolutionGate](https://docs.quantum.ibm.com/api/qiskit/qiskit.circuit.library.PauliEvolutionGate) in Qiskit!).\n", "\n", "The following tutorial explores the p-VQD algorithm, which is available as the [PVQD](https://qiskit-community.github.io/qiskit-algorithms/stubs/qiskit_algorithms.PVQD.html) class. For details on the algorithm, see the original paper: [Barison et al. Quantum 5, 512 (2021)](https://quantum-journal.org/papers/q-2021-07-28-512/#)." ] diff --git a/docs/tutorials/12_gradients_framework.ipynb b/docs/tutorials/12_gradients_framework.ipynb index 24b693d8..acfa946e 100644 --- a/docs/tutorials/12_gradients_framework.ipynb +++ b/docs/tutorials/12_gradients_framework.ipynb @@ -10,7 +10,7 @@ }, "source": [ "# Gradient Framework\n", - "This tutorial demonstrates the use of the `qiskit_algorithms.gradients` module to evaluate quantum gradients using the [Qiskit Primitives](https://qiskit.org/documentation/apidoc/primitives.html).\n", + "This tutorial demonstrates the use of the `qiskit_algorithms.gradients` module to evaluate quantum gradients using the [Qiskit Primitives](https://docs.quantum.ibm.com/api/qiskit/primitives).\n", "\n", "## Introduction\n", "The gradient frameworks allows the evaluation of quantum gradients (see [Schuld et al.](https://journals.aps.org/pra/abstract/10.1103/PhysRevA.99.032331) and [Mari et al.](https://journals.aps.org/pra/abstract/10.1103/PhysRevA.103.012405)).\n", diff --git a/docs/tutorials/13_trotterQRTE.ipynb b/docs/tutorials/13_trotterQRTE.ipynb index 9ac01562..c53038e5 100644 --- a/docs/tutorials/13_trotterQRTE.ipynb +++ b/docs/tutorials/13_trotterQRTE.ipynb @@ -49,7 +49,7 @@ "| $\\ldots$ | $\\ldots$ |\n", "| $\\lvert 1 1 1 1 \\rangle$ | $\\downarrow\\downarrow\\downarrow\\downarrow$ |\n", "\n", - "First, we will create a function that takes in the system parameters $L$, $J$, $h$ and $\\alpha$, and returns our Hamiltonian as a `SparsePauliOp`. A [SparsePauliOp](https://qiskit.org/documentation/stubs/qiskit.quantum_info.SparsePauliOp.html) is a sparse representation of an operator in terms of weighted [Pauli](https://qiskit.org/documentation/stubs/qiskit.quantum_info.Pauli.html) terms." + "First, we will create a function that takes in the system parameters $L$, $J$, $h$ and $\\alpha$, and returns our Hamiltonian as a `SparsePauliOp`. A [SparsePauliOp](https://docs.quantum.ibm.com/api/qiskit/qiskit.quantum_info.SparsePauliOp) is a sparse representation of an operator in terms of weighted [Pauli](https://docs.quantum.ibm.com/api/qiskit/qiskit.quantum_info.Pauli) terms." ] }, { @@ -198,7 +198,7 @@ "id": "6b207d17-7633-40b6-b70e-3788966c4fb8", "metadata": {}, "source": [ - "By sequentially decomposing the circuit, we can show it in terms of Qiskit's [Circuit Library](https://qiskit.org/documentation/apidoc/circuit_library.html) standard gates." + "By sequentially decomposing the circuit, we can show it in terms of Qiskit's [Circuit Library](https://docs.quantum.ibm.com/api/qiskit/circuit_library) standard gates." ] }, { @@ -547,7 +547,7 @@ "\\vert \\psi(t) \\rangle = e^{-i H t} \\vert \\psi(0) \\rangle \\text{,}\n", "$$\n", "\n", - "on each one of the timesteps used by Trotter. We compute this exponential using SciPy's [linalg.expm](https://docs.scipy.org/doc/scipy/reference/generated/scipy.linalg.expm.html) function, and then we let the initial system evolve using the `Statevector`'s [evolve](https://qiskit.org/documentation/stubs/qiskit.quantum_info.Statevector.evolve.html) method. This becomes too costly to be performed on larger systems very quickly." + "on each one of the timesteps used by Trotter. We compute this exponential using SciPy's [linalg.expm](https://docs.scipy.org/doc/scipy/reference/generated/scipy.linalg.expm.html) function, and then we let the initial system evolve using the `Statevector`'s [evolve](https://docs.quantum.ibm.com/api/qiskit/qiskit.quantum_info.Statevector#evolve) method. This becomes too costly to be performed on larger systems very quickly." ] }, { @@ -646,7 +646,7 @@ "source": [ "### Product formula overview\n", "\n", - "If it isn't specified, the default product formula that `TrotterQRTE` uses is the Lie product formula [2], which is at first order. In Qiskit this is implemented in the [LieTrotter](https://qiskit.org/documentation/stubs/qiskit.synthesis.LieTrotter.html) class. A first order formula consists of the approximation stated in the introduction, where the matrix exponential of a sum is approximated by a product of matrix exponentials:\n", + "If it isn't specified, the default product formula that `TrotterQRTE` uses is the Lie product formula [2], which is at first order. In Qiskit this is implemented in the [LieTrotter](https://docs.quantum.ibm.com/api/qiskit/qiskit.synthesis.LieTrotter) class. A first order formula consists of the approximation stated in the introduction, where the matrix exponential of a sum is approximated by a product of matrix exponentials:\n", "\n", "$$\n", "e^{A+B} \\approx e^A e^B\n", @@ -729,7 +729,7 @@ "id": "ad8c6b98-eb15-497f-ba17-35402c0f8a22", "metadata": {}, "source": [ - "There exists a second-order formula, called the Suzuki-Trotter decomposition [3], and can be used in Qiskit by means of the [SuzukiTrotter class](https://qiskit.org/documentation/stubs/qiskit.synthesis.SuzukiTrotter.html). Using this formula, a second order decomposition is:\n", + "There exists a second-order formula, called the Suzuki-Trotter decomposition [3], and can be used in Qiskit by means of the [SuzukiTrotter class](https://docs.quantum.ibm.com/api/qiskit/qiskit.synthesis.SuzukiTrotter). Using this formula, a second order decomposition is:\n", "\n", "$$\n", "e^{A+B} \\approx e^{B/2}e^{A}e^{B/2}\n", diff --git a/qiskit_algorithms/__init__.py b/qiskit_algorithms/__init__.py index e97da0ae..11bcab11 100644 --- a/qiskit_algorithms/__init__.py +++ b/qiskit_algorithms/__init__.py @@ -1,6 +1,6 @@ # This code is part of a Qiskit project. # -# (C) Copyright IBM 2018, 2023. +# (C) Copyright IBM 2018, 2024. # # This code is licensed under the Apache License, Version 2.0. You may # obtain a copy of this license in the LICENSE.txt file in the root directory @@ -15,7 +15,7 @@ Qiskit Algorithms (:mod:`qiskit_algorithms`) ============================================ Qiskit Algorithms is a library of quantum algorithms for quantum computing with -`Qiskit `_. +`Qiskit `__. These algorithms can be used to carry out research and investigate how to solve problems in different domains on simulators and near-term real quantum devices using shallow circuits. @@ -31,7 +31,7 @@ time evolution and quantum machine learning. The quantum algorithms here all use -`Primitives `__ +`Primitives `__ to execute quantum circuits. This can be an ``Estimator``, which computes expectation values, or a ``Sampler`` which computes probability distributions. Refer to the specific algorithm for more information in this regard. diff --git a/setup.py b/setup.py index 9c347992..7f177714 100644 --- a/setup.py +++ b/setup.py @@ -50,7 +50,7 @@ long_description_content_type="text/markdown", url="https://github.com/qiskit-community/qiskit-algorithms", author="Qiskit Algorithms Development Team", - author_email="hello@qiskit.org", + author_email="qiskit@us.ibm.com", license="Apache-2.0", classifiers=[ "Environment :: Console",