Just thresholding red and and blue then calculating the angle of the line between the two relative to the horizontal done using opencv's python bindings. for ...