海阳网网站,网站优化 h几 更易被抓,wordpress图片排列,书店网页设计图片这是我想出的解决方案。谢谢mprat的帮助。在我发现spectralcolormap最适合这种任务#xff0c;而且我还添加了您可以指定的边框。在from matplotlib import pyplotimport numpy as npborder 2images_amount 300row_amount 10col_amount 30image_height 28image_width 28…这是我想出的解决方案。谢谢mprat的帮助。在我发现spectralcolormap最适合这种任务而且我还添加了您可以指定的边框。在from matplotlib import pyplotimport numpy as npborder 2images_amount 300row_amount 10col_amount 30image_height 28image_width 28all_filter_image np.zeros((row_amount*image_height border*row_amount,col_amount*image_width border*col_amount))for filter_num in range(images_amount):start_row image_height*(filter_num / col_amount) \(filter_num / col_amount 1)*borderend_row start_row image_heightstart_col image_width*(filter_num % col_amount) \(filter_num % col_amount 1)*borderend_col start_col image_widthall_filter_image[start_row:end_row, start_col:end_col] \all_filters[filter_num]print start_row, end_row, start_col, end_colpyplot.imshow(all_filter_image)pyplot.axis(off)pyplot.set_cmap(spectral)pyplot.colorbar()pyplot.savefig(repflds1.png)以下是一些用法示例不太训练有素的网络训练有素的网络正如你所看到的边界使得区分一个过滤器(权重)和另一个过滤器变得非常容易。在