Spaces:
Sleeping
Sleeping
added models deletion
Browse files
app.py
CHANGED
@@ -358,6 +358,14 @@ def main():
|
|
358 |
st.text(f"Hybrid hit rate: {hybrid_hit_rate}")
|
359 |
st.text(f"Hybrid MRR: {vector_mrr}")
|
360 |
st.text(f"Total misses: {total_misses}")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
361 |
|
362 |
st.write("----------")
|
363 |
|
|
|
358 |
st.text(f"Hybrid hit rate: {hybrid_hit_rate}")
|
359 |
st.text(f"Hybrid MRR: {vector_mrr}")
|
360 |
st.text(f"Total misses: {total_misses}")
|
361 |
+
|
362 |
+
delete_models = st.button('Delete all models')
|
363 |
+
if delete_models:
|
364 |
+
for model in os.listdir("models"):
|
365 |
+
model_path = os.path.join("models", model)
|
366 |
+
if os.path.isdir(model_path):
|
367 |
+
shutil.rmtree(model_path)
|
368 |
+
st.write("Models deleted")
|
369 |
|
370 |
st.write("----------")
|
371 |
|