qdk_chemistry.algorithms.term_grouper.base module
Abstract base class and factory for term-grouper algorithms.
- class qdk_chemistry.algorithms.term_grouper.base.TermGrouper[source]
Bases:
AlgorithmAbstract base class for algorithms that partition Hamiltonian terms.
A
TermGrouperconsumes aQubitOperatorand returns a newQubitOperatorwhoseterm_partitionis populated with the grouping computed by the strategy.Subclasses implement
_run_impl, which must return a newQubitOperator(the input must not be mutated).
- class qdk_chemistry.algorithms.term_grouper.base.TermGrouperFactory[source]
Bases:
AlgorithmFactoryFactory for
TermGrouperinstances.