Datasets:
Improve dataset card for Seg-Zero: Add license, tags, abstract, features, and usage (#3)
Browse files- Improve dataset card for Seg-Zero: Add license, tags, abstract, features, and usage (8decf5001068a7af014f888c65af3046733ac11f)
Co-authored-by: Niels Rogge <nielsr@users.noreply.huggingface.co>
README.md
CHANGED
|
@@ -1,4 +1,11 @@
|
|
| 1 |
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 2 |
dataset_info:
|
| 3 |
features:
|
| 4 |
- name: id
|
|
@@ -24,10 +31,60 @@ configs:
|
|
| 24 |
data_files:
|
| 25 |
- split: train
|
| 26 |
path: data/train-*
|
| 27 |
-
task_categories:
|
| 28 |
-
- image-segmentation
|
| 29 |
---
|
| 30 |
|
| 31 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 32 |
|
| 33 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
---
|
| 2 |
+
task_categories:
|
| 3 |
+
- image-segmentation
|
| 4 |
+
license: cc-by-nc-4.0
|
| 5 |
+
tags:
|
| 6 |
+
- reasoning
|
| 7 |
+
- reinforcement-learning
|
| 8 |
+
- zero-shot
|
| 9 |
dataset_info:
|
| 10 |
features:
|
| 11 |
- name: id
|
|
|
|
| 31 |
data_files:
|
| 32 |
- split: train
|
| 33 |
path: data/train-*
|
|
|
|
|
|
|
| 34 |
---
|
| 35 |
|
| 36 |
+
# Seg-Zero Dataset: Reasoning-Chain Guided Segmentation via Cognitive Reinforcement
|
| 37 |
+
|
| 38 |
+
This repository hosts the training dataset introduced in the paper [Seg-Zero: Reasoning-Chain Guided Segmentation via Cognitive Reinforcement](https://huggingface.co/papers/2503.06520).
|
| 39 |
+
|
| 40 |
+
## Abstract
|
| 41 |
+
Traditional methods for reasoning segmentation rely on supervised fine-tuning with categorical labels and simple descriptions, limiting its out-of-domain generalization and lacking explicit reasoning processes. To address these limitations, we propose Seg-Zero, a novel framework that demonstrates remarkable generalizability and derives explicit chain-of-thought reasoning through cognitive reinforcement. Seg-Zero introduces a decoupled architecture consisting of a reasoning model and a segmentation model. The reasoning model interprets user intentions, generates explicit reasoning chains, and produces positional prompts, which are subsequently used by the segmentation model to generate precious pixel-level masks. We design a sophisticated reward mechanism that integrates both format and accuracy rewards to effectively guide optimization directions. Trained exclusively via reinforcement learning with GRPO and without explicit reasoning data, Seg-Zero achieves robust zero-shot generalization and exhibits emergent test-time reasoning capabilities. Experiments show that Seg-Zero-7B achieves a zero-shot performance of 57.5 on the ReasonSeg benchmark, surpassing the prior LISA-7B by 18%. This significant improvement highlights Seg-Zero's ability to generalize across domains while presenting an explicit reasoning process.
|
| 42 |
+
|
| 43 |
+
## Code and Project Links
|
| 44 |
+
* **Paper Link:** [https://huggingface.co/papers/2503.06520](https://huggingface.co/papers/2503.06520)
|
| 45 |
+
* **Code Repository:** [https://github.com/dvlab-research/Seg-Zero](https://github.com/dvlab-research/Seg-Zero)
|
| 46 |
+
|
| 47 |
+
## Dataset Description
|
| 48 |
+
This dataset is designed for training and evaluating models on reasoning-chain guided image segmentation tasks. It contains `2000` examples in the `train` split, with each entry comprising:
|
| 49 |
+
- `id`: Unique identifier for the sample.
|
| 50 |
+
- `problem`: The reasoning problem or question.
|
| 51 |
+
- `solution`: The explicit reasoning chain or solution.
|
| 52 |
+
- `image`: The input image.
|
| 53 |
+
- `img_height`: Height of the image.
|
| 54 |
+
- `img_width`: Width of the image.
|
| 55 |
+
|
| 56 |
+
## Key Features of Seg-Zero (Associated Framework)
|
| 57 |
+
This dataset supports the Seg-Zero framework, which demonstrates the following key features:
|
| 58 |
+
1. **Emergent Test-Time Reasoning**: Seg-Zero exhibits emergent test-time reasoning ability. It generates a reasoning chain before producing the final segmentation mask.
|
| 59 |
+
2. **Reinforcement Learning Only**: Seg-Zero is trained exclusively using reinforcement learning, without any explicit supervised reasoning data.
|
| 60 |
+
3. **Superior Generalization**: Compared to supervised fine-tuning, Seg-Zero achieves superior performance on both in-domain and out-of-domain data.
|
| 61 |
+
|
| 62 |
+
## Sample Usage
|
| 63 |
+
You can load the dataset using the Hugging Face `datasets` library:
|
| 64 |
+
|
| 65 |
+
```python
|
| 66 |
+
from datasets import load_dataset
|
| 67 |
+
|
| 68 |
+
# Load the training split of the Seg-Zero dataset
|
| 69 |
+
dataset = load_dataset("Ricky06662/Seg-Zero", split="train")
|
| 70 |
+
|
| 71 |
+
# Access the first example
|
| 72 |
+
print(dataset[0])
|
| 73 |
+
|
| 74 |
+
# Example of accessing image and problem statement
|
| 75 |
+
print(f"Problem: {dataset[0]['problem']}")
|
| 76 |
+
dataset[0]['image'].save("first_image.png")
|
| 77 |
+
print("First image saved as first_image.png")
|
| 78 |
+
```
|
| 79 |
+
|
| 80 |
+
## Citation
|
| 81 |
+
If you find this dataset or the associated work useful, please cite the paper:
|
| 82 |
|
| 83 |
+
```bibtex
|
| 84 |
+
@article{liu2025segzero,
|
| 85 |
+
title = {Seg-Zero: Reasoning-Chain Guided Segmentation via Cognitive Reinforcement},
|
| 86 |
+
author = {Liu, Yuqi and Peng, Bohao and Zhong, Zhisheng and Yue, Zihao and Lu, Fanbin and Yu, Bei and Jia, Jiaya},
|
| 87 |
+
journal = {arXiv preprint arXiv:2503.06520},
|
| 88 |
+
year = {2025}
|
| 89 |
+
}
|
| 90 |
+
```
|