Last active
April 17, 2019 13:25
-
-
Save saurabhpal97/8e6c484546beeb167363bc690fb3ca41 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
layers = model.layers | |
layer_ids = [1,4,7,11,15] | |
#plot the filters | |
fig,ax = plt.subplots(nrows=1,ncols=5) | |
for i in range(5): | |
ax[i].imshow(layers[layer_ids[i]].get_weights()[0][:,:,:,0][:,:,0],cmap='gray') | |
ax[i].set_title('block'+str(i+1)) | |
ax[i].set_xticks([]) | |
ax[i].set_yticks([]) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment