An implementation of "Song, Yibing & Bao, Linchao & Xu, Xiaobin & Yang, Qingxiong. (2013). Decolorization: Is rgb2gray() out?. SIGGRAPH Asia 2013 Technical Briefs, SA "
- python3 (or higher)
- opencv 3.0
install package
- numpy
- matplotlib
$ python main.py --mode <c: conventional; a: advanced> -i <input image folder> -o <output directory>
# for example to process advanced grayscale
$ python main.py
The program will output:
- Conventional mode
- RGB image convert to grayscale image using
Y = 0.299 * R + 0.587 * G + 0.114 * B
formula
- RGB image convert to grayscale image using
- Advanced mode
- RGB image convert to grayscale image using Decolorization: Is rgb2gray() Out? method to select weight
- Record weight and vote in save file name
- Processing all image in input folder
- Save process result in output directory
see more detail in Report