MCPcopy Create free account
hub / github.com/DeepLabCut/DeepLabCut / _update_detectors

Method _update_detectors

deeplabcut/gui/tabs/modelzoo.py:575–587  ·  view source on GitHub ↗
(self, super_animal: str)

Source from the content-addressed store, hash-verified

573 )
574
575 def _update_detectors(self, super_animal: str) -> None:
576 if len(super_animal) == 0:
577 set_combo_items(combo_box=self.detector_type_selector, items=[])
578 return
579
580 items = []
581 if self.root.engine == Engine.PYTORCH:
582 if super_animal == "superanimal_humanbody":
583 items = list(TORCHVISION_DETECTORS.keys())
584 else:
585 items = dlclibrary.get_available_detectors(super_animal)
586 set_combo_items(combo_box=self.detector_type_selector, items=items)
587 set_layout_contents_visible(self.detector_row, self.root.engine == Engine.PYTORCH)
588
589 def _update_adaptation_detector_visibility(self, superanimal: str):
590 self.adapt_det_epoch_label.setVisible(superanimal != "superanimal_humanbody")

Callers 1

__init__Method · 0.95

Calls 3

set_combo_itemsFunction · 0.90
keysMethod · 0.80

Tested by

no test coverage detected