Questions tagged [detectron]

Use "detectron" tag for questions related to FAIR's detectron or detectron2 framework for object detection and segmentation.

217 questions
0
votes
1 answer

detectron2 SSLError when loading model from model_zoo

I'm trying to load a model from detectron2 model_zoo. Here is what I try: from detectron2.config import get_cfg from detectron2.engine import DefaultPredictor cfg =…
user3731622
  • 4,844
  • 8
  • 45
  • 84
0
votes
1 answer

COCO Evaluator results to var

I have COCOEvaluator implemented into my Detectron2 network, however I need to output the evaluation metrics (AP) into variable so I can work with it further. I cant figure out how to do that, or what to call? The only thing that "works" is reading…
Deamoon
  • 3
  • 4
0
votes
0 answers

How to merge two different trained datasets together

I trained a custom dataset but now I want to merge it with different pre-trained dataset in detectron2!
0
votes
2 answers

SSL: CERTIFICATE_VERIFY_FAILED when using pretrained detectron2 model

I am trying to just use the pretrained mask_rcnn_R_50_FPN_3x model in detectron2 on an image. I get the error ssl.SSLCertVerificationError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: unable to get local issuer certificate…
0
votes
1 answer

Extract the masks values from detectron2 object detection Segmentation and then draw the mask with opencv and calculate the area of that mask?

I want to calculate the area of predicted masks from the output of Detectron2 object detection Segmentation So when I run inference it returns the dictionary outputs = predictor(im) pred_mask,pred_boxes,pred_scores. When I print the pred_masks the…
0
votes
0 answers

How can I detect if an object is complete in a image?

I'm using Detectron2 for object detection and I'm looking for a way to understand that if the detected object from Detectron2 is the full object or is the part of it. For example, I'm interested in detecting cars and I want to know if the detected…
0
votes
1 answer

detectron2.data.detection_utils.SizeMismatchError: Mismatched image shape for image

Problem is obvious actually, my images shape's are not the same with the required shapes. All I'm doing is putting my images to detectron's already prepared function(you can see functions below). How can I fix it? These functions are preparing data…
berkaiii
  • 23
  • 3
0
votes
1 answer

Detectron2 what is difference between INPUT.MIN_SIZE and INPUT.MAX_SIZE

In detectron2 training, in the config we can define the INPUT.MIN_SIZE and INPUT.MAX_SIZE to tell detectron what image resolution to scale to in terms of width(height is determined by Detectron2). I understand this scaling is done by Edge shortest…
0
votes
0 answers

IndexError: too many indices for tensor of dimension 3

I am trying to convert Detectron2 Model into an onnx model format (pytorch to onnx). This is the code I am using (note I am using all necessary imports and to my understanding my installations are correct). Here is my code: cfg =…
0
votes
1 answer

Detectron2 code not showing anything in object detection

I am using the code described in this article for running inference (object detection) on an image using a trained model. # import some common detectron2 utilities from detectron2.engine import DefaultPredictor from detectron2.config import…
Preetom Saha Arko
  • 2,588
  • 4
  • 21
  • 37
0
votes
0 answers

RuntimeError: Currently topk on mps works only for k<=16 in Apple silicon GPU (device = MPS)

I am trying to run detectron2 google colab code given on the front page of the repository. I have a system with apple silicon GPU and I am encountering an error. It seems like the "mps" only supports up to 16 proposals from the error message. Any…
bikram
  • 7,127
  • 2
  • 51
  • 63
0
votes
1 answer

Detectron2 difference between SOLVER.IMS_PER_BATCH and MODEL.ROI_HEADS.BATCH_SIZE_PER_IMAGE in cfg file

In detectron2 there seems to be two settings related to batch size in the config file. They are SOLVER.IMS_PER_BATCH and MODEL.ROI_HEADS.BATCH_SIZE_PER_IMAGE I have seen both being used as batch size online and not sure how they differ. What is the…
devman3211
  • 63
  • 1
  • 11
0
votes
1 answer

How to start webcam detection with Detectron2 on Google Colab?

I'm using Detectron2 to implement real time segmentation. After training my model, I tried to perform the inference on my webcam video, using this script: !git clone https://github.com/facebookresearch/detectron2 %run detectron2/demo/demo.py…
0
votes
1 answer

Running Detectron2 locally - windows - [Pytorch Config error]

I am trying to run this code locally: https://gist.github.com/shashank524/74d8f46d5de633b84e2265fcc34774de#file-tabledetection-ipynb After installing required packages, when I am trying to run this line: import layoutparser as lp # PubLayNet model…
CFD
  • 607
  • 1
  • 11
  • 29
0
votes
0 answers

FileNotFoundError: [Errno 2] No such file or directory: using the detectron2 framework on an Ubuntu Docker Container

I'm currently working with facebooks detectron2 framework and have a problem training my model. I have an image path variable train_images_path = "arachne_images/images" which points to a folder containing images, which is used to train the model.…