Skip to content
This repository was archived by the owner on Aug 15, 2019. It is now read-only.

Commit 4fc5c1f

Browse files
committed
Remove impl
1 parent e3631c6 commit 4fc5c1f

File tree

1 file changed

+7
-84
lines changed

1 file changed

+7
-84
lines changed

src/ops/pool.ts

+7-84
Original file line numberDiff line numberDiff line change
@@ -509,52 +509,13 @@ function withSpaceToBatchBasePaddings(
509509
* - For more info, see this guide:
510510
* [https://www.tensorflow.org/api_guides/python/nn#Convolution](
511511
* https://www.tensorflow.org/api_guides/python/nn#Convolution)
512-
* @param dimRoundingMode The rounding mode used when computing output
513-
* dimensions if pad is a number. If none is provided, it will not round
514-
* and error if the output is of fractional size.
515-
* @param dataFormat An optional string from: "NDHWC", "NCDHW". Defaults to
516-
* "NDHWC". Specify the data format of the input and output data. With the
517-
* default format "NDHWC", the data is stored in the order of: [batch,
518-
* depth, height, width, channels]. Only "NDHWC" is currently supported.
519-
*/
520-
/** @doc {heading: 'Operations', subheading: 'Convolution'} */
521-
function avgPool3d_(
522-
x: Tensor5D|TensorLike, filterSize: [number, number, number]|number,
523-
strides: [number, number, number]|number, pad: 'valid'|'same'|number,
524-
dimRoundingMode?: 'floor'|'round'|'ceil',
525-
dataFormat: 'NDHWC'|'NCDHW' = 'NDHWC'): Tensor5D {
526-
return avgPool3dImpl_(
527-
x, filterSize, strides, 1, pad, dimRoundingMode, dataFormat);
528-
}
529-
530-
/**
531-
* Computes the 3D average pooling.
532-
*
533-
* @param x The input tensor, of rank 5 of shape
534-
* `[batch, depth, height, width, inChannels]`.
535-
* @param filterSize The filter size:
536-
* `[filterDepth, filterHeight, filterWidth]`.
537-
* If `filterSize` is a single number,
538-
* then `filterDepth == filterHeight == filterWidth`.
539-
* @param strides The strides of the pooling:
540-
* `[strideDepth, strideHeight, strideWidth]`.
541-
* If `strides` is a single number,
542-
* then `strideDepth == strideHeight == strideWidth`.
543512
* @param dilations The dilation rates:
544513
* `[dilationDepth, dilationHeight, dilationWidth]`
545514
* in which we sample input values across the depth, height and width
546515
* dimensions in dilated pooling.
547516
* Defaults to `[1, 1, 1]`. If `dilations` is a single number,
548517
* then `dilationDepth == dilationHeight == dilationWidth`.
549518
* If it is greater than 1, then all values of `strides` must be 1.
550-
* @param pad The type of padding algorithm.
551-
* - `same` and stride 1: output will be of same size as input,
552-
* regardless of filter size.
553-
* - `valid`: output will be smaller than input if filter is larger
554-
* than 1*1x1.
555-
* - For more info, see this guide:
556-
* [https://www.tensorflow.org/api_guides/python/nn#Convolution](
557-
* https://www.tensorflow.org/api_guides/python/nn#Convolution)
558519
* @param dimRoundingMode The rounding mode used when computing output
559520
* dimensions if pad is a number. If none is provided, it will not round
560521
* and error if the output is of fractional size.
@@ -563,10 +524,10 @@ function avgPool3d_(
563524
* default format "NDHWC", the data is stored in the order of: [batch,
564525
* depth, height, width, channels]. Only "NDHWC" is currently supported.
565526
*/
566-
function avgPool3dImpl_(
527+
/** @doc {heading: 'Operations', subheading: 'Convolution'} */
528+
function avgPool3d_(
567529
x: Tensor5D|TensorLike, filterSize: [number, number, number]|number,
568-
strides: [number, number, number]|number,
569-
dilations: [number, number, number]|number, pad: 'valid'|'same'|number,
530+
strides: [number, number, number]|number, pad: 'valid'|'same'|number,
570531
dimRoundingMode?: 'floor'|'round'|'ceil',
571532
dataFormat: 'NDHWC'|'NCDHW' = 'NDHWC'): Tensor5D {
572533
const $x = convertToTensor(x, 'x', 'avgPool3d', 'float32');
@@ -706,52 +667,13 @@ function avgPool3dBackprop(
706667
* - For more info, see this guide:
707668
* [https://www.tensorflow.org/api_guides/python/nn#Convolution](
708669
* https://www.tensorflow.org/api_guides/python/nn#Convolution)
709-
* @param dimRoundingMode The rounding mode used when computing output
710-
* dimensions if pad is a number. If none is provided, it will not round
711-
* and error if the output is of fractional size.
712-
* @param dataFormat An optional string from: "NDHWC", "NCDHW". Defaults to
713-
* "NDHWC". Specify the data format of the input and output data. With the
714-
* default format "NDHWC", the data is stored in the order of: [batch,
715-
* depth, height, width, channels]. Only "NDHWC" is currently supported.
716-
*/
717-
/** @doc {heading: 'Operations', subheading: 'Convolution'} */
718-
function maxPool3d_(
719-
x: Tensor5D|TensorLike, filterSize: [number, number, number]|number,
720-
strides: [number, number, number]|number, pad: 'valid'|'same'|number,
721-
dimRoundingMode?: 'floor'|'round'|'ceil',
722-
dataFormat: 'NDHWC'|'NCDHW' = 'NDHWC'): Tensor5D {
723-
return maxPool3dImpl_(
724-
x, filterSize, strides, 1, pad, dimRoundingMode, dataFormat);
725-
}
726-
727-
/**
728-
* Computes the 3D max pooling.
729-
*
730-
* @param x The input tensor, of rank 5 of shape
731-
* `[batch, depth, height, width, inChannels]`.
732-
* @param filterSize The filter size:
733-
* `[filterDepth, filterHeight, filterWidth]`.
734-
* If `filterSize` is a single number,
735-
* then `filterDepth == filterHeight == filterWidth`.
736-
* @param strides The strides of the pooling:
737-
* `[strideDepth, strideHeight, strideWidth]`.
738-
* If `strides` is a single number,
739-
* then `strideDepth == strideHeight == strideWidth`.
740670
* @param dilations The dilation rates:
741671
* `[dilationDepth, dilationHeight, dilationWidth]`
742672
* in which we sample input values across the depth, height and width
743673
* dimensions in dilated pooling.
744674
* Defaults to `[1, 1, 1]`. If `dilations` is a single number,
745675
* then `dilationDepth == dilationHeight == dilationWidth`.
746676
* If it is greater than 1, then all values of `strides` must be 1.
747-
* @param pad The type of padding algorithm.
748-
* - `same` and stride 1: output will be of same size as input,
749-
* regardless of filter size.
750-
* - `valid`: output will be smaller than input if filter is larger
751-
* than 1*1x1.
752-
* - For more info, see this guide:
753-
* [https://www.tensorflow.org/api_guides/python/nn#Convolution](
754-
* https://www.tensorflow.org/api_guides/python/nn#Convolution)
755677
* @param dimRoundingMode The rounding mode used when computing output
756678
* dimensions if pad is a number. If none is provided, it will not round
757679
* and error if the output is of fractional size.
@@ -760,10 +682,11 @@ function maxPool3d_(
760682
* default format "NDHWC", the data is stored in the order of: [batch,
761683
* depth, height, width, channels]. Only "NDHWC" is currently supported.
762684
*/
763-
function maxPool3dImpl_(
685+
/** @doc {heading: 'Operations', subheading: 'Convolution'} */
686+
function maxPool3d_(
764687
x: Tensor5D|TensorLike, filterSize: [number, number, number]|number,
765-
strides: [number, number, number]|number,
766-
dilations: [number, number, number]|number, pad: 'valid'|'same'|number,
688+
strides: [number, number, number]|number, pad: 'valid'|'same'|number,
689+
dilations: [number, number, number]|number,
767690
dimRoundingMode?: 'floor'|'round'|'ceil',
768691
dataFormat: 'NDHWC'|'NCDHW' = 'NDHWC'): Tensor5D {
769692
const $x = convertToTensor(x, 'x', 'maxPool3d');

0 commit comments

Comments
 (0)