Spaces:
Running
Running
Update my_model/tabs/run_inference.py
Browse files
my_model/tabs/run_inference.py
CHANGED
@@ -244,9 +244,6 @@ class InferenceRunner(StateManager):
|
|
244 |
reload_detection_model = False
|
245 |
force_reload_full_model = False
|
246 |
|
247 |
-
#if self.is_model_loaded and self.settings_changed:
|
248 |
-
if self.settings_changed:
|
249 |
-
self.col1.warning("Model settings have changed, please reload the model.. ")
|
250 |
# self.update_prev_state()
|
251 |
st.session_state.button_label = (
|
252 |
"Reload Model" if (self.is_model_loaded and
|
@@ -255,6 +252,9 @@ class InferenceRunner(StateManager):
|
|
255 |
st.session_state['method'] != st.session_state['previous_state']['method'])
|
256 |
else "Load Model"
|
257 |
)
|
|
|
|
|
|
|
258 |
|
259 |
with self.col1:
|
260 |
if st.session_state.method == "7b-Fine-Tuned Model" or st.session_state.method == "13b-Fine-Tuned Model":
|
|
|
244 |
reload_detection_model = False
|
245 |
force_reload_full_model = False
|
246 |
|
|
|
|
|
|
|
247 |
# self.update_prev_state()
|
248 |
st.session_state.button_label = (
|
249 |
"Reload Model" if (self.is_model_loaded and
|
|
|
252 |
st.session_state['method'] != st.session_state['previous_state']['method'])
|
253 |
else "Load Model"
|
254 |
)
|
255 |
+
#if self.is_model_loaded and self.settings_changed:
|
256 |
+
if st.session_state.button_label == "Reload Model":
|
257 |
+
self.col1.warning("Model settings have changed, please reload the model.. ")
|
258 |
|
259 |
with self.col1:
|
260 |
if st.session_state.method == "7b-Fine-Tuned Model" or st.session_state.method == "13b-Fine-Tuned Model":
|