dragonSwing commited on
Commit
f695925
1 Parent(s): 2adf03d

Fix imports

Browse files
Files changed (2) hide show
  1. app.py +2 -2
  2. utils.py +4 -4
app.py CHANGED
@@ -23,9 +23,9 @@ sys.path.append("tag2text")
23
  sys.path.append("GroundingDINO")
24
 
25
  from tag2text.models import tag2text
26
- from GroundingDINO.groundingdino.util.inference import Model as DinoModel
27
  from config import *
28
- from utils import download_file_hf, detect, segment, show_anns, generate_tags
29
 
30
  if not os.path.exists(abs_weight_dir):
31
  os.makedirs(abs_weight_dir, exist_ok=True)
 
23
  sys.path.append("GroundingDINO")
24
 
25
  from tag2text.models import tag2text
26
+ from groundingdino.util.inference import Model as DinoModel
27
  from config import *
28
+ from utils import download_file_hf, detect, segment, show_anns_sam, generate_tags
29
 
30
  if not os.path.exists(abs_weight_dir):
31
  os.makedirs(abs_weight_dir, exist_ok=True)
utils.py CHANGED
@@ -17,10 +17,10 @@ from segment_anything import SamPredictor
17
  sys.path.append("tag2text")
18
  sys.path.append("GroundingDINO")
19
 
20
- from GroundingDINO.groundingdino.models import build_model
21
- from GroundingDINO.groundingdino.util.inference import Model as DinoModel
22
- from GroundingDINO.groundingdino.util.slconfig import SLConfig
23
- from GroundingDINO.groundingdino.util.utils import clean_state_dict
24
  from tag2text.inference import inference as tag2text_inference
25
 
26
 
 
17
  sys.path.append("tag2text")
18
  sys.path.append("GroundingDINO")
19
 
20
+ from groundingdino.models import build_model
21
+ from groundingdino.util.inference import Model as DinoModel
22
+ from groundingdino.util.slconfig import SLConfig
23
+ from groundingdino.util.utils import clean_state_dict
24
  from tag2text.inference import inference as tag2text_inference
25
 
26