Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -25,12 +25,12 @@ from detectron2.utils.visualizer import Visualizer
|
|
25 |
from detectron2.data import MetadataCatalog
|
26 |
from detectron2.data.datasets import register_coco_instances
|
27 |
try:
|
28 |
-
register_coco_instances("Fiber", {}, "./labels-fiver.json", "
|
29 |
Fiber_metadata = MetadataCatalog.get("Fiber")
|
30 |
dataset_dicts = DatasetCatalog.get("Fiber")
|
31 |
except:
|
32 |
print("there is an issue")
|
33 |
-
model_path = "
|
34 |
|
35 |
cfg = get_cfg()
|
36 |
cfg.merge_from_file("./configs/detectron2/faster_rcnn_R_50_FPN_3x.yaml")
|
|
|
25 |
from detectron2.data import MetadataCatalog
|
26 |
from detectron2.data.datasets import register_coco_instances
|
27 |
try:
|
28 |
+
register_coco_instances("Fiber", {}, "./labels-fiver.json", "./Fiber")
|
29 |
Fiber_metadata = MetadataCatalog.get("Fiber")
|
30 |
dataset_dicts = DatasetCatalog.get("Fiber")
|
31 |
except:
|
32 |
print("there is an issue")
|
33 |
+
model_path = "./model_final.pth"
|
34 |
|
35 |
cfg = get_cfg()
|
36 |
cfg.merge_from_file("./configs/detectron2/faster_rcnn_R_50_FPN_3x.yaml")
|