Skip to content

Commit

Permalink
update number of channels after transition_block (d2l-ai#525)
Browse files Browse the repository at this point in the history
  • Loading branch information
LaoLiulaoliu authored and astonzhang committed Apr 25, 2019
1 parent ca4a41a commit 61728ff
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion chapter_convolutional-neural-networks/densenet.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,8 @@ for i, num_convs in enumerate(num_convs_in_dense_blocks):
num_channels += num_convs * growth_rate
# 在稠密块之间加入通道数减半的过渡层
if i != len(num_convs_in_dense_blocks) - 1:
net.add(transition_block(num_channels // 2))
num_channels //= 2
net.add(transition_block(num_channels))
```

同ResNet一样,最后接上全局池化层和全连接层来输出。
Expand Down

0 comments on commit 61728ff

Please sign in to comment.