lyse.__main__.DataFrameModel¶
- class lyse.__main__.DataFrameModel(view, exp_config)[source]¶
Bases:
PyQt5.QtCore.QObject
Methods
__init__
(view, exp_config)add_files
(filepaths, new_row_data[, done])Add files to the dataframe model.
blockSignals
(self, b)childEvent
(self, a0)children
(self)connectNotify
(self, signal)customEvent
(self, a0)deleteLater
(self)disconnect
(-> bool)disconnectNotify
(self, signal)dumpObjectInfo
(self)dumpObjectTree
(self)dynamicPropertyNames
(self)event
(self, a0)eventFilter
(self, a0, a1)findChild
(-> QObject)findChildren
(...)Returns the filepath of the first shot in the model that has not been analysed
Convert columns in the dataframe with dtype 'object' into compatible, more specific types, if possible.
inherits
(self, classname)installEventFilter
(self, a0)isSignalConnected
(self, signal)isWidgetType
(self)isWindowType
(self)killTimer
(self, id)mark_as_deleted_off_disk
(filepath)metaObject
(self)moveToThread
(self, thread)new_row
(filepath[, done])objectName
(self)on_double_click
(index)parent
(self)property
(self, name)pyqtConfigure
(...)Each keyword argument is either the name of a Qt property or a Qt signal.
receivers
(self, signal)removeEventFilter
(self, a0)remove_selection
([confirm])renumber_rows
([add_from])Add/update row indices - the rows are numbered in simple sequential order for easy comparison with the dataframe.
sender
(self)senderSignalIndex
(self)setObjectName
(self, name)setParent
(self, a0)setProperty
(self, name, value)set_columns_visible
(columns_visible)set_status_percent
(filepath, status_percent)signalsBlocked
(self)startTimer
(self, interval[, timerType])thread
(self)timerEvent
(self, a0)tr
(self, sourceText[, disambiguation, n])Pads the keys and values of our lists of column names so that they still match those in the dataframe after the number of levels in its multiindex has increased (the number of levels never decreases, given the current implementation of concat_with_padding())
update_row
(filepath[, ...])"Updates a row in the dataframe and Qt model to the data in the HDF5 file for that shot.
Attributes
destroyed
typing.Optional[QObject] = None) [signal]
objectNameChanged
str) [signal]
staticMetaObject
- COL_FILEPATH = 1¶
- COL_STATUS = 0¶
- ROLE_DELETED_OFF_DISK = 258¶
- ROLE_STATUS_PERCENT = 257¶
- add_files(filepaths, new_row_data, done=False)[source]¶
Add files to the dataframe model. New_row_data should be a dataframe containing the new rows.
- columns_changed¶
- get_first_incomplete()[source]¶
Returns the filepath of the first shot in the model that has not been analysed
- infer_objects()[source]¶
Convert columns in the dataframe with dtype ‘object’ into compatible, more specific types, if possible. This improves pickling performance and ensures multishot analysis code does not encounter columns with dtype ‘object’ for non-mixed numerical data, which it might choke on.
- renumber_rows(add_from=0)[source]¶
Add/update row indices - the rows are numbered in simple sequential order for easy comparison with the dataframe. add_from allows you to only add numbers for new rows from the given index as a performance optimisation, though if the number of digits changes, all rows will still be renumbered. add_from should not be used if rows have been deleted.