[tracks] fix unsetting of userlabeled status ...
This commit is contained in:
parent
dc4833e825
commit
367cbb021f
@ -143,7 +143,6 @@ class FixTracks(QWidget):
|
|||||||
def on_autoClassify(self, tracks):
|
def on_autoClassify(self, tracks):
|
||||||
self._data.setSelectionRange("index", 0, self._data.numDetections)
|
self._data.setSelectionRange("index", 0, self._data.numDetections)
|
||||||
self._data.assignTracks(tracks)
|
self._data.assignTracks(tracks)
|
||||||
self._timeline.setDetectionData(self._data.data)
|
|
||||||
self.update()
|
self.update()
|
||||||
|
|
||||||
def on_dataSelection(self):
|
def on_dataSelection(self):
|
||||||
@ -172,7 +171,8 @@ class FixTracks(QWidget):
|
|||||||
ids = df.index.values.astype(int)
|
ids = df.index.values.astype(int)
|
||||||
frames = df["frame"].values.astype(int)
|
frames = df["frame"].values.astype(int)
|
||||||
self._detectionView.addDetections(coords, tracks, ids, frames, keypoint, self._brushes[name])
|
self._detectionView.addDetections(coords, tracks, ids, frames, keypoint, self._brushes[name])
|
||||||
|
|
||||||
|
self._timeline.setData(self._data)
|
||||||
start_frame = self._currentWindowPos
|
start_frame = self._currentWindowPos
|
||||||
stop_frame = start_frame + self._currentWindowWidth
|
stop_frame = start_frame + self._currentWindowWidth
|
||||||
self._controls_widget.setWindow(start_frame, stop_frame)
|
self._controls_widget.setWindow(start_frame, stop_frame)
|
||||||
@ -238,13 +238,11 @@ class FixTracks(QWidget):
|
|||||||
self._currentWindowWidth = self._windowspinner.value()
|
self._currentWindowWidth = self._windowspinner.value()
|
||||||
self._maxframes = self._data.max("frame")
|
self._maxframes = self._data.max("frame")
|
||||||
self.populateKeypointCombo(self._data.numKeypoints())
|
self.populateKeypointCombo(self._data.numKeypoints())
|
||||||
self._timeline.setDetectionData(self._data.data)
|
self._timeline.setData(self._data)
|
||||||
self._timeline.setWindow(self._currentWindowPos / self._maxframes,
|
self._timeline.setWindow(self._currentWindowPos / self._maxframes,
|
||||||
self._currentWindowWidth / self._maxframes)
|
self._currentWindowWidth / self._maxframes)
|
||||||
coordinates = self._data.coordinates()
|
coordinates = self._data.coordinates()
|
||||||
positions = self._data.centerOfGravity()
|
positions = self._data.centerOfGravity()
|
||||||
tracks = self._data["track"]
|
|
||||||
frames = self._data["frame"]
|
|
||||||
self._classifier.size_classifier.setCoordinates(coordinates)
|
self._classifier.size_classifier.setCoordinates(coordinates)
|
||||||
self._classifier.consistency_tracker.setData(self._data)
|
self._classifier.consistency_tracker.setData(self._data)
|
||||||
self.update()
|
self.update()
|
||||||
@ -280,19 +278,16 @@ class FixTracks(QWidget):
|
|||||||
def on_assignOne(self):
|
def on_assignOne(self):
|
||||||
logging.debug("Assigning user selection to track One")
|
logging.debug("Assigning user selection to track One")
|
||||||
self._data.assignUserSelection(self.trackone_id)
|
self._data.assignUserSelection(self.trackone_id)
|
||||||
self._timeline.setDetectionData(self._data.data)
|
|
||||||
self.update()
|
self.update()
|
||||||
|
|
||||||
def on_assignTwo(self):
|
def on_assignTwo(self):
|
||||||
logging.debug("Assigning user selection to track Two")
|
logging.debug("Assigning user selection to track Two")
|
||||||
self._data.assignUserSelection(self.tracktwo_id)
|
self._data.assignUserSelection(self.tracktwo_id)
|
||||||
self._timeline.setDetectionData(self._data.data)
|
|
||||||
self.update()
|
self.update()
|
||||||
|
|
||||||
def on_assignOther(self):
|
def on_assignOther(self):
|
||||||
logging.debug("Assigning user selection to track Other")
|
logging.debug("Assigning user selection to track Other")
|
||||||
self._data.assignUserSelection(self.trackother_id, False)
|
self._data.assignUserSelection(self.trackother_id, False)
|
||||||
self._timeline.setDetectionData(self._data.data)
|
|
||||||
self.update()
|
self.update()
|
||||||
|
|
||||||
def on_setUserFlag(self):
|
def on_setUserFlag(self):
|
||||||
@ -305,8 +300,9 @@ class FixTracks(QWidget):
|
|||||||
self.update()
|
self.update()
|
||||||
|
|
||||||
def on_revertUserFlags(self):
|
def on_revertUserFlags(self):
|
||||||
logging.debug("Tracks:revert ALL UserFlags")
|
logging.debug("Tracks:revert ALL UserFlags and track assignments")
|
||||||
self._data.revertAssignmentStatus()
|
self._data.revertAssignmentStatus()
|
||||||
|
self._data.revertTrackAssignments()
|
||||||
self.update()
|
self.update()
|
||||||
|
|
||||||
def on_deleteDetection(self):
|
def on_deleteDetection(self):
|
||||||
|
Loading…
Reference in New Issue
Block a user