sknrf.app.dataviewer.model.dataset module

Dataset (sknrf.model.dataviewer.dataset)

This module stores measurement data into a hierarchial HDF5 database consisting of the following organization.

  • Datagroup
    • Dataset1
      • v1

      • i1

      • z1

    • Dataset2
      • v1

      • i1

      • z1

    • DatasetN
      • v1

      • i1

      • z1

This ensures that related measurement datasets can be stored inside the same database datagroup.

See Also

sknrf.model.dataviewer.equation.EquationModel, sknrf.model.dataviewer.equation.SignalArray

sknrf.app.dataviewer.model.dataset.preview_plot(ds, get_func, item: str, filters: list, ax_model: AxesModel, plt_model: PlotModel, transform_type: Domain, options_map)
class sknrf.app.dataviewer.model.dataset.WCArray(bind, *args, readonly=False)

Bases: Dataset

Subclass of PyTables CArray designed to avoid numpy limitation that arrays cannot exceed 32 dimensions

classmethod create_array(ds, name, shape=None, dtype=None, data=None, **kwds)
class sknrf.app.dataviewer.model.dataset.IQFile(name, *args, mode='r', driver=None, libver=None, userblock_size=None, swmr=False, rdcc_nslots=None, rdcc_nbytes=None, rdcc_w0=None, track_order=None, fs_strategy=None, fs_persist=False, fs_threshold=1, fs_page_size=None, page_buf_size=None, min_meta_keep=0, min_raw_keep=0, locking=None, **kwds)

Bases: H5File

Database representation of an IQ Waveform

Parameters:
filenamestr

Absolute filename of the database.

modestr

‘r’ - read access, ‘w’ - write access, ‘a’ - append to existing database.

property iq
property header
property marker
static from_waveform(filename, iq_array, header_map)
to_waveform()
static from_txt(filename, i_filename, q_filename, config_filename)
to_txt(i_filename, q_filename, config_filename)
tostring()
class sknrf.app.dataviewer.model.dataset.DatasetIterator(dataset, step=1, sweep_enabled=True)

Bases: object

save(viz_bag, aux)
class sknrf.app.dataviewer.model.dataset.BaseWCArrayGroup(bind)

Bases: Group

class sknrf.app.dataviewer.model.dataset.SweepMapGroup(bind)

Bases: BaseWCArrayGroup

class sknrf.app.dataviewer.model.dataset.IndepMapGroup(bind)

Bases: BaseWCArrayGroup

class sknrf.app.dataviewer.model.dataset.DatasetModel(bind)

Bases: BaseWCArrayGroup

Database representation of a Dataset

property sweep_map
property sweep_shape
property indep_map
property ports
property duts
property videos
property time
property freq
property freq_m
property time_c
add(name, value)

Add new dataset.

Parameters:
namestr

Equation name.

valueth.Tensor
has_equation(name)

Returns true if dataset has existing equation name.

Parameters:
namestr

Equation name.

Returns:
bool

True if dataset has equation name, else False.

equation(name)

Gets the equation by name.

Parameters:
namestr

Equation name.

set_equation(name, value)

Sets the equation by name.

Parameters:
namestr

Equation name.

remove(name)

Remove the equation by name.

Parameters:
namestr

Equation name.

class sknrf.app.dataviewer.model.dataset.DatagroupModel(name=None, **kwargs)

Bases: H5File

Database representation of a Datagroup

Parameters:
name

Name of the file on disk, or file-like object. Note: for files created with the ‘core’ driver, HDF5 still requires this be non-empty.

mode

r Readonly, file must exist (default) r+ Read/write, file must exist w Create file, truncate if exists w- or x Create file, fail if exists a Read/write if exists, create otherwise

driver

Name of the driver to use. Legal values are None (default, recommended), ‘core’, ‘sec2’, ‘stdio’, ‘mpio’, ‘ros3’.

See also

h5py.File
add(name, ports=(), duts=(), mipis=(), videos=(), sweep_map={}, indep_map={}, **kwargs)

Add new dataset.

Parameters:
namestr

Dataset name.

portstuple

Ports to be included in measurement.

dutstuple

DUTS to be included in measurement.

mipituple

MIPIs to be included in measurement.

videotuple

Videos to be included in measurement.

sweeep_mapdict

Parametric sweeps stored inside the dataset.

indep_mapdict

Single measurement stored inside the dataset

has_dataset(name)

Returns true if datagroup has existing dataset name.

Parameters:
namestr

Dataset name.

Returns:
bool

True if datagroup has dataset name, else False.

dataset(name)

Gets the dataset by name.

Parameters:
namestr

Dataset name.

Returns:
DatasetModel

The selected dataset.

remove(name)

Remove the dataset by name.

Parameters:
namestr

Dataset name.

class sknrf.app.dataviewer.model.dataset.DatagroupTreeModel(parent=None, root={})

Bases: QStandardItemModel

headerData(self, section: int, orientation: PySide6.QtCore.Qt.Orientation, role: int = Instance(Qt.DisplayRole)) Any
flags(self, index: Union[PySide6.QtCore.QModelIndex, PySide6.QtCore.QPersistentModelIndex]) PySide6.QtCore.Qt.ItemFlag
appendRow(self, item: PySide6.QtGui.QStandardItem) None
appendRow(self, items: Sequence[PySide6.QtGui.QStandardItem]) None
removeRow(self, row: int, parent: Union[PySide6.QtCore.QModelIndex, PySide6.QtCore.QPersistentModelIndex] = Invalid(PySide6.QtCore.QModelIndex)) bool
selected()
Returns:
ndarray

The selected dictionary value based on the selected row.

set_selected(indices)

Set the selected dictionary value

Parameters:
indexQtCore.QModelIndex

The table row to be selected.

staticMetaObject = PySide6.QtCore.QMetaObject("DatagroupTreeModel" inherits "QStandardItemModel": Methods:   #79 type=Slot, signature=set_selected(int), parameters=int )