Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -12,6 +12,9 @@ os.rename("best.ckpt", "models/best.ckpt")
|
|
12 |
os.mkdir("dataout")
|
13 |
model = hub.Module(name='U2Net')
|
14 |
def infer(img,option):
|
|
|
|
|
|
|
15 |
img = Image.fromarray(img["image"])
|
16 |
mask = Image.fromarray(img["mask"])
|
17 |
img = ImageOps.contain(img, (700,700))
|
|
|
12 |
os.mkdir("dataout")
|
13 |
model = hub.Module(name='U2Net')
|
14 |
def infer(img,option):
|
15 |
+
print(type(img))
|
16 |
+
print(type(img["image"]))
|
17 |
+
print(type(img["mask"]))
|
18 |
img = Image.fromarray(img["image"])
|
19 |
mask = Image.fromarray(img["mask"])
|
20 |
img = ImageOps.contain(img, (700,700))
|