Update my_model/tabs/run_inference.py
Browse files
my_model/tabs/run_inference.py
CHANGED
@@ -103,7 +103,7 @@ class InferenceRunner(StateManager):
|
|
103 |
nested_col22.text("Please click 'Analyze Image'..")
|
104 |
analyze_button_key = f'analyze_{image_key}_{st.session_state.detection_model}_{st.session_state.confidence_level}'
|
105 |
if nested_col22.button('Analyze Image', key=analyze_button_key, on_click=self.disable_widgets, disabled=self.is_widget_disabled):
|
106 |
-
with
|
107 |
caption, detected_objects_str, image_with_boxes = self.analyze_image(image_data['image'])
|
108 |
self.update_image_data(image_key, caption, detected_objects_str, True)
|
109 |
st.session_state['loading_in_progress'] = False
|
|
|
103 |
nested_col22.text("Please click 'Analyze Image'..")
|
104 |
analyze_button_key = f'analyze_{image_key}_{st.session_state.detection_model}_{st.session_state.confidence_level}'
|
105 |
if nested_col22.button('Analyze Image', key=analyze_button_key, on_click=self.disable_widgets, disabled=self.is_widget_disabled):
|
106 |
+
with st.spinner('Analyzing the image...'):
|
107 |
caption, detected_objects_str, image_with_boxes = self.analyze_image(image_data['image'])
|
108 |
self.update_image_data(image_key, caption, detected_objects_str, True)
|
109 |
st.session_state['loading_in_progress'] = False
|