Noursine commited on
Commit
44cf9b0
·
verified ·
1 Parent(s): 391d19c

Update src/streamlit_app.py

Browse files
Files changed (1) hide show
  1. src/streamlit_app.py +5 -2
src/streamlit_app.py CHANGED
@@ -6,7 +6,7 @@ from ultralytics import YOLO
6
 
7
  @st.cache_resource(show_spinner=False)
8
  def load_model():
9
- return YOLO('best.pt') # Make sure the model file is in the same folder or provide full path
10
 
11
  def predict(image, model):
12
  img_np = np.array(image)
@@ -83,4 +83,7 @@ def main():
83
  st.write(f"Tooth {i+1}: {label}")
84
 
85
  else:
86
- st.info("No teeth detected in this image.")
 
 
 
 
6
 
7
  @st.cache_resource(show_spinner=False)
8
  def load_model():
9
+ return YOLO('best.pt')
10
 
11
  def predict(image, model):
12
  img_np = np.array(image)
 
83
  st.write(f"Tooth {i+1}: {label}")
84
 
85
  else:
86
+ st.info("No teeth detected in this image.")
87
+
88
+ if __name__ == "__main__":
89
+ main()