mirror of
https://github.com/Bing-su/adetailer.git
synced 2026-05-01 03:31:21 +00:00
fix: suppress mediapipe error
This commit is contained in:
@@ -21,7 +21,10 @@ def mediapipe_predict(
|
|||||||
}
|
}
|
||||||
if model_type in mapping:
|
if model_type in mapping:
|
||||||
func = mapping[model_type]
|
func = mapping[model_type]
|
||||||
return func(image, confidence)
|
try:
|
||||||
|
return func(image, confidence)
|
||||||
|
except Exception:
|
||||||
|
return PredictOutput()
|
||||||
msg = f"[-] ADetailer: Invalid mediapipe model type: {model_type}, Available: {list(mapping.keys())!r}"
|
msg = f"[-] ADetailer: Invalid mediapipe model type: {model_type}, Available: {list(mapping.keys())!r}"
|
||||||
raise RuntimeError(msg)
|
raise RuntimeError(msg)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user