mosidi commited on
Commit
5415aac
·
1 Parent(s): 715faf9

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -51,7 +51,7 @@ API_Secret =os.environ["API_Secret"]
51
 
52
 
53
 
54
-
55
 
56
  # try:
57
  # register_coco_instances("Fiber", {}, "./labels-fiver.json", "./Fiber")
@@ -72,7 +72,7 @@ cfg.MODEL.ROI_HEADS.NUM_CLASSES = 2
72
  my_metadata = MetadataCatalog.get("dbmdz_coco_all")
73
  # Fiber_metadata.thing_classes = ["Fiber", "Fiber","Fiber"]
74
  my_metadata.thing_classes = ["Fiber", "Fiber"]
75
- cfg = get_cfg()
76
  cfg.merge_from_file("./configs/detectron2/mask_rcnn_R_50_FPN_3x.yaml")
77
  cfg.MODEL.WEIGHTS = model_path #os.path.join(cfg.OUTPUT_DIR, "model_final.pth")
78
  cfg.MODEL.ROI_HEADS.SCORE_THRESH_TEST = 0.05 # set the testing threshold for this model
 
51
 
52
 
53
 
54
+ cfg = get_cfg()
55
 
56
  # try:
57
  # register_coco_instances("Fiber", {}, "./labels-fiver.json", "./Fiber")
 
72
  my_metadata = MetadataCatalog.get("dbmdz_coco_all")
73
  # Fiber_metadata.thing_classes = ["Fiber", "Fiber","Fiber"]
74
  my_metadata.thing_classes = ["Fiber", "Fiber"]
75
+
76
  cfg.merge_from_file("./configs/detectron2/mask_rcnn_R_50_FPN_3x.yaml")
77
  cfg.MODEL.WEIGHTS = model_path #os.path.join(cfg.OUTPUT_DIR, "model_final.pth")
78
  cfg.MODEL.ROI_HEADS.SCORE_THRESH_TEST = 0.05 # set the testing threshold for this model