question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

The way `--output_coco_json` works right now is it operates on a dataset (which doesn't need to have ground truth). So you need to give a `--dataset` parameter instead of an `--image` parameter. The dataset you use doesn't need annotations, simply create a COCO dataset with just images and an empty annotation array and follow the dataset definition of `coco2017_testdev_dataset`.

See original GitHub issue

Hi, thanks for your code. it works well with my dataset. But I have a problem of outputting the json file of eval.py. I have create a json file with empty annotation based on the test image (more than one), so I used this json file on the coco2017_testdev_dataset, but it did not give a path for imaging, just path for json file. I think I did not really understand how I can use --dataset, can u explain more?? thanks a lot.

The way --output_coco_json works right now is it operates on a dataset (which doesn’t need to have ground truth). So you need to give a --dataset parameter instead of an --image parameter. The dataset you use doesn’t need annotations, simply create a COCO dataset with just images and an empty annotation array and follow the dataset definition of coco2017_testdev_dataset.

For single images, this is kind of cumbersome, but for large batches it probably works fine? This feature was intended for submission to the COCO eval servers so that’s why it’s so roundabout. Let me know if this is indeed too cumbersome, and I can add --output_coco_json support to --image.

_Originally posted by @dbolya in https://github.com/dbolya/yolact/issues/230#issuecomment-560542964_

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:23

github_iconTop GitHub Comments

1reaction
qiumei1101commented, Aug 20, 2021

Hi @PL-96, @linyingyingkarina I could use the dataset parameter as suggested and it gave me two files: mask_detections.json bbox_detections.json How can i get single file per image from these two files? Do i use coco2labelme.py for this?

What does it mean by empty annotation array? Could you please explain. Did you find the answer?

Did not receive any answer

thanks for replying, I create an empty json file; image but I get the error: image if you know how to solve this issue, please share;

I’m facing the same error, Could somebody help.

I modified the code and get the json file now.

1reaction
PL-96commented, Apr 24, 2021

Hi @PL-96 No, here is what i want to do: Manual annotation - drawing polygons is a painful task. I have trained the YOLACT model on few images and it is predicting good polygons on the remaining. However the categories are false, so i need to open the annotations in labelme and correct the labels. Once the labels are corrected, i will retrain the model on the additional images (now i will have many images to train). For this purpose, i need the ‘eval.py’ to output single json file for each image (i know we can add --dataset parameter to get a single json - but that is one file for the entire dataset, i need per image) Thanks

hi, can I know how u generate my_custom_dataset to meet the demand of the dataset parameter?

the same as coco2017_testdev_dataset, and set ‘has_gt’ to False.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to work with object detection datasets in COCO format
If you only have unlabeled images, then you will first need to generate object labels. You can generate either ground truth labels with...
Read more >
BME695DL Homework 4 Solved - Ankitcodinghub
The goal of the present homework is to provide you with a first introduction to the Microsoft COCO dataset that is just as...
Read more >
Convert any dataset to COCO object detection format with SAHI
Convert any dataset to COCO object detection format with SAHI. After reading this post, you will be able to easily convert any dataset...
Read more >
Create your own COCO-style datasets - waspinator –
The format COCO uses to store annotations has since become a de facto standard, and if you can convert your dataset to its...
Read more >
How do I take COCO formatted json and compare them to ...
I am looking for some help with COCO jsons. I have a set of images that I have labelled with 10 sided polygons...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found