Save comparison script
This commit is contained in:
parent
f3123e38c3
commit
7523ca8878
|
@ -0,0 +1,12 @@
|
||||||
|
import cv2
|
||||||
|
import numpy as np
|
||||||
|
|
||||||
|
class ComparisonComparison:
|
||||||
|
def convert_color (self, color, color_space) :
|
||||||
|
pixel = np.zeros([1, 1, 3], dtype=np.uint8)
|
||||||
|
pixel[:] = color
|
||||||
|
cvt = cv2.cvtColor(pixel, color_space)
|
||||||
|
return cvt[0, 0]
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
|
ComparisonComparison()
|
Loading…
Reference in New Issue