qiskit-documentation/docs/api/qiskit/0.29/qiskit.aqua.components.mdx

41 lines
7.6 KiB
Plaintext

---
title: components (v0.29)
description: API reference for qiskit.aqua.components in qiskit v0.29
in_page_toc_min_heading_level: 2
python_api_type: module
python_api_name: qiskit.aqua.components
---
<span id="module-qiskit.aqua.components" />
<span id="qiskit-aqua-components" />
<span id="components-qiskit-aqua-components" />
# Components
`qiskit.aqua.components`
Components were designed to be swappable sub-parts of an algorithm. Different implementations of a component type can thereby be exchanged to potentially alter the behavior and outcome of the algorithm. For example [`VQE`](qiskit.aqua.algorithms.VQE "qiskit.aqua.algorithms.VQE") takes an [`Optimizer`](qiskit.aqua.components.optimizers.Optimizer "qiskit.aqua.components.optimizers.Optimizer") and a [`VariationalForm`](qiskit.aqua.components.variational_forms.VariationalForm "qiskit.aqua.components.variational_forms.VariationalForm") components. There are a selection of both different [`optimizers`](qiskit.aqua.components.optimizers#module-qiskit.aqua.components.optimizers "qiskit.aqua.components.optimizers") and [`variational_forms`](qiskit.aqua.components.variational_forms#module-qiskit.aqua.components.variational_forms "qiskit.aqua.components.variational_forms") that can be chosen from according the nature of the problem. Some optimizers use gradients, others have alternative techniques to finding a minimum. Variational forms include heuristic ansatzes such as [`EfficientSU2`](qiskit.circuit.library.EfficientSU2 "qiskit.circuit.library.EfficientSU2") and types designed for specific problems such as [`UCCSD`](qiskit.chemistry.components.variational_forms.UCCSD "qiskit.chemistry.components.variational_forms.UCCSD") for chemistry and ground state energy computation.
Components may also be used in other components. For example the [`UnivariateVariationalDistribution`](qiskit.aqua.components.uncertainty_models.UnivariateVariationalDistribution "qiskit.aqua.components.uncertainty_models.UnivariateVariationalDistribution") takes a [`VariationalForm`](qiskit.aqua.components.variational_forms.VariationalForm "qiskit.aqua.components.variational_forms.VariationalForm").
Each type of component has a base class that can be extended to provide a new implementation. For example the base class for [`variational_forms`](qiskit.aqua.components.variational_forms#module-qiskit.aqua.components.variational_forms "qiskit.aqua.components.variational_forms") is [`VariationalForm`](qiskit.aqua.components.variational_forms.VariationalForm "qiskit.aqua.components.variational_forms.VariationalForm"). For more information refer to the component type of interest below.
# Submodules
| | |
| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [`eigs`](qiskit.aqua.components.eigs#module-qiskit.aqua.components.eigs "qiskit.aqua.components.eigs") | Eigenvalues ([`qiskit.aqua.components.eigs`](qiskit.aqua.components.eigs#module-qiskit.aqua.components.eigs "qiskit.aqua.components.eigs")) |
| [`feature_maps`](qiskit.aqua.components.feature_maps#module-qiskit.aqua.components.feature_maps "qiskit.aqua.components.feature_maps") | Feature Maps ([`qiskit.aqua.components.feature_maps`](qiskit.aqua.components.feature_maps#module-qiskit.aqua.components.feature_maps "qiskit.aqua.components.feature_maps")) |
| [`initial_states`](qiskit.aqua.components.initial_states#module-qiskit.aqua.components.initial_states "qiskit.aqua.components.initial_states") | Initial States ([`qiskit.aqua.components.initial_states`](qiskit.aqua.components.initial_states#module-qiskit.aqua.components.initial_states "qiskit.aqua.components.initial_states")) |
| [`multiclass_extensions`](qiskit.aqua.components.multiclass_extensions#module-qiskit.aqua.components.multiclass_extensions "qiskit.aqua.components.multiclass_extensions") | Multi-class Extensions ([`qiskit.aqua.components.multiclass_extensions`](qiskit.aqua.components.multiclass_extensions#module-qiskit.aqua.components.multiclass_extensions "qiskit.aqua.components.multiclass_extensions")) |
| [`neural_networks`](qiskit.aqua.components.neural_networks#module-qiskit.aqua.components.neural_networks "qiskit.aqua.components.neural_networks") | Neural Networks ([`qiskit.aqua.components.neural_networks`](qiskit.aqua.components.neural_networks#module-qiskit.aqua.components.neural_networks "qiskit.aqua.components.neural_networks")) |
| [`optimizers`](qiskit.aqua.components.optimizers#module-qiskit.aqua.components.optimizers "qiskit.aqua.components.optimizers") | Optimizers ([`qiskit.aqua.components.optimizers`](qiskit.aqua.components.optimizers#module-qiskit.aqua.components.optimizers "qiskit.aqua.components.optimizers")) |
| [`oracles`](qiskit.aqua.components.oracles#module-qiskit.aqua.components.oracles "qiskit.aqua.components.oracles") | Oracles ([`qiskit.aqua.components.oracles`](qiskit.aqua.components.oracles#module-qiskit.aqua.components.oracles "qiskit.aqua.components.oracles")) |
| [`reciprocals`](qiskit.aqua.components.reciprocals#module-qiskit.aqua.components.reciprocals "qiskit.aqua.components.reciprocals") | Reciprocals ([`qiskit.aqua.components.reciprocals`](qiskit.aqua.components.reciprocals#module-qiskit.aqua.components.reciprocals "qiskit.aqua.components.reciprocals")) |
| [`uncertainty_models`](qiskit.aqua.components.uncertainty_models#module-qiskit.aqua.components.uncertainty_models "qiskit.aqua.components.uncertainty_models") | Uncertainty Models ([`qiskit.aqua.components.uncertainty_models`](qiskit.aqua.components.uncertainty_models#module-qiskit.aqua.components.uncertainty_models "qiskit.aqua.components.uncertainty_models")) |
| [`uncertainty_problems`](qiskit.aqua.components.uncertainty_problems#module-qiskit.aqua.components.uncertainty_problems "qiskit.aqua.components.uncertainty_problems") | Uncertainty Problems ([`qiskit.aqua.components.uncertainty_problems`](qiskit.aqua.components.uncertainty_problems#module-qiskit.aqua.components.uncertainty_problems "qiskit.aqua.components.uncertainty_problems")) |
| [`variational_forms`](qiskit.aqua.components.variational_forms#module-qiskit.aqua.components.variational_forms "qiskit.aqua.components.variational_forms") | Variational Forms ([`qiskit.aqua.components.variational_forms`](qiskit.aqua.components.variational_forms#module-qiskit.aqua.components.variational_forms "qiskit.aqua.components.variational_forms")) |