m7mdal7aj commited on
Commit
b9e08de
1 Parent(s): af795cc

Update my_model/tabs/run_inference.py

Browse files
Files changed (1) hide show
  1. my_model/tabs/run_inference.py +1 -1
my_model/tabs/run_inference.py CHANGED
@@ -102,7 +102,7 @@ def run_inference():
102
 
103
  method = st.selectbox("Choose a method:", ["Fine-Tuned Model", "In-Context Learning (n-shots)"], index=0, key='method')
104
  detection_model = st.selectbox("Choose a model for objects detection:", ["yolov5", "detic"], index=1, key='detection_model')
105
- default_confidence = 0.2 if st.session_state['detection_model'] == "yolov5" else 0.4
106
  # confidence_level = st.slider("Select minimum detection confidence level", min_value=0.1, max_value=0.9, value=default_confidence, step=0.1)
107
  confidence_level = state_manager.set_slider_value(text="Select minimum detection confidence level",
108
  min_value=0.1,
 
102
 
103
  method = st.selectbox("Choose a method:", ["Fine-Tuned Model", "In-Context Learning (n-shots)"], index=0, key='method')
104
  detection_model = st.selectbox("Choose a model for objects detection:", ["yolov5", "detic"], index=1, key='detection_model')
105
+ default_confidence = 0.2 if detection_model == "yolov5" else 0.4
106
  # confidence_level = st.slider("Select minimum detection confidence level", min_value=0.1, max_value=0.9, value=default_confidence, step=0.1)
107
  confidence_level = state_manager.set_slider_value(text="Select minimum detection confidence level",
108
  min_value=0.1,