The question is clear but the title is not as precise as it could be. My answer is for those who came looking to change the axis label, as opposed to the tick labels, which is what the accepted answer is about. (The title has now been corrected).
for ax in plt.gcf().axes:
plt.sca(ax)
plt.xlabel(ax.get_xlabel(), rotation=90)