ilass commited on
Commit
1f46401
·
1 Parent(s): ab38131

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +5 -5
app.py CHANGED
@@ -10,11 +10,11 @@ from ultralytics import YOLO
10
  import ultralytics
11
  from ultralytics.yolo.data import utils
12
 
13
- model = YOLO('yolov8n.pt')
 
14
 
15
-
16
- #load class_names
17
- yaml_path = str(Path(ultralytics.__file__).parent/'datasets/coco128.yaml')
18
  class_names = utils.yaml_load(yaml_path)['names']
19
 
20
  def detect(img):
@@ -56,4 +56,4 @@ with gr.Blocks() as demo:
56
 
57
  gr.close_all()
58
  demo.queue()
59
- demo.launch()
 
10
  import ultralytics
11
  from ultralytics.yolo.data import utils
12
 
13
+ # Pfad zu Ihrem Modell aktualisieren
14
+ model = YOLO('2023-05-12-foodAndDrinks.pt')
15
 
16
+ # Pfad zur YAML-Datei aktualisieren
17
+ yaml_path = '2023-05-12-foodAndDrinks.yaml'
 
18
  class_names = utils.yaml_load(yaml_path)['names']
19
 
20
  def detect(img):
 
56
 
57
  gr.close_all()
58
  demo.queue()
59
+ demo.launch()