GF-John commited on
Commit
d78aa39
·
verified ·
1 Parent(s): acdc36a

trying to fix flash-attn issue when using cuda

Browse files
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -6,7 +6,6 @@
6
  import gradio as gr
7
  import cv2
8
  import tempfile
9
- from ultralytics import YOLO
10
  import spaces, subprocess
11
 
12
  # Install flash attention, skipping CUDA build if necessary
@@ -16,6 +15,8 @@ subprocess.run(
16
  shell=True,
17
  )
18
 
 
 
19
  @spaces.GPU
20
  def yolov12_inference(image, video, model_id, image_size, conf_threshold):
21
  model = YOLO(model_id)
 
6
  import gradio as gr
7
  import cv2
8
  import tempfile
 
9
  import spaces, subprocess
10
 
11
  # Install flash attention, skipping CUDA build if necessary
 
15
  shell=True,
16
  )
17
 
18
+ from ultralytics import YOLO
19
+
20
  @spaces.GPU
21
  def yolov12_inference(image, video, model_id, image_size, conf_threshold):
22
  model = YOLO(model_id)