@staticmethod
def init_colors(n_colors: int, randomize: bool=False) -> Sequence[ColorT]:
    color_map = plt.cm.get_cmap('Spectral', n_colors)
    colors = [tuple((int(round((c * 255))) for c in color_map(i)[:3])) for i in range(n_colors)]
    if randomize:
        random.shuffle(colors)
    return cast(Sequence[ColorT], colors)
@staticmethod
def init_colors(n_colors: int, randomize: bool=False) -> Sequence[ColorT]:
    color_map = plt.cm.get_cmap('Spectral', n_colors)
    colors = [tuple((int(round((c * 255))) for c in color_map(i)[:3])) for i in range(n_colors)]
    if randomize:
        random.shuffle(colors)
    return cast(Sequence[ColorT], colors)