Clothing Segmentation using deep learning.
First, after preprocessing the clothing dataset, four classes(backgrounds, skin, hiar, clothes) were segmented using deep neural network models(FCN, DeepLab, U-Net).
Clothing Co-Parsing(CCP) dataset that i used can be found https://github.com/bearpaw/clothing-co-parsing.
After importing the image data , divide into four classes(Background, hair, skin, clothes) and resize 384 x 256.
Models are found in model file. Model file includes FCN.py(Fully Covolutional Networks), DeepLabV2.py(DeepLab V2), UNet.py(U-Net). U-Net has shown the best performance among the models in this project.
- Python
- Keras
- Python packages : numpy, matplotlib, opencv, and so on...
In order to preprocessing the data, download the dataset from this.
Then copy the annotation and photo files into the same path as pre_processing.py or pre_processing.ipynb in the download file.
After that you copy files, you can implement the codes. You can use Segmentation.py to get a segmented image.
python pre_processing.py
python run_main.py --model unet
python segmentation.py --model_path ./save_model/UNet_model.h5 --image_path ./MyFile/example.png