Code to change rgb colors to label numbers