def get_primaries_matrix(xy_red, xy_green, xy_blue):
    XYZ_red = xy_to_XYZ(xy_red)
    XYZ_green = xy_to_XYZ(xy_green)
    XYZ_blue = xy_to_XYZ(xy_blue)
    primaries_matrix = numpy.matrix(
        [
            [XYZ_red[0], XYZ_green[0], XYZ_blue[0]],
            [XYZ_red[1], XYZ_green[1], XYZ_blue[1]],
            [XYZ_red[2], XYZ_green[2], XYZ_blue[2]],
        ])
    return primaries_matrix
Return primaries XYZ matrix form xy coords
dataset/ETHPy150Open mikrosimage/ColorPipe-tools/utils/colors_helper.py/get_primaries_matrix