Last active
May 19, 2019 09:25
-
-
Save navin-mohan/3ad20ac8491a7f9f18ec34d5b84d4f57 to your computer and use it in GitHub Desktop.
resnet50 visualization
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
/* | |
** HOW TO USE | |
** -------------- | |
** Go to http://alexlenail.me/NN-SVG/AlexNet.html | |
** Open console (Ctrl + Shift + J on Chrome) | |
** Paste this script and hit enter | |
*/ | |
document.getElementsByClassName('btn btn-primary btn-add input-group-prepend')[0].classList.add('add-layer-btn') | |
function addValue(value_list){ | |
let add_layer_btn = document.getElementsByClassName('add-layer-btn btn-primary')[0]; | |
let siblings = add_layer_btn.parentNode.children; | |
for(let sibling of siblings){ | |
let name = sibling.getAttribute('name'); | |
if (name && name in value_list){ | |
sibling.value = value_list[name]; | |
} | |
} | |
add_layer_btn.click(); | |
} | |
items = [{"height": 512, "width": 256, "depth": 64, "filterHeight": 7, "filterWidth": 7}, {"height": 256, "width": 128, "depth": 64, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 64, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 64, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 256, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 64, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 64, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 256, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 64, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 64, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 256, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 128, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 128, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 512, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 128, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 128, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 512, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 128, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 128, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 512, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 128, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 128, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 512, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 256, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 256, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 1024, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 256, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 256, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 1024, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 256, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 256, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 1024, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 256, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 256, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 1024, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 256, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 256, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 1024, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 256, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 256, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 1024, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 512, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 512, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 2048, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 512, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 512, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 2048, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 512, "filterHeight": 1, "filterWidth": 1}, {"height": 128, "width": 64, "depth": 512, "filterHeight": 3, "filterWidth": 3}, {"height": 128, "width": 64, "depth": 2048, "filterHeight": 1, "filterWidth": 1}]; | |
for(let item of items){ | |
addValue(item); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment