[trackingdata] more logging, cleanup
This commit is contained in:
parent
4762921ccd
commit
c231b52876
@ -61,7 +61,7 @@ class TrackingData(QObject):
|
||||
self._indices = np.where((self._data[col] >= self._start) & (self._data[col] < self._stop))[0]
|
||||
|
||||
def selectedData(self, col):
|
||||
return self._data[col][self._indices]
|
||||
return self[col][self._indices]
|
||||
|
||||
def setUserSelection(self, ids):
|
||||
"""
|
||||
@ -84,14 +84,20 @@ class TrackingData(QObject):
|
||||
userFlag : bool
|
||||
Should the "userlabeled" state of the detections be set to True or False?
|
||||
"""
|
||||
self._data["track"][self._user_selections] = track_id
|
||||
self["track"][self._user_selections] = track_id
|
||||
self.setAssignmentStatus(userFlag)
|
||||
|
||||
def setAssignmentStatus(self, isTrue: bool):
|
||||
self._data["userlabeled"][self._user_selections] = isTrue
|
||||
logging.debug("TrackingData:Re-setting assignment status of user selected data to %s", str(isTrue))
|
||||
self["userlabeled"][self._user_selections] = isTrue
|
||||
|
||||
def revertAssignmentStatus(self):
|
||||
self._data["userlabeled"][:] = False
|
||||
logging.debug("TrackingData:Un-setting assignment status of all data!")
|
||||
self["userlabeled"][:] = False
|
||||
|
||||
def revertTrackAssignments(self):
|
||||
logging.debug("TrackingData: Reverting all track assignments!")
|
||||
self["track"][:] = -1
|
||||
|
||||
def deleteDetections(self):
|
||||
# from IPython import embed
|
||||
@ -116,7 +122,7 @@ class TrackingData(QObject):
|
||||
None
|
||||
"""
|
||||
if len(tracks) != self.numDetections:
|
||||
logging.error("DataController: Size of passed tracks does not match data!")
|
||||
logging.error("Trackingdata: Size of passed tracks does not match data!")
|
||||
return
|
||||
self._data["track"] = tracks
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user