Spaces:
Runtime error
Runtime error
Commit ·
db2e7bb
1
Parent(s): b912d76
35 unmodified lines363738393940414243444546474849505152535435 unmodified linesimg = images[index]images[index] = ImageOps.expand(Image.open(io.BytesIO(requests.get(images[index], stream=True).content)),border=20,fill='blue')
col1.image(img, use_column_width=True)caps = list(range(10))
if show: if index == idx: cap = f'{index} (GROUNDTRUTH)' caps[idx] = f'{idx} (GROUNDTRUTH)' images[idx] = ImageOps.expand(Image.open(io.BytesIO(requests.get(images[index], stream=True).content)),border=50,fill='green')if hide: if index == idx: cap = f'{index}' caps[idx] = f'{idx}' images[idx] = Image.open(io.BytesIO(requests.get(images[index], stream=True).content))# shown = True if len(caps[idx]) > 2 else False# if shown col1.image(img, use_column_width=True, caption=cap)col2.image(images, width=175, caption=caps)app.py+7-1