Skip to content

Commit

Permalink
add doc for mmdet coco
Browse files Browse the repository at this point in the history
  • Loading branch information
wonjuleee committed Dec 1, 2023
1 parent c4ca126 commit 020bac1
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 0 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## \[Unreleased\]
### New features
- Support MMDetection COCO format
(<https://github.com/openvinotoolkit/datumaro/pull/1213>)

### Enhancements
- Optimize Python import to make CLI entrypoint faster
(<https://github.com/openvinotoolkit/datumaro/pull/1182>)
Expand Down
5 changes: 5 additions & 0 deletions docs/source/docs/data-formats/formats/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ Supported Data Formats
mapillary_vistas
market1501
mars
mmdet
mnist
mot
mots
Expand Down Expand Up @@ -141,6 +142,10 @@ Supported Data Formats
* `Format specification <https://zheng-lab.cecs.anu.edu.au/Project/project_mars.html>`_
* `Dataset example <https://github.com/openvinotoolkit/datumaro/tree/develop/tests/assets/mars_dataset>`_
* `Format documentation <mars.md>`_
* MMDet-COCO (``detection``, ``segmentation``)
* `Format specification <https://mmdetection.readthedocs.io/en/latest/user_guides/dataset_prepare.html>`_
* `Dataset example <https://github.com/openvinotoolkit/datumaro/tree/develop/tests/assets/coco_dataset/mmdet_coco>`_
* `Format documentation <mmdet.md>`_
* MNIST (``classification``)
* `Format specification <http://yann.lecun.com/exdb/mnist/>`_
* `Dataset example <https://github.com/openvinotoolkit/datumaro/tree/develop/tests/assets/mnist_dataset>`_
Expand Down
41 changes: 41 additions & 0 deletions docs/source/docs/data-formats/formats/mmdet.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# MMDetection COCO

## Format specification

[MMDetection](https://mmdetection.readthedocs.io/en/latest/) is a training framework for object detection and instance segmentation tasks, providing a modular and flexible architecture that supports various state-of-the-art models, datasets, and training techniques. MMDetection has gained popularity in the research community for its comprehensive features and ease of use in developing and benchmarking object detection algorithms.
MMDetection specifies their COCO format [here](https://mmdetection.readthedocs.io/en/latest/user_guides/dataset_prepare.html).

Most of available tasks or formats are similar to the [original COCO format](./formats/coco), while only the image directories are separated with respect to subsets.
In this document, we just describe the directory structure of MMDetection COCO format as per [here](https://mmdetection.readthedocs.io/en/latest/user_guides/dataset_prepare.html).
MMDetection COCO dataset directory should have the following structure:

<!--lint disable fenced-code-flag-->
```
└─ Dataset/
├── <subset_name>/
│ ├── <image_name1.ext>
│ ├── <image_name2.ext>
│ └── ...
├── <subset_name>/
│ ├── <image_name1.ext>
│ ├── <image_name2.ext>
│ └── ...
└── annotations/
├── instances_<subset_name>.json
└── ...
```

### Import using CLI

``` bash
datum project create
datum project import --format mmdet_coco <path/to/dataset>
```

### Import using Python API

```python
import datumaro as dm

dataset = dm.Dataset.import_from('<path/to/dataset>', 'mmdet_coco')
```

0 comments on commit 020bac1

Please sign in to comment.