numpy
opencv-python
Before: the block at left-top corner is bounded by a white box.
After: Image is rotated anticlockwise by 30 degree and the block is still bounded by the white box.
.
├── check_label.py
├── rotation.py
├── data_original
│ ├── images
│ │ └── test00.png
│ └── labels
│ └── test00.txt
└── data_rotational
├── images
│ ├── test00_000.jpg
│ ├── test00_030.jpg
│ └── ...
└── labels
├── test00_000.txt
├── test00_030.txt
└── ...
data_original
is directory with your images and labels. After running rotation.py
, rotated images and labels will be stored in data_rotational
.
python rotation.py DATASET_INPUT
DATASET_INPUT
is data_original
in this example. The default output destination directory is data_rotational
.
You can use python rotation.py -h
to get more information.
python check_label.py DATASET_INPUT
DATASET_INPUT
is data_rotational
in this example.
You can use python check_label.py -h
to get more information.