提交 4ccbc17f 编写于 作者: 别团等shy哥发育's avatar 别团等shy哥发育

ResNet101V2、ResNet152V2模型复现

上级 f103f1b5
......@@ -3,7 +3,8 @@ import tensorflow.keras.layers as layers
from tensorflow.keras.models import Model
from plot_model import plot_model
"""A residual block.
"""
A residual block.
Arguments:
x: input tensor.
filters: integer, filters of the bottleneck layer.
......@@ -14,9 +15,7 @@ from plot_model import plot_model
name: string, block label.
Returns:
Output tensor for the residual block.
"""
"""
def block2(x, filters, kernel_size=3, stride=1, conv_shortcut=False, name=None):
preact = layers.BatchNormalization(name=name + '_preact_bn')(x)
preact = layers.Activation('relu', name=name + '_preact_relu')(preact)
......@@ -183,4 +182,6 @@ if __name__ == '__main__':
model152=ResNet152V2(input_shape=(224,224,3))
model152.summary()
# plot_model(model, to_file='../img/resnet50v2.png')
# plot_model(model, to_file='img/resnet50v2.png')
# plot_model(model101, to_file='img/resnet101v2.png')
# plot_model(model152, to_file='img/resnet152v2.png')
......@@ -36,7 +36,7 @@
"cell_type": "code",
"execution_count": 3,
"metadata": {
"scrolled": false
"scrolled": true
},
"outputs": [
{
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册