Metadata-Version: 2.1
Name: poly2pascal
Version: 0.0.1
Summary: Convert POLYGON bounding boxes from .csv files to .xml annotation files in the Pascal VOC format for computer vision projects.
Home-page: https://github.com/ruankie/poly2pascal
Author: Ruan Pretorius
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Operating System :: OS Independent
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: opencv-python (>=4)
Requires-Dist: geopandas (>=0.10)
Provides-Extra: dev
Requires-Dist: pytest (>=7) ; extra == 'dev'
Requires-Dist: black (>=22) ; extra == 'dev'
Requires-Dist: pylint (>=2) ; extra == 'dev'
Requires-Dist: jupyterlab (>=3) ; extra == 'dev'

# poly2pascal
Convert POLYGON bounding boxes from `.csv` files to `.xml` annotation files in the Pascal VOC format for computer vision projects.

## Installation
Install `poly2pascal` with pip
```bash
  pip install poly2pascal
```

## Usage
See the example notebook for more details. Here are the essentials:
```python
# import annotator
from poly2pascal.annotations import XMLAnnotator

# create annotator
xmla = XMLAnnotator(
    images_path="path/to/images", 
    csv_file_path="path/to/csv/file.csv", 
    image_name_col="<image_name_column>",
    image_label_col="<object_label_column>", 
    xml_output_path="path/to/xml/annotation/output"
)

# create xml annotation files in Pascal VOC format
xmla.get_all_xml_annotations(img_format=".jpg")
```

## Licence
* [MIT](./LICENSE)

## Authors
- [@ruankie](https://www.github.com/ruankie)

## TODO
### Essential
- [x] add jupyterlab to dev requirements
- [x] run through example notebook to ensure everythin works as expected
- [ ] build and publish on pypi test
- [ ] build and publish to pypi
- [ ] format with black
- [ ] add badges to README
- [ ] show example of csv data schema
- [ ] fix docstrings

### Optional
- [ ] pylint score >= 8.0
- [ ] add Sphinx docs
- [ ] add unit tests
- [ ] add github actions for automated testing
- [ ] add code coverage

## References
- [Build python package](https://towardsdatascience.com/how-to-convert-your-python-project-into-a-package-installable-through-pip-a2b36e8ace10)
