Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -99,7 +99,7 @@ def predict(jpg, msk):
|
|
99 |
|
100 |
image, mask = prepare_img_and_mask(imagex.resize((512, 512)), mask.resize((512, 512)), 'cpu')
|
101 |
# Run the model
|
102 |
-
outputs = model.run(None, {'
|
103 |
|
104 |
output = outputs[0][0]
|
105 |
# Postprocess the outputs
|
|
|
99 |
|
100 |
image, mask = prepare_img_and_mask(imagex.resize((512, 512)), mask.resize((512, 512)), 'cpu')
|
101 |
# Run the model
|
102 |
+
outputs = model.run(None, {'image': image.numpy().astype(np.float32), 'mask': mask.numpy().astype(np.float32)})
|
103 |
|
104 |
output = outputs[0][0]
|
105 |
# Postprocess the outputs
|