I'm writing a script to classify images based on their features: Histogram, color balance, keypoint count, etc. And although the function that I wrote to display the charts works fine:
fig,axes = plt.subplots(2,3,figsize=(15,7))
axes[0, 0].scatter((zip(*xy_a))[0], (zip(*xy_a))[1])
for i, txt in enumerate(xy_na): axes[0, 0].annotate(txt, ((zip(*xy_a))[0][i],(zip(*xy_a))[1][i]))
axes[0, 0].set_title("xy_a")
axes[0, 0].set_xlabel('Histogram')
axes[0, 0].set_ylabel('Average Pixel')
axes[1, 0].scatter(*zip(*xy_b))
for i, txt in enumerate(xy_na): axes[1, 0].annotate(txt, ((zip(*xy_b))[0][i],(zip(*xy_b))[1][i]))
axes[1, 0].set_title("xy_b")
axes[1, 0].set_xlabel('Average Pixel')
axes[1, 0].set_ylabel('Keypoint Number')
axes[0, 1].scatter(*zip(*xy_c))
for i, txt in enumerate(xy_na): axes[0, 1].annotate(txt, ((zip(*xy_c))[0][i],(zip(*xy_c))[1][i]))
axes[0, 1].set_title("xy_c")
axes[0, 1].set_xlabel('Keypoint Number')
axes[0, 1].set_ylabel('Histogram')
axes[1, 1].scatter(*zip(*xy_d))
for i, txt in enumerate(xy_na): axes[1, 1].annotate(txt, ((zip(*xy_d))[0][i],(zip(*xy_d))[1][i]))
axes[1, 1].set_title("xy_d")
axes[1, 1].set_xlabel('Dimentional Mean')
axes[1, 1].set_ylabel('Histogram')
axes[0, 2].scatter(*zip(*xy_e))
for i, txt in enumerate(xy_na): axes[0, 2].annotate(txt, ((zip(*xy_e))[0][i],(zip(*xy_f))[1][i]))
axes[0, 2].set_title("xy_e")
axes[0, 2].set_xlabel('Average Pixel')
axes[0, 2].set_ylabel('Dimentional Mean')
axes[1, 2].scatter(*zip(*xy_f))
for i, txt in enumerate(xy_na): axes[1, 2].annotate(txt, ((zip(*xy_f))[0][i],(zip(*xy_f))[1][i]))
axes[1, 2].set_title("xy_f")
axes[1, 2].set_xlabel('Keypoint Number')
axes[1, 2].set_ylabel('Dimentional Mean')
fig.tight_layout()
fig.suptitle("Folder: {}".format ((str(folder_path)).split("/")[-1]))
plt.show()
The chart that it generates is less than readable:
That folder has 13 images in it: 11 facial shots and 2 group pictures. Now, it's not entirely unreadable, but what happens when I run it on a folder with 100 images?
There are other answers on overlapping annotations, but none of them are applicable to my one-liner annotation scheme. If anyone could find a solution to my problem, that would be great.