block_half: Block Half

Description Usage Arguments Details Value See Also

Description

This function creates a block of convolutional layers with max pooling such that the dimension of the outputs is halved after each block.

Usage

1
2
3
block_half(object, initial_filters = 2, kernel_size = c(3, 3, 3),
  num_steps = 1, batch_normalization = FALSE, dropout = 0,
  use_maxpooling = TRUE, activation = "relu")

Arguments

object

(keras object) Object to which append this block

initial_filters

(numeric) Number of filters in the first convolutional layer, Default: 2

kernel_size

(list or vector) size of the convolution kernels, Default: c(3, 3, 3)

num_steps

(integer) Number of steps to perform downsampling, Default: 1 if kernel_size is a vector or its length if it's a list.

activation

(character) Activation function in the block layers, Default: 'relu'

Details

In each step, the number of filters is doubled wrt the previous step. Thus, if initial_filters == 2, the number of filters in the layers in this block is: 2, 4, 8, 16...

Value

The composed object.

See Also

block_upsample block_unet

Other blocks: block_double


neuroimaginador/dl4ni documentation built on May 3, 2019, 5:47 p.m.