fcakyon commited on
Commit
fe27809
1 Parent(s): a7ccadc

update to latest sahi api

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -1,7 +1,7 @@
1
  import streamlit as st
2
  import sahi.utils.file
3
  import sahi.utils.mmdet
4
- import sahi.model
5
  from PIL import Image
6
  import random
7
  from utils import sahi_mmdet_inference
@@ -42,7 +42,8 @@ def get_model():
42
  model_name="yolox", config_file_name="yolox_tiny_8x8_300e_coco.py"
43
  )
44
 
45
- detection_model = sahi.model.MmdetDetectionModel(
 
46
  model_path=model_path,
47
  config_path=config_path,
48
  confidence_threshold=0.5,
1
  import streamlit as st
2
  import sahi.utils.file
3
  import sahi.utils.mmdet
4
+ from sahi import AutoDetectionModel
5
  from PIL import Image
6
  import random
7
  from utils import sahi_mmdet_inference
42
  model_name="yolox", config_file_name="yolox_tiny_8x8_300e_coco.py"
43
  )
44
 
45
+ detection_model = AutoDetectionModel(
46
+ model_type='mmdet'
47
  model_path=model_path,
48
  config_path=config_path,
49
  confidence_threshold=0.5,