Ich habe den folgenden Code:Achsen in Nebenhandlungen
import matplotlib.pyplot as plt
import matplotlib.image as mpimg
import matplotlib.cm as cm
img = mpimg.imread("lena.jpg")
f, axarr = plt.subplots(2, 2)
axarr[0,0].imshow(img, cmap = cm.Greys_r)
axarr[0,0].set_title("Rank = 512")
rank = 128
new_img = prune_matrix(rank, img)
axarr[0,1].imshow(new_img, cmap = cm.Greys_r)
axarr[0,1].set_title("Rank = %s" %rank)
rank = 32
new_img = prune_matrix(rank, img)
axarr[1,0].imshow(new_img, cmap = cm.Greys_r)
axarr[1,0].set_title("Rank = %s" %rank)
rank = 16
new_img = prune_matrix(rank, img)
axarr[1,1].imshow(new_img, cmap = cm.Greys_r)
axarr[1,1].set_title("Rank = %s" %rank)
plt.show()
Allerdings ist das Ergebnis ziemlich hässlich, weil der Werte auf den Achsen:
Wie kann ich abschalten Achsenwerte für alle Subplots gleichzeitig?
Was ist los mit http://stackoverflow.com/questions/9295026/matplotlib-plots-removing-axis-legends-and-white-spaces? Können Sie Ihren Code auch ausführbar machen? – Veedrac
Das Problem, dass die Achse ausgeschaltet ist, macht nur den letzten Teilplan unsichtbar. –