bstool is a Python library for Building Segmentation.
It will provide the following functionalities.
- Basic parse and dump functions for building segmentation dataset
- Evaluation tools
- Visualization tools
- Dataset convert
- Python 3.6+
- Pytorch 1.1+
- CUDA 9.0+
- mmcv
- pycocotools (pip install lvis@git+https://github.com/open-mmlab/cocoapi.git#subdirectory=lvis)
git clone https://github.com/jwwangchn/bstool.git
cd bstool
python setup.py develop
- Parse shapefile
- Show polygons or show polygons on corresponding image
- Merge separate polygon in original shapefile
- Parse ignore file (png)
- Add ignore flag to properties
- Show ignored polygons
- Split large image and corresponding polygons
- Convert Json to COCO format
- COCO format visualization codes
- Merge detection results on small image to original image
- Generate CSV file for evaluation (xian fine)
- Evaluation codes for semantic segmentation
- Evaluation codes for instance segmentation
- Visualization code for ground truth CSV file and prediction CSV file
- Visualization code for TP, FN, FP (pred and gt)
- Evaluation codes for offset
- Evaluation codes for height
- demo: Simple demo to illustrate how to use the corresponding functions
- tools: Put the codes for projects
- bstool
- datasets: Parse and dump data for dataset (e.g. shapefile, coco, json file)
- evaluation: Detection and segmentation evaluation codes
- generation: Generation the specific objects (e.g. empty images, polygons on pixel annotation)
- ops: Operators (e.g. bbox nms, mask nms)
- transforms: bbox, mask, image transformation functions (e.g. mask to polygon, polygon to mask)
- image
- bbox
- mask
- visualization: Codes for visualization
- image
- mask
- bbox
- color
- utils
- utils: Small useful tools for general tasks
- path
- mask
- csrc: Codes for cuda operation (Note: if you meet the compilation errors, please comment this section in setup.py)