Spaces:
Build error
Build error
Commit ·
511bb57
1
Parent(s): 24581a2
Update app.py
Browse files
app.py
CHANGED
|
@@ -74,6 +74,8 @@ def image_mod(img_original):
|
|
| 74 |
alpha = 0.4
|
| 75 |
img_resultante = cv.addWeighted(img_mod, 1 - alpha, cv.cvtColor(th, cv.COLOR_GRAY2BGR), alpha, 0)
|
| 76 |
|
|
|
|
|
|
|
| 77 |
image_with_predictions = Image.fromarray(img_resultante[..., ::-1]) # RGB PIL image
|
| 78 |
|
| 79 |
image_with_predictions = image_with_predictions.resize((ancho, alto))
|
|
|
|
| 74 |
alpha = 0.4
|
| 75 |
img_resultante = cv.addWeighted(img_mod, 1 - alpha, cv.cvtColor(th, cv.COLOR_GRAY2BGR), alpha, 0)
|
| 76 |
|
| 77 |
+
img_resultante = cv.cvtColor(imagen_umbralizada, cv.COLOR_BGR2RGB)
|
| 78 |
+
|
| 79 |
image_with_predictions = Image.fromarray(img_resultante[..., ::-1]) # RGB PIL image
|
| 80 |
|
| 81 |
image_with_predictions = image_with_predictions.resize((ancho, alto))
|