Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -14,7 +14,7 @@ def yolo_inference(image):
|
|
14 |
output_path = Path(temp_dir.name) / "output_image.jpg"
|
15 |
image.save(temp_path)
|
16 |
|
17 |
-
run(weights=
|
18 |
|
19 |
result_image_path = list((Path(temp_dir.name) / 'result').glob('*.jpg'))[0]
|
20 |
result_image = Image.open(result_image_path)
|
|
|
14 |
output_path = Path(temp_dir.name) / "output_image.jpg"
|
15 |
image.save(temp_path)
|
16 |
|
17 |
+
run(weights=weights_path, source=str(temp_path), project=str(temp_dir.name), name='result', exist_ok=True)
|
18 |
|
19 |
result_image_path = list((Path(temp_dir.name) / 'result').glob('*.jpg'))[0]
|
20 |
result_image = Image.open(result_image_path)
|