qsim::
BasicGateFuser
#include <fuser_basic.h>
Stateless object with methods for aggregating
Gate
s into
GateFused
.
Summary
Measurement gates with equal times are fused together. User-defined controlled gates (controlled_by.size() > 0) and gates acting on more than two qubits are not fused. The template parameter Gate can be Gate type or a pointer to Gate type. This class is deprecated. It is recommended to use MultiQubitGateFuser from fuser_mqubit.h.
Inheritance
Inherits from: qsim::Fuser< IO, Gate >
Public types |
|
---|---|
GateFused
|
using
qsim::GateFused
< RGate >
|
Public static functions |
|
---|---|
FuseGates
(const
Parameter
& param, unsigned num_qubits, const std::vector<
Gate
> & gates)
|
std::vector<
GateFused
>
Stores sets of gates that can be applied together.
|
FuseGates
(const
Parameter
& param, unsigned num_qubits, const std::vector<
Gate
> & gates, const std::vector< unsigned > & times_to_split_at)
|
std::vector<
GateFused
>
Stores sets of gates that can be applied together.
|
FuseGates
(const
Parameter
& param, unsigned num_qubits, typename std::vector<
Gate
>::const_iterator gfirst, typename std::vector<
Gate
>::const_iterator glast)
|
std::vector<
GateFused
>
Stores sets of gates that can be applied together.
|
FuseGates
(const
Parameter
& param, unsigned num_qubits, typename std::vector<
Gate
>::const_iterator gfirst, typename std::vector<
Gate
>::const_iterator glast, const std::vector< unsigned > & times_to_split_at)
|
std::vector<
GateFused
>
Stores sets of gates that can be applied together.
|
Structs |
|
---|---|
qsim::
|
User-specified parameters for gate fusion. |
Public types
Public static functions
FuseGates
std::vector< GateFused > FuseGates( const Parameter & param, unsigned num_qubits, const std::vector< Gate > & gates )
Stores sets of gates that can be applied together.
Only one- and two-qubit gates will get fused. Gates fused with this method are not multiplied together until ApplyFusedGate is called on the output. To respect specific time boundaries while fusing gates, use the other version of this method below.
Details | |||||||
---|---|---|---|---|---|---|---|
Parameters |
|
||||||
Returns |
A vector of fused gate objects. Each element is a set of gates acting on a specific pair of qubits which can be applied as a group.
|
FuseGates
std::vector< GateFused > FuseGates( const Parameter & param, unsigned num_qubits, const std::vector< Gate > & gates, const std::vector< unsigned > & times_to_split_at )
Stores sets of gates that can be applied together.
Only one- and two-qubit gates will get fused. Gates fused with this method are not multiplied together until ApplyFusedGate is called on the output.
Details | |||||||||
---|---|---|---|---|---|---|---|---|---|
Parameters |
|
||||||||
Returns |
A vector of fused gate objects. Each element is a set of gates acting on a specific pair of qubits which can be applied as a group.
|
FuseGates
std::vector< GateFused > FuseGates( const Parameter & param, unsigned num_qubits, typename std::vector< Gate >::const_iterator gfirst, typename std::vector< Gate >::const_iterator glast )
Stores sets of gates that can be applied together.
Only one- and two-qubit gates will get fused. Gates fused with this method are not multiplied together until ApplyFusedGate is called on the output. To respect specific time boundaries while fusing gates, use the other version of this method below.
Details | |||||||
---|---|---|---|---|---|---|---|
Parameters |
|
||||||
Returns |
A vector of fused gate objects. Each element is a set of gates acting on a specific pair of qubits which can be applied as a group.
|
FuseGates
std::vector< GateFused > FuseGates( const Parameter & param, unsigned num_qubits, typename std::vector< Gate >::const_iterator gfirst, typename std::vector< Gate >::const_iterator glast, const std::vector< unsigned > & times_to_split_at )
Stores sets of gates that can be applied together.
Only one- and two-qubit gates will get fused. Gates fused with this method are not multiplied together until ApplyFusedGate is called on the output.
Details | |||||||||
---|---|---|---|---|---|---|---|---|---|
Parameters |
|
||||||||
Returns |
A vector of fused gate objects. Each element is a set of gates acting on a specific pair of qubits which can be applied as a group.
|