As the colors in Matplotlib can be specified with a wide variety of ways, this new version consists of a method matplotlib.colors.same_color which checks if two colors are the same.
matplotlib.colors.same_color
colors