gg
Browse files- pipeline.py +11 -1
pipeline.py
CHANGED
|
@@ -177,8 +177,18 @@ def process(
|
|
| 177 |
_build_stage_a_checkerboard_from_mask = M._build_stage_a_checkerboard_from_mask
|
| 178 |
|
| 179 |
def _progress(msg: str):
|
|
|
|
| 180 |
if progress_callback:
|
| 181 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 182 |
|
| 183 |
try:
|
| 184 |
# 0) Basic video info
|
|
|
|
| 177 |
_build_stage_a_checkerboard_from_mask = M._build_stage_a_checkerboard_from_mask
|
| 178 |
|
| 179 |
def _progress(msg: str):
|
| 180 |
+
logger.info(f"Progress: {msg}")
|
| 181 |
if progress_callback:
|
| 182 |
+
try:
|
| 183 |
+
# Try calling with just the message
|
| 184 |
+
progress_callback(msg)
|
| 185 |
+
except TypeError:
|
| 186 |
+
try:
|
| 187 |
+
# Try calling with progress, message signature
|
| 188 |
+
progress_callback(0.0, msg)
|
| 189 |
+
except (TypeError, AttributeError):
|
| 190 |
+
# Callback has incompatible signature, just log
|
| 191 |
+
pass
|
| 192 |
|
| 193 |
try:
|
| 194 |
# 0) Basic video info
|