This repository provides tools to resize computer vision datasets, enabling the enhancement of image and annotation resolutions (such as segmentation masks) using super-resolution techniques and mask refinement.
This repository is under continous development.
To install resize-dataset you can clone the repository and use pip.
Clone the repository.
git clone https://javierganan99/resize-dataset.git
cd resize-dataset
Install the tool using pip.
Just use it (not recommended).
pip install .
Editable mode.
pip install -e .
resize-dataset can be accessed through both the Command-Line Interface (CLI) and Python code. The deault parameters are configured in the resize-dataset/cfg/default.yaml
file, and overwritten by the specified arguments in the CLI or Python calls.
resize-dataset may be used directly in the Command Line Interface (CLI), with the following command format:
resize-dataset <task> <arg1=value2> <arg2=value2> ...
For example:
resize-dataset scale scale_factor=4 dataset_format=coco dataset_task=segmentation show
DAM may also be used directly in a Python environment, and it accepts the same arguments as in the CLI example above:
from resize_dataset import resize_dataset
# Scale a dataset
resize_dataset(task="scale", images_path="/your_path/coco_dataset/val2017", labels_path="/your_path/coco_dataset/panoptic_val2017.json", dataset_format="coco", dataset_task="panoptic")