fix_colors
Browse files- handler.py +1 -0
handler.py
CHANGED
|
@@ -124,6 +124,7 @@ class EndpointHandler:
|
|
| 124 |
logger.info("🖼️ Restoration complete, encoding output...")
|
| 125 |
|
| 126 |
# Encode result as base64
|
|
|
|
| 127 |
_, buffer = cv2.imencode(".jpg", restored_img)
|
| 128 |
b64_output = base64.b64encode(buffer).decode("utf-8")
|
| 129 |
|
|
|
|
| 124 |
logger.info("🖼️ Restoration complete, encoding output...")
|
| 125 |
|
| 126 |
# Encode result as base64
|
| 127 |
+
restored_img_rgb = cv2.cvtColor(restored_img, cv2.COLOR_BGR2RGB)
|
| 128 |
_, buffer = cv2.imencode(".jpg", restored_img)
|
| 129 |
b64_output = base64.b64encode(buffer).decode("utf-8")
|
| 130 |
|