.TH "MPSCNNPoolingAverage" 3 "Mon Jul 9 2018" "Version MetalPerformanceShaders-119.3" "MetalPerformanceShaders.framework" \" -*- nroff -*- .ad l .nh .SH NAME MPSCNNPoolingAverage .SH SYNOPSIS .br .PP .PP \fC#import \fP .PP Inherits \fBMPSCNNPooling\fP\&. .SS "Instance Methods" .in +1c .ti -1c .RI "(nonnull instancetype) \- \fBinitWithDevice:kernelWidth:kernelHeight:strideInPixelsX:strideInPixelsY:\fP" .br .ti -1c .RI "(nullable instancetype) \- \fBinitWithCoder:device:\fP" .br .in -1c .SS "Properties" .in +1c .ti -1c .RI "NSUInteger \fBzeroPadSizeX\fP" .br .ti -1c .RI "NSUInteger \fBzeroPadSizeY\fP" .br .in -1c .SS "Additional Inherited Members" .SH "Detailed Description" .PP This depends on Metal\&.framework Specifies the average pooling filter\&. For each pixel, returns the mean value of pixels in the kernelWidth x kernelHeight filter region\&. When \fBedgeMode\fP is \fBMPSImageEdgeModeClamp\fP the filtering window is shrunk to remain .SH "within the source image borders\&. What this means is that close to image borders the filtering window" .PP .PP will be smaller in order to fit inside the source image and less values will be used to compute the average\&. In case the filtering window is entirely outside the source image border the outputted value will be zero\&. .SH "Method Documentation" .PP .SS "\- (nullable instancetype) \fBinitWithCoder:\fP (NSCoder *__nonnull) aDecoder(nonnull id< MTLDevice >) device" \fBNSSecureCoding\fP compatability See \fBMPSKernel::initWithCoder\fP\&. .PP \fBParameters:\fP .RS 4 \fIaDecoder\fP The NSCoder subclass with your serialized \fBMPSCNNPooling\fP .br \fIdevice\fP The MTLDevice on which to make the \fBMPSCNNPooling\fP .RE .PP \fBReturns:\fP .RS 4 \fBA\fP new \fBMPSCNNPooling\fP object, or nil if failure\&. .RE .PP .PP Reimplemented from \fBMPSCNNPooling\fP\&. .SS "\- (nonnull instancetype) \fBinitWithDevice:\fP (nonnull id< MTLDevice >) device(NSUInteger) kernelWidth(NSUInteger) kernelHeight(NSUInteger) strideInPixelsX(NSUInteger) strideInPixelsY" Initialize a \fBMPSCNNPoolingAverage\fP pooling filter .PP \fBParameters:\fP .RS 4 \fIdevice\fP The device the filter will run on .br \fIkernelWidth\fP The width of the kernel\&. Can be an odd or even value\&. .br \fIkernelHeight\fP The height of the kernel\&. Can be an odd or even value\&. .br \fIstrideInPixelsX\fP The output stride (downsampling factor) in the x dimension\&. .br \fIstrideInPixelsY\fP The output stride (downsampling factor) in the y dimension\&. .RE .PP \fBReturns:\fP .RS 4 \fBA\fP valid \fBMPSCNNPooling\fP object or nil, if failure\&. .RE .PP .PP Reimplemented from \fBMPSCNNPooling\fP\&. .SH "Property Documentation" .PP .SS "\- zeroPadSizeX\fC [read]\fP, \fC [write]\fP, \fC [nonatomic]\fP, \fC [assign]\fP" How much zero padding to apply to both left and right borders of the input image for average pooling, when using .PP \fBSee also:\fP .RS 4 \fBedgeMode\fP \fBMPSImageEdgeModeClamp\fP\&. For .PP \fBedgeMode\fP \fBMPSImageEdgeModeZero\fP this property is ignored and the area outside the image is interpreted to contain zeros\&. The zero \fBpadding\fP size is used to shrink the pooling window to fit inside the area bound by the source image and its \fBpadding\fP region, but the effect is that the normalization factor of the average computation is computed also for the zeros in the \fBpadding\fP region\&. .RE .PP .SS "\- zeroPadSizeY\fC [read]\fP, \fC [write]\fP, \fC [nonatomic]\fP, \fC [assign]\fP" How much zero padding to apply to both top and bottom borders of the input image for average pooling, when using .PP \fBSee also:\fP .RS 4 \fBedgeMode\fP \fBMPSImageEdgeModeClamp\fP\&. For .PP \fBedgeMode\fP \fBMPSImageEdgeModeZero\fP this property is ignored and the area outside the image is interpreted to contain zeros\&. The zero \fBpadding\fP size is used to shrink the pooling window to fit inside the area bound by the source image and its \fBpadding\fP region, but the effect is that the normalization factor of the average computation is computed also for the zeros in the \fBpadding\fP region\&. .RE .PP .SH "Author" .PP Generated automatically by Doxygen for MetalPerformanceShaders\&.framework from the source code\&.