ExtIndexObject¶
- class scqubits.core.namedslots_array.ExtIndexObject(idx_entry, parameters, slot=None)[source]¶
Object used for enabling enhanced indexing in NamedSlotsNdarray. Handles a single idx_entry in multi-index
Methods
ExtIndexObject.__init__(idx_entry, parameters)ExtIndexObject.convert_to_np_idx_entry(idx_entry)Convert a generalized multi-index entry into a valid numpy multi-index entry, and returns that along with a str recording the idx_entry type
Handles value-based slices, converting a float or complex value based entry into the corresponding position-based entry
- Parameters:
idx_entry (int | integer | slice | Tuple[int] | List[int] | Tuple[int, integer] | List[integer] | Any | float | complex)
parameters (Parameters)
slot (int | None)
- convert_to_np_idx_entry(idx_entry)[source]¶
Convert a generalized multi-index entry into a valid numpy multi-index entry, and returns that along with a str recording the idx_entry type
- Return type:
Tuple[str,Union[int,integer,slice,Tuple[int],List[int],Tuple[int,integer],List[integer],Any]]- Parameters:
idx_entry (int | integer | slice | Tuple[int] | List[int] | Tuple[int, integer] | List[integer] | Any | float | complex)