Update app.py
Browse files
app.py
CHANGED
@@ -130,9 +130,12 @@ def run_inference():
|
|
130 |
|
131 |
if 'kbvqa' not in st.session_state or st.session_state['detection_model'] != detection_model:
|
132 |
st.session_state['detection_model'] = detection_model
|
133 |
-
if
|
134 |
-
|
135 |
-
|
|
|
|
|
|
|
136 |
|
137 |
|
138 |
|
|
|
130 |
|
131 |
if 'kbvqa' not in st.session_state or st.session_state['detection_model'] != detection_model:
|
132 |
st.session_state['detection_model'] = detection_model
|
133 |
+
if 'model' not in st.session_state:
|
134 |
+
if st.button('Load Model'):
|
135 |
+
|
136 |
+
if load_kbvqa_model(detection_model):
|
137 |
+
set_model_confidence(detection_model)
|
138 |
+
image_qa_app(st.session_state['kbvqa'])
|
139 |
|
140 |
|
141 |
|