Skip to content

Commit

Permalink
<model> Removed layer shortcut for FCN.
Browse files Browse the repository at this point in the history
  • Loading branch information
benjaminplanche authored Apr 27, 2020
1 parent 0562a23 commit 46f2a7b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Chapter07/fcn.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,10 +60,10 @@ def fcn_8s(image_size, ch_in=3, ch_out=3):
f5_conv3 = Conv2D(filters=ch_out, kernel_size=1, padding='same',
activation=None)(f5_drop2)

# Using a transposed conv (w/ s=2) to upscale `f5` into a 14 x 14 map
# Using a transposed conv (w/ s=2) to upscale `f5_conv3` into a 14 x 14 map
# so it can be merged with features from `f4_conv1` obtained from `f4`:
f5_conv3_x2 = Conv2DTranspose(filters=ch_out, kernel_size=4, strides=2,
use_bias=False, padding='same', activation='relu')(f5)
use_bias=False, padding='same', activation='relu')(f5_conv3)
f4_conv1 = Conv2D(filters=ch_out, kernel_size=1, padding='same',
activation=None)(f4)

Expand All @@ -83,4 +83,4 @@ def fcn_8s(image_size, ch_in=3, ch_out=3):
padding='same', activation=None, name='predictions')(merge2)

fcn8s_model = Model(inputs, outputs)
return fcn8s_model
return fcn8s_model

0 comments on commit 46f2a7b

Please sign in to comment.