qrunch.chemistry.ground_state_problem.calculators.vqe_creator
Module containing all the VQE (Variational Quantum Eigensolver) algorithms with chemistry-tailored defaults.
Functions
Create an ExcitationGateEstimator configured for BEAST-VQE (recommended default). |
|
Create an ExcitationGateSampler configured for BEAST-VQE (recommended default). |
|
Create an ExcitationGateEstimator configured for FAST-VQE (recommended default). |
|
Create an ExcitationGateSampler configured for FAST-VQE (recommended default). |
|
Create a FAST Gate selector creator, with chemistry defaults. |
|
Create a VQE algorithm creator. |
Classes
creator for all types of VQE algorithms. |
|
creator for all types of VQE algorithms. |
|
creator for all types of VQE algorithms. |
- class IterativeVqeCreator
Bases:
objectcreator for all types of VQE algorithms.
- static beast() BeastSecondQuantizationAdaptiveVqeCreator
Narrow the VQE type to BEAST-VQE (without orbital optimization) with chemistry defaults.
- Return type:
- static paired_electron_approximation() SecondQuantizationAdaptiveVqeCreator
Narrow to paired electron approximation version (without orbital optimization).
- Return type:
- static standard() SecondQuantizationAdaptiveVqeCreator
Narrow the VQE type to an adaptive VQE (defaults to FAST-VQE), with chemistry default settings.
An adaptive VQE is a VQE that grows the ansatz during the optimization, by selecting gates from a pool. The difference between FAST-VQE and other adaptive schemes, such as ADAPT-VQE (https://arxiv.org/pdf/1812.11173) is the gate selection strategy. FAST-VQE uses a heuristic strategy to select gates (either a heuristic gradient or heuristic selected CI), while ADAPT-VQE uses the exact gradient.
To use ADAPT-VQE instead of FAST-VQE, use the
with_gate_selector()method with a gate_selector created by following the adapt-path in the gate_selector_creator().- Return type:
- class OrbitalOptimizedIterativeVqeCreator
Bases:
objectcreator for all types of VQE algorithms.
- static beast() BeastSecondQuantizationAdaptiveOrbitalOptimizationVqeCreator
Narrow the VQE type to BEAST-VQE with orbital optimization with chemistry defaults.
BEAST-VQE is an iterative VQE (grows the ansatz during the optimization, by selecting gates from a pool), that is specific to bosonic encoding of paired electrons in molecular ground state energy problems.
In addition, the adaptive orbital optimization VQE also optimizes the molecular orbitals to find a better basis for the problem. This is particularly useful in the bosonic-encoding case, where the orbital optimization can significantly improve the accuracy of the results.
- static paired_electron_approximation() SecondQuantizationAdaptiveOrbitalOptimizationVqeCreator
Narrow to paired electron approximation version with orbital optimization.
It grows the ansatz during the optimization, by selecting gates from a pool, that is specific to bosonic encoding of paired electrons in molecular ground state energy problems. This enables a specialized gate set (only singles, corresponding to paired-excitations, are needed), and a highly simplified Hamiltonian whose expectation value can be measured only using three distinct measurement bases.
In addition, the adaptive orbital optimization VQE also optimizes the molecular orbitals to find a better basis for the problem. This is particularly useful in the bosonic-encoding case, where the orbital optimization can significantly improve the accuracy of the results.
- static standard() SecondQuantizationAdaptiveOrbitalOptimizationVqeCreator
Narrow the VQE type to an adaptive VQE (defaults to FAST-VQE), with chemistry default settings.
An adaptive VQE is a VQE that grows the ansatz during the optimization, by selecting gates from a pool. The difference between FAST-VQE and other adaptive schemes, such as ADAPT-VQE (https://arxiv.org/pdf/1812.11173) is the gate selection strategy. FAST-VQE uses a heuristic strategy to select gates (either a heuristic gradient or heuristic selected CI), while ADAPT-VQE uses the exact gradient.
To use ADAPT-VQE instead of FAST-VQE, use the
with_gate_selector()method with a gate_selector created by following the adapt-path in the gate_selector_creator().
- class VqeCreator
Bases:
objectcreator for all types of VQE algorithms.
- static fixed_ansatz() SecondQuantizationBasicVqeCreator
Narrow the VQE type to a basic VQE, with chemistry defaults.
A basic VQE is a VQE that does not grow the ansatz, but uses a fixed ansatz provided by the user.
- Return type:
- static iterative() IterativeVqeCreator
Narrow the VQE type to an iterative VQE (defaults to FAST-VQE), with chemistry default settings.
An adaptive VQE is a VQE that grows the ansatz during the optimization, by selecting gates from a pool. The difference between FAST-VQE and other adaptive schemes, such as ADAPT-VQE (https://arxiv.org/pdf/1812.11173) is the gate selection strategy. FAST-VQE uses a heuristic strategy to select gates (either a heuristic gradient or heuristic selected CI), while ADAPT-VQE uses the exact gradient.
To use ADAPT-VQE instead of FAST-VQE, use the
with_gate_selector()method with a gate_selector created by following the adapt-path in the gate_selector_creator().- Return type:
- static iterative_with_orbital_optimization() OrbitalOptimizedIterativeVqeCreator
Narrow to an iterative VQE with orbital optimization.
It defaults to OO-FAST-VQE, with chemistry default settings.
An adaptive VQE is a VQE that grows the ansatz during the optimization, by selecting gates from a pool. The difference between FAST-VQE and other adaptive schemes, such as ADAPT-VQE (https://arxiv.org/pdf/1812.11173) is the gate selection strategy. FAST-VQE uses a heuristic strategy to select gates (either a heuristic gradient or heuristic selected CI), while ADAPT-VQE uses the exact gradient.
To use ADAPT-VQE instead of FAST-VQE, use the
with_gate_selector()method with a gate_selector created by following the adapt-path in the gate_selector_creator().- Return type:
- chemistry_default_boson_estimator() ExcitationGateEstimator
Create an ExcitationGateEstimator configured for BEAST-VQE (recommended default).
- Return type:
- chemistry_default_boson_sampler() ExcitationGateSampler
Create an ExcitationGateSampler configured for BEAST-VQE (recommended default).
- Return type:
- chemistry_default_fermion_estimator() ExcitationGateEstimator
Create an ExcitationGateEstimator configured for FAST-VQE (recommended default).
- Return type:
- chemistry_default_fermion_sampler() ExcitationGateSampler
Create an ExcitationGateSampler configured for FAST-VQE (recommended default).
- Return type:
- fast_gate_selector_creator() FastGateSelectorCreator
Create a FAST Gate selector creator, with chemistry defaults. Configured for FAST-VQE (recommended default).
- Return type:
- vqe_creator() VqeCreator
Create a VQE algorithm creator.
- Return type: