BasisGateLibrary¶
- class BasisGateLibrary(basis_gates=None, default_values=None, **extra_kwargs)[source]¶
 A base class for libraries of basis gates to make it easier to setup Calibrations.
Setup the library.
- Parameters:
 basis_gates (List[str] | None) – The basis gates to generate.
default_values (Dict | None) – A dictionary to override library default parameter values.
extra_kwargs – Extra key-word arguments of the subclasses that are saved to be able to reconstruct the library using the
__init__()method.
- Raises:
 CalibrationError – If on of the given basis gates is not supported by the library.
Attributes
- basis_gates¶
 Return the basis gates supported by the library.
Methods
- abstract default_values()[source]¶
 Return the default values for the parameters.
- Returns
 A list of tuples is returned. These tuples are structured so that instances of
Calibrationscan callCalibrations.add_parameter_value()on the tuples.
- Return type:
 List[DefaultCalValue]
- classmethod from_config(config)[source]¶
 Deserialize the library given the input dictionary
- Return type:
 
- get(k[, d]) D[k] if k in D, else d. d defaults to None.¶
 
- items() a set-like object providing a view on D's items¶
 
- keys() a set-like object providing a view on D's keys¶
 
- num_qubits(name)[source]¶
 Return the number of qubits that the schedule with the given name acts on.
- Return type:
 int
- values() an object providing a view on D's values¶