From 6018184ce4203bcbc750ba49daefa370d358b759 Mon Sep 17 00:00:00 2001 From: Dowon Date: Thu, 29 Feb 2024 20:34:35 +0900 Subject: [PATCH] fix: sync with ultralytics implement https://github.com/ultralytics/ultralytics/blob/f8e681c2be251562633d424f4a1a1cc7da526bed/ultralytics/models/yolo/model.py#L17 --- adetailer/ultralytics.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/adetailer/ultralytics.py b/adetailer/ultralytics.py index 091872e..8483b12 100644 --- a/adetailer/ultralytics.py +++ b/adetailer/ultralytics.py @@ -40,7 +40,7 @@ def ultralytics_predict( def apply_classes(model, model_path: str | Path, classes: str): - if not classes or not Path(model_path).stem.endswith("world"): + if not classes or "-world" not in Path(model_path).stem: return parsed = [c.strip() for c in classes.split(",")] model.set_classes(parsed)