diff --git a/label_studio_ml/examples/yolo/control_models/timeline_labels.py b/label_studio_ml/examples/yolo/control_models/timeline_labels.py index ee1e3341..646c0079 100644 --- a/label_studio_ml/examples/yolo/control_models/timeline_labels.py +++ b/label_studio_ml/examples/yolo/control_models/timeline_labels.py @@ -40,7 +40,7 @@ def create(cls, *args, **kwargs): instance = super().create(*args, **kwargs) # timeline models can be trainable and based on YOLO trained classes directly - instance.trainable = instance.control.attr.get("model_trainable", instance.trainable) + instance.trainable = get_bool(self.control.attr, "model_trainable", "false") # if it's trainable, we need to use labels from the labeling config as is because we will train them if instance.trainable: instance.label_map = {label: label for label in instance.control.labels}