Datasets:
Add dataset card
Browse files
README.md
CHANGED
|
@@ -1,59 +1,212 @@
|
|
| 1 |
---
|
| 2 |
-
|
| 3 |
-
|
| 4 |
-
-
|
| 5 |
-
|
| 6 |
-
-
|
| 7 |
-
|
| 8 |
-
-
|
| 9 |
-
|
| 10 |
-
|
| 11 |
-
|
| 12 |
-
|
| 13 |
-
|
| 14 |
-
-
|
| 15 |
-
list:
|
| 16 |
-
- name: area
|
| 17 |
-
dtype: float64
|
| 18 |
-
- name: bbox
|
| 19 |
-
list: float64
|
| 20 |
-
- name: category_id
|
| 21 |
-
dtype: int64
|
| 22 |
-
- name: id
|
| 23 |
-
dtype: int64
|
| 24 |
-
- name: iscrowd
|
| 25 |
-
dtype: int64
|
| 26 |
-
- name: segmentation
|
| 27 |
-
list: 'null'
|
| 28 |
-
- name: relations
|
| 29 |
-
list:
|
| 30 |
-
- name: id
|
| 31 |
-
dtype: int64
|
| 32 |
-
- name: object_id
|
| 33 |
-
dtype: int64
|
| 34 |
-
- name: predicate_id
|
| 35 |
-
dtype: int64
|
| 36 |
-
- name: subject_id
|
| 37 |
-
dtype: int64
|
| 38 |
-
splits:
|
| 39 |
-
- name: train
|
| 40 |
-
num_bytes: 810556127
|
| 41 |
-
num_examples: 9538
|
| 42 |
-
- name: val
|
| 43 |
-
num_bytes: 85408782
|
| 44 |
-
num_examples: 733
|
| 45 |
-
- name: test
|
| 46 |
-
num_bytes: 514138017
|
| 47 |
-
num_examples: 4403
|
| 48 |
-
download_size: 1866283688
|
| 49 |
-
dataset_size: 1410102926
|
| 50 |
-
configs:
|
| 51 |
-
- config_name: default
|
| 52 |
-
data_files:
|
| 53 |
-
- split: train
|
| 54 |
-
path: data/train-*
|
| 55 |
-
- split: val
|
| 56 |
-
path: data/val-*
|
| 57 |
-
- split: test
|
| 58 |
-
path: data/test-*
|
| 59 |
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|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
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
---
|
| 2 |
+
license: cc-by-4.0
|
| 3 |
+
task_categories:
|
| 4 |
+
- object-detection
|
| 5 |
+
tags:
|
| 6 |
+
- scene-graph-generation
|
| 7 |
+
- visual-relationship-detection
|
| 8 |
+
- visual-genome
|
| 9 |
+
- coco-format
|
| 10 |
+
language:
|
| 11 |
+
- en
|
| 12 |
+
pretty_name: IndoorVG — Indoor Visual Genome (COCO format)
|
| 13 |
+
size_categories:
|
| 14 |
+
- 10K<n<100K
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 15 |
---
|
| 16 |
+
|
| 17 |
+
# IndoorVG — Indoor Visual Genome (COCO format)
|
| 18 |
+
|
| 19 |
+
**IndoorVG** is a curated split of
|
| 20 |
+
[Visual Genome](https://homes.cs.washington.edu/~ranjay/visualgenome/index.html)
|
| 21 |
+
targeting real-world **indoor** scenarios (kitchens, offices, living rooms, …).
|
| 22 |
+
It was proposed in
|
| 23 |
+
[Neau et al. (2024)](https://link.springer.com/chapter/10.1007/978-3-031-55015-7_25)
|
| 24 |
+
and reformatted here in standard COCO-JSON format.
|
| 25 |
+
|
| 26 |
+
It was produced as part of the
|
| 27 |
+
[SGG-Benchmark](https://github.com/Maelic/SGG-Benchmark) framework and used to train
|
| 28 |
+
the models described in the **REACT** paper
|
| 29 |
+
([Neau et al., BMVC 2025](https://bmva-archive.org.uk/bmvc/2025/assets/papers/Paper_239/paper.pdf)).
|
| 30 |
+
|
| 31 |
+
The 84 object classes and 37 predicate classes were **manually selected and
|
| 32 |
+
semi-automatically merged** to reduce label noise and ambiguity compared to VG150,
|
| 33 |
+
focusing on indoor-relevant concepts.
|
| 34 |
+
|
| 35 |
+
---
|
| 36 |
+
|
| 37 |
+
## Annotation overview
|
| 38 |
+
|
| 39 |
+
Each image comes with:
|
| 40 |
+
- **Object bounding boxes** — 84 indoor-focused object categories.
|
| 41 |
+
- **Scene-graph relations** — 37 predicate categories connecting pairs of objects as
|
| 42 |
+
directed `(subject, predicate, object)` triplets.
|
| 43 |
+
|
| 44 |
+

|
| 45 |
+
|
| 46 |
+
*Four random validation images with bounding boxes (coloured by category) and
|
| 47 |
+
relation arrows (yellow, labelled with the predicate name).*
|
| 48 |
+
|
| 49 |
+
---
|
| 50 |
+
|
| 51 |
+
## Dataset statistics
|
| 52 |
+
|
| 53 |
+
| Split | Images | Object annotations | Relations |
|
| 54 |
+
|-------|-------:|-------------------:|----------:|
|
| 55 |
+
| train | 9 538 | 125 411 | 72 291 |
|
| 56 |
+
| val | 733 | 10 246 | 4 866 |
|
| 57 |
+
| test | 4 403 | 61 278 | 29 367 |
|
| 58 |
+
|
| 59 |
+
---
|
| 60 |
+
|
| 61 |
+
## Object categories (84)
|
| 62 |
+
|
| 63 |
+
Manually curated indoor vocabulary: *bag, basket, bin, blind, book, bottle, bowl,
|
| 64 |
+
cabinet, ceiling, chair, …* Full list embedded in `dataset_info.description`.
|
| 65 |
+
|
| 66 |
+
## Predicate categories (37)
|
| 67 |
+
|
| 68 |
+
> above · against · at · attached to · behind · between · carrying · covering ·
|
| 69 |
+
> cutting · drinking · eating · filled with · for · hanging from · has · holding ·
|
| 70 |
+
> in · in front of · laying on · looking at · lying on · mounted on · near · of ·
|
| 71 |
+
> on · playing with · reading · sitting at · sitting on · standing on · taking ·
|
| 72 |
+
> talking on · under · using · watching · wearing · with
|
| 73 |
+
|
| 74 |
+
---
|
| 75 |
+
|
| 76 |
+
## Dataset structure
|
| 77 |
+
|
| 78 |
+
```python
|
| 79 |
+
DatasetDict({
|
| 80 |
+
train: Dataset({
|
| 81 |
+
features: ['image', 'image_id', 'width', 'height', 'file_name',
|
| 82 |
+
'objects', 'relations'],
|
| 83 |
+
num_rows: 9538
|
| 84 |
+
}),
|
| 85 |
+
val: Dataset({
|
| 86 |
+
features: ['image', 'image_id', 'width', 'height', 'file_name',
|
| 87 |
+
'objects', 'relations'],
|
| 88 |
+
num_rows: 733
|
| 89 |
+
}),
|
| 90 |
+
test: Dataset({
|
| 91 |
+
features: ['image', 'image_id', 'width', 'height', 'file_name',
|
| 92 |
+
'objects', 'relations'],
|
| 93 |
+
num_rows: 4403
|
| 94 |
+
}),
|
| 95 |
+
})
|
| 96 |
+
```
|
| 97 |
+
|
| 98 |
+
Each row contains:
|
| 99 |
+
|
| 100 |
+
| Field | Type | Description |
|
| 101 |
+
|-------|------|-------------|
|
| 102 |
+
| `image` | `Image` | PIL image |
|
| 103 |
+
| `image_id` | `int` | Original Visual Genome image id |
|
| 104 |
+
| `width` / `height` | `int` | Image dimensions |
|
| 105 |
+
| `file_name` | `str` | Original filename |
|
| 106 |
+
| `objects` | `List[dict]` | `{id, category_id, bbox (xywh), area, iscrowd, segmentation}` |
|
| 107 |
+
| `relations` | `List[dict]` | `{id, subject_id, object_id, predicate_id}` — ids refer to `objects[*].id` |
|
| 108 |
+
|
| 109 |
+
---
|
| 110 |
+
|
| 111 |
+
## Usage
|
| 112 |
+
|
| 113 |
+
```python
|
| 114 |
+
from datasets import load_dataset
|
| 115 |
+
import json
|
| 116 |
+
|
| 117 |
+
ds = load_dataset("maelic/IndoorVG-coco-format")
|
| 118 |
+
|
| 119 |
+
# Recover label maps from the embedded metadata
|
| 120 |
+
meta = json.loads(ds["train"].info.description)
|
| 121 |
+
cat_id2name = {c["id"]: c["name"] for c in meta["categories"]}
|
| 122 |
+
pred_id2name = {c["id"]: c["name"] for c in meta["rel_categories"]}
|
| 123 |
+
|
| 124 |
+
sample = ds["train"][0]
|
| 125 |
+
image = sample["image"] # PIL Image
|
| 126 |
+
for obj in sample["objects"]:
|
| 127 |
+
print(cat_id2name[obj["category_id"]], obj["bbox"])
|
| 128 |
+
for rel in sample["relations"]:
|
| 129 |
+
print(rel["subject_id"], "--", pred_id2name[rel["predicate_id"]], "->", rel["object_id"])
|
| 130 |
+
```
|
| 131 |
+
|
| 132 |
+
This dataset can be used with the pycocotools API for scene graph generation:
|
| 133 |
+
```bash
|
| 134 |
+
pip install git+https://github.com/Maelic/pycocotools
|
| 135 |
+
```
|
| 136 |
+
|
| 137 |
+
```python
|
| 138 |
+
from pycocootools.coco import COCO
|
| 139 |
+
|
| 140 |
+
from datasets import load_dataset
|
| 141 |
+
ds = load_dataset("maelic/IndoorVG-coco-format")
|
| 142 |
+
# Convert Hugging Face dataset to COCO format
|
| 143 |
+
coco_ds = {
|
| 144 |
+
"images": ds["train"]["image_id"],
|
| 145 |
+
"annotations": ds["train"]["objects"],
|
| 146 |
+
"rel_annotations": ds["train"]["relations"],
|
| 147 |
+
"categories": json.loads(ds["train"].info.description)["categories"],
|
| 148 |
+
"rel_categories": json.loads(ds["train"].info.description)["rel_categories"],
|
| 149 |
+
}
|
| 150 |
+
coco = COCO()
|
| 151 |
+
coco.dataset = coco_ds
|
| 152 |
+
coco.createIndex()
|
| 153 |
+
|
| 154 |
+
for img_id in coco.getImgIds():
|
| 155 |
+
rel_ids = coco.getRelIds(imgIds=img_id)
|
| 156 |
+
relations.extend(coco.loadRels(rel_ids))
|
| 157 |
+
```
|
| 158 |
+
---
|
| 159 |
+
|
| 160 |
+
## Citation
|
| 161 |
+
|
| 162 |
+
If you use this dataset, please cite the IndoorVG paper:
|
| 163 |
+
|
| 164 |
+
```bibtex
|
| 165 |
+
@incollection{neau2023defense,
|
| 166 |
+
title={In defense of scene graph generation for human-robot open-ended interaction in service robotics},
|
| 167 |
+
author={Neau, Ma{"e}lic and Santos, Paulo and Bosser, Anne-Gwenn and Buche, C{'e}dric},
|
| 168 |
+
booktitle={Robot World Cup},
|
| 169 |
+
pages={299--310},
|
| 170 |
+
year={2023},
|
| 171 |
+
publisher={Springer}
|
| 172 |
+
}
|
| 173 |
+
```
|
| 174 |
+
|
| 175 |
+
And Visual Genome:
|
| 176 |
+
|
| 177 |
+
```bibtex
|
| 178 |
+
@article{krishna2017visual,
|
| 179 |
+
title={Visual genome: Connecting language and vision using crowdsourced dense image annotations},
|
| 180 |
+
author={Krishna, Ranjay and Zhu, Yuke and Groth, Oliver and Johnson, Justin and Hata, Kenji and Kravitz, Joshua and Chen, Stephanie and Kalantidis, Yannis and Li, Li-Jia and Shamma, David A and others},
|
| 181 |
+
journal={International journal of computer vision},
|
| 182 |
+
volume={123},
|
| 183 |
+
number={1},
|
| 184 |
+
pages={32--73},
|
| 185 |
+
year={2017},
|
| 186 |
+
publisher={Springer}
|
| 187 |
+
}
|
| 188 |
+
```
|
| 189 |
+
|
| 190 |
+
And the REACT paper if you use the SGG-Benchmark models:
|
| 191 |
+
|
| 192 |
+
```bibtex
|
| 193 |
+
@inproceedings{Neau_2025_BMVC,
|
| 194 |
+
author = {Ma\"elic Neau and Paulo Eduardo Santos and Anne-Gwenn Bosser
|
| 195 |
+
and Akihiro Sugimoto and Cedric Buche},
|
| 196 |
+
title = {REACT: Real-time Efficiency and Accuracy Compromise for Tradeoffs
|
| 197 |
+
in Scene Graph Generation},
|
| 198 |
+
booktitle = {36th British Machine Vision Conference 2025, {BMVC} 2025,
|
| 199 |
+
Sheffield, UK, November 24-27, 2025},
|
| 200 |
+
publisher = {BMVA},
|
| 201 |
+
year = {2025},
|
| 202 |
+
url = {https://bmva-archive.org.uk/bmvc/2025/assets/papers/Paper_239/paper.pdf},
|
| 203 |
+
}
|
| 204 |
+
```
|
| 205 |
+
|
| 206 |
+
---
|
| 207 |
+
|
| 208 |
+
## License
|
| 209 |
+
|
| 210 |
+
Visual Genome images and annotations are released under the
|
| 211 |
+
[Creative Commons Attribution 4.0 International (CC BY 4.0)](https://creativecommons.org/licenses/by/4.0/)
|
| 212 |
+
license.
|