syedfaisalabrar commited on
Commit
af02505
·
verified ·
1 Parent(s): 3c725b4

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -12,7 +12,7 @@ from backPrompt import main as main_b
12
  from frontPrompt import main as main_f
13
 
14
  model_path = "best.pt"
15
- model = YOLO(model_path)
16
 
17
  path = "OpenGVLab/InternVL2_5-4B"
18
  model = AutoModel.from_pretrained(
@@ -51,7 +51,7 @@ def imageRotation(image):
51
  def detect_document(image):
52
  """Detects front and back of the document using YOLO."""
53
  image = np.array(image)
54
- results = model(image, conf=0.85)
55
 
56
  detected_classes = set()
57
  labels = []
 
12
  from frontPrompt import main as main_f
13
 
14
  model_path = "best.pt"
15
+ modelY = YOLO(model_path)
16
 
17
  path = "OpenGVLab/InternVL2_5-4B"
18
  model = AutoModel.from_pretrained(
 
51
  def detect_document(image):
52
  """Detects front and back of the document using YOLO."""
53
  image = np.array(image)
54
+ results = modelY(image, conf=0.85)
55
 
56
  detected_classes = set()
57
  labels = []