({{, (RefLink[LocalResponseNormalizationLayer, paclet:ref/LocalResponseNormalizationLayer])[] 
represents a net layer that normalizes its input by averaging across neighboring input channels.}})

OpenersNotesSection(Spacer1)Details and Options

The following optional parameters can be included:

(RefLink[LocalResponseNormalizationLayer, paclet:ref/LocalResponseNormalizationLayer])[…][input] explicitly computes the output from applying the layer.

(RefLink[LocalResponseNormalizationLayer, paclet:ref/LocalResponseNormalizationLayer])[…][{(Subscript[input, 1]),(Subscript[input, 2]),…}] explicitly computes outputs for each of the (Subscript[input, i]).

When given a (RefLink[NumericArray, paclet:ref/NumericArray]) as input, the output will be a (RefLink[NumericArray, paclet:ref/NumericArray]).

(RefLink[LocalResponseNormalizationLayer, paclet:ref/LocalResponseNormalizationLayer]) is typically used inside (RefLink[NetChain, paclet:ref/NetChain]), (RefLink[NetGraph, paclet:ref/NetGraph]), etc.

(RefLink[LocalResponseNormalizationLayer, paclet:ref/LocalResponseNormalizationLayer]) exposes the following ports for use in (RefLink[NetGraph, paclet:ref/NetGraph]) etc.:

When it cannot be inferred from other layers in a larger net, the option "Input"->{(Subscript[n, 1]),(Subscript[n, 2]),(Subscript[n, 3])} can be used to fix the input dimensions of (RefLink[LocalResponseNormalizationLayer, paclet:ref/LocalResponseNormalizationLayer]).

The output array (Subscript[O, ijk]) is obtained via (Subscript[O, ijk])=((Subscript[T, ijk])/(Subscript[D, ijk])), where (Subscript[D, ijk])=((((α/(2c+1)) (∑_( x = max(1, i-c))^( min(N, c+i)))(Subscript[T, xjk]^2)+b))^β), (Subscript[T, ijk]) is the input, α is the "Alpha" parameter, β is the "Beta" parameter, c is the "ChannelWindowSize" and N is the number of channels in the input (Subscript[T, ijk]).

OpenersPrimaryExamplesSection(Spacer1)Examples  (4)

OpenersExampleSection0(Spacer1)Basic Examples  (2)

Create a (RefLink[LocalResponseNormalizationLayer, paclet:ref/LocalResponseNormalizationLayer]):

LocalResponseNormalizationLayer[]

Create a (RefLink[LocalResponseNormalizationLayer, paclet:ref/LocalResponseNormalizationLayer]) with input dimensions specified:

lrn=LocalResponseNormalizationLayer["Input"->{5,2,1}]

Apply the layer to an input:

lrn[RandomReal[1,{5,2,1}]]//MatrixForm

OpenersExampleSection1(Spacer1)Scope  (1)

Create a (RefLink[LocalResponseNormalizationLayer, paclet:ref/LocalResponseNormalizationLayer]) with input dimensions specified:

lrn=LocalResponseNormalizationLayer["Input"->{5,1,1}]

Apply the layer to an input:

data={{{-2}},{{-1}},{{0}},{{1}},{{2}}};
lrn[data]

Thread the layer across a batch of inputs:

lrn[{data,-data}]

OpenersExampleSection4(Spacer1)Possible Issues  (1)

The number of input channels must be larger than 2×(channel window size)+ 1:

LocalResponseNormalizationLayer["ChannelWindowSize"-> 5,"Input"-> {3,25,25}]

({{DocumentationFooterIconsRelatedFunction.png, ({{See Also}, {(RefLink[ConvolutionLayer, paclet:ref/ConvolutionLayer])  ▪  (RefLink[PoolingLayer, paclet:ref/PoolingLayer])  ▪  (RefLink[BatchNormalizationLayer, paclet:ref/BatchNormalizationLayer])  ▪  (RefLink[NetChain, paclet:ref/NetChain])  ▪  (RefLink[NetGraph, paclet:ref/NetGraph])  ▪  (RefLink[NetInitialize, paclet:ref/NetInitialize])  ▪  (RefLink[NetTrain, paclet:ref/NetTrain])  ▪  (RefLink[NetExtract, paclet:ref/NetExtract])}})}})

({{DocumentationFooterIconsRelatedTutorial.png, ({{Tutorials}, {▪(RefLinkPlain[Neural Networks in the Wolfram Language, paclet:tutorial/NeuralNetworksOverview])}})}})

({{DocumentationFooterIconsRelatedGuide.png, ({{Related Guides}, {▪(RefLinkPlain[Neural Networks, paclet:guide/NeuralNetworks])}})}})