Spaces:
Sleeping
Sleeping
Update my_model/tabs/run_inference.py
Browse files
my_model/tabs/run_inference.py
CHANGED
|
@@ -35,7 +35,7 @@ class InferenceRunner(StateManager):
|
|
| 35 |
for idx, sample_image_path in enumerate(self.sample_images):
|
| 36 |
with cols[idx]:
|
| 37 |
image = Image.open(sample_image_path)
|
| 38 |
-
st.image(image, width=
|
| 39 |
if st.button(f'Select Sample Image {idx + 1}', key=f'sample_{idx}'):
|
| 40 |
self.process_new_image(sample_image_path, image, kbvqa)
|
| 41 |
|
|
@@ -46,7 +46,7 @@ class InferenceRunner(StateManager):
|
|
| 46 |
|
| 47 |
# Display and interact with each uploaded/selected image
|
| 48 |
for image_key, image_data in self.get_images_data().items():
|
| 49 |
-
self.col2.image(image_data['image'], caption=f'Uploaded Image: {image_key[-11:]}',
|
| 50 |
if not image_data['analysis_done']:
|
| 51 |
self.col2.text("Cool image, please click 'Analyze Image'..")
|
| 52 |
if self.col2.button('Analyze Image', key=f'analyze_{image_key}'):
|
|
|
|
| 35 |
for idx, sample_image_path in enumerate(self.sample_images):
|
| 36 |
with cols[idx]:
|
| 37 |
image = Image.open(sample_image_path)
|
| 38 |
+
st.image(image, width=100, height=100)
|
| 39 |
if st.button(f'Select Sample Image {idx + 1}', key=f'sample_{idx}'):
|
| 40 |
self.process_new_image(sample_image_path, image, kbvqa)
|
| 41 |
|
|
|
|
| 46 |
|
| 47 |
# Display and interact with each uploaded/selected image
|
| 48 |
for image_key, image_data in self.get_images_data().items():
|
| 49 |
+
self.col2.image(image_data['image'], caption=f'Uploaded Image: {image_key[-11:]}', width=1000)
|
| 50 |
if not image_data['analysis_done']:
|
| 51 |
self.col2.text("Cool image, please click 'Analyze Image'..")
|
| 52 |
if self.col2.button('Analyze Image', key=f'analyze_{image_key}'):
|