import seaborn as sns
path1 = 'a.npy'
b = np.load(path1) # (n, 3)
b= np.reshape(b,(8,8))
sns.heatmap(rank,cmap=cm.coolwarm,annot=True)
plt.axis('off')
plt.savefig('b.png')
效果
import seaborn as sns
path1 = 'a.npy'
b = np.load(path1) # (n, 3)
b= np.reshape(b,(8,8))
sns.heatmap(rank,cmap=cm.coolwarm,annot=True)
plt.axis('off')
plt.savefig('b.png')
效果