Home
last modified time | relevance | path

Searched refs:data_format_ (Results 1 – 25 of 30) sorted by relevance

12

/external/tensorflow/tensorflow/core/kernels/
Dmkl_conv_ops.h56 TensorFormat data_format_; variable
66 data_format_(fm) {} in context_()
76 int stride_rows = GetTensorDim(strides_, data_format_, 'H'); in GetStridesInMklOrder()
77 int stride_cols = GetTensorDim(strides_, data_format_, 'W'); in GetStridesInMklOrder()
80 int stride_planes = GetTensorDim(strides_, data_format_, '0'); in GetStridesInMklOrder()
81 int stride_rows = GetTensorDim(strides_, data_format_, '1'); in GetStridesInMklOrder()
82 int stride_cols = GetTensorDim(strides_, data_format_, '2'); in GetStridesInMklOrder()
93 int dilations_rows = GetTensorDim(dilations_, data_format_, 'H'); in GetDilationsInMklOrder()
94 int dilations_cols = GetTensorDim(dilations_, data_format_, 'W'); in GetDilationsInMklOrder()
97 int dilations_planes = GetTensorDim(dilations_, data_format_, '0'); in GetDilationsInMklOrder()
[all …]
Dpooling_ops_3d.cc136 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in Pooling3DOp()
140 context, data_format_ == FORMAT_NHWC, in Pooling3DOp()
155 (GetTensorDim(ksize_, data_format_, 'N') == 1 && in Pooling3DOp()
156 GetTensorDim(stride_, data_format_, 'N') == 1), in Pooling3DOp()
160 (GetTensorDim(ksize_, data_format_, 'C') == 1 && in Pooling3DOp()
161 GetTensorDim(stride_, data_format_, 'C') == 1), in Pooling3DOp()
171 const int64 depth = GetTensorDim(tensor_in, data_format_, 'C'); in Compute()
172 const int64 in_batch = GetTensorDim(tensor_in, data_format_, 'N'); in Compute()
176 {GetTensorDim(tensor_in, data_format_, '2'), in Compute()
177 GetTensorDim(tensor_in, data_format_, '1'), in Compute()
[all …]
Dconv_grad_ops_3d.cc169 data_format_(FORMAT_NHWC), in Conv3DBackpropInputOp()
175 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in Conv3DBackpropInputOp()
178 context, data_format_ == FORMAT_NHWC, in Conv3DBackpropInputOp()
188 (GetTensorDim(dilation_, data_format_, 'C') == 1 && in Conv3DBackpropInputOp()
189 GetTensorDim(dilation_, data_format_, 'N') == 1), in Conv3DBackpropInputOp()
196 (GetTensorDim(dilation_, data_format_, '0') == 1 && in Conv3DBackpropInputOp()
197 GetTensorDim(dilation_, data_format_, '1') == 1 && in Conv3DBackpropInputOp()
198 GetTensorDim(dilation_, data_format_, '2') == 1), in Conv3DBackpropInputOp()
209 (GetTensorDim(stride_, data_format_, 'C') == 1 && in Conv3DBackpropInputOp()
210 GetTensorDim(stride_, data_format_, 'N') == 1), in Conv3DBackpropInputOp()
[all …]
Dbias_op.cc93 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in BiasOp()
96 data_format_ = FORMAT_NHWC; in BiasOp()
113 if (data_format_ == FORMAT_NCHW) { in Compute()
134 if (data_format_ == FORMAT_NCHW) { in Compute()
136 GetBiasValueDims(input, data_format_, &batch, &height, &width, &depth, in Compute()
203 TensorFormat data_format_; member in tensorflow::BiasOp
238 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in BiasGradOp()
241 data_format_ = FORMAT_NHWC; in BiasGradOp()
260 GetBiasValueDims(output_backprop, data_format_, &batch, &height, &width, in Compute()
273 if (data_format_ == FORMAT_NCHW) { in Compute()
[all …]
Davgpooling_op.cc55 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in AvgPoolingOp()
58 context, data_format_ == FORMAT_NHWC, in AvgPoolingOp()
79 padding_, data_format_, tensor_in.shape()}; in Compute()
102 TensorFormat data_format_; member in tensorflow::AvgPoolingOp
123 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in AvgPoolingOp()
134 const int32 ksize_n = GetTensorDim(ksize_, data_format_, 'N'); in AvgPoolingOp()
135 const int32 stride_n = GetTensorDim(stride_, data_format_, 'N'); in AvgPoolingOp()
144 padding_, data_format_, tensor_in.shape()}; in Compute()
158 if (data_format_ == FORMAT_NCHW) { in Compute()
160 stride_, padding_, data_format_, tensor_in, in Compute()
[all …]
Dconv_ops_3d.cc79 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in Conv3DOp()
87 (GetTensorDim(stride_, data_format_, 'N') == 1 && in Conv3DOp()
88 GetTensorDim(stride_, data_format_, 'C') == 1), in Conv3DOp()
93 (GetTensorDim(stride_, data_format_, '0') > 0 && in Conv3DOp()
94 GetTensorDim(stride_, data_format_, '1') > 0 && in Conv3DOp()
95 GetTensorDim(stride_, data_format_, '2') > 0), in Conv3DOp()
102 (GetTensorDim(dilation_, data_format_, 'N') == 1 && in Conv3DOp()
103 GetTensorDim(dilation_, data_format_, 'C') == 1), in Conv3DOp()
109 (GetTensorDim(dilation_, data_format_, '0') > 0 && in Conv3DOp()
110 GetTensorDim(dilation_, data_format_, '1') > 0 && in Conv3DOp()
[all …]
Ddepthtospace_op.cc49 OP_REQUIRES(context, FormatFromString(data_format_str, &data_format_), in DepthToSpaceOp()
59 context, data_format_ == FORMAT_NHWC, in DepthToSpaceOp()
71 OP_REQUIRES(context, (is_int8x4 == (data_format_ == FORMAT_NCHW_VECT_C)), in Compute()
83 input.dim_size(GetTensorDimIndex<kNumSpatialDims>(data_format_, 'N')); in Compute()
85 input.dim_size(GetTensorDimIndex<kNumSpatialDims>(data_format_, 'H')); in Compute()
87 input.dim_size(GetTensorDimIndex<kNumSpatialDims>(data_format_, 'W')); in Compute()
89 input.dim_size(GetTensorDimIndex<kNumSpatialDims>(data_format_, 'C')) * in Compute()
109 ShapeFromFormat(data_format_, batch_size, output_height, in Compute()
124 } else if (data_format_ == FORMAT_NCHW) { in Compute()
143 TensorFormat data_format_; member in tensorflow::DepthToSpaceOp
Dspacetodepth_op.cc49 OP_REQUIRES(context, FormatFromString(data_format_str, &data_format_), in SpaceToDepthOp()
59 context, data_format_ == FORMAT_NHWC, in SpaceToDepthOp()
71 OP_REQUIRES(context, (is_int8x4 == (data_format_ == FORMAT_NCHW_VECT_C)), in Compute()
83 input.dim_size(GetTensorDimIndex<kNumSpatialDims>(data_format_, 'N')); in Compute()
85 input.dim_size(GetTensorDimIndex<kNumSpatialDims>(data_format_, 'H')); in Compute()
87 input.dim_size(GetTensorDimIndex<kNumSpatialDims>(data_format_, 'W')); in Compute()
89 input.dim_size(GetTensorDimIndex<kNumSpatialDims>(data_format_, 'C')) * in Compute()
110 ShapeFromFormat(data_format_, batch_size, output_height, in Compute()
126 } else if (data_format_ == FORMAT_NCHW) { in Compute()
145 TensorFormat data_format_; member in tensorflow::SpaceToDepthOp
Dmaxpooling_op.cc217 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in MaxPoolingGradOp()
220 context, data_format_ == FORMAT_NHWC, in MaxPoolingGradOp()
317 TensorFormat data_format_; member in tensorflow::MaxPoolingGradOp
354 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in MaxPoolingGradOp()
365 const int32 ksize_n = GetTensorDim(ksize_, data_format_, 'N'); in MaxPoolingGradOp()
366 const int32 stride_n = GetTensorDim(stride_, data_format_, 'N'); in MaxPoolingGradOp()
413 const int32 ksize_n = GetTensorDim(ksize, data_format_, 'N'); in Compute()
414 const int32 stride_n = GetTensorDim(stride, data_format_, 'N'); in Compute()
421 ksize, stride, padding_, data_format_, in Compute()
425 CHECK(data_format_ == FORMAT_NHWC) in Compute()
[all …]
Dmkl_conv_grad_bias_ops.cc59 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in MklConv2DCustomBackpropBiasOp()
82 } else if (data_format_ == FORMAT_NHWC || data_format_ == FORMAT_NCHW) { in Compute()
83 mkl_context.c_size = GetTensorDim(input, data_format_, 'C'); in Compute()
109 mkl_context.in_sizes[MklDims::W] = GetTensorDim(input, data_format_, 'W'); in Compute()
110 mkl_context.in_sizes[MklDims::H] = GetTensorDim(input, data_format_, 'H'); in Compute()
111 mkl_context.in_sizes[MklDims::C] = GetTensorDim(input, data_format_, 'C'); in Compute()
112 mkl_context.in_sizes[MklDims::N] = GetTensorDim(input, data_format_, 'N'); in Compute()
113 GetStridesFromSizes(data_format_, mkl_context.in_strides, in Compute()
254 TensorFormat data_format_; member in tensorflow::MklConv2DCustomBackpropBiasOp
Dconv_ops_using_gemm.cc436 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in Conv2DUsingGemmOp()
438 OP_REQUIRES(context, data_format_ == FORMAT_NHWC, in Conv2DUsingGemmOp()
444 const int64 stride_n = GetTensorDim(strides_, data_format_, 'N'); in Conv2DUsingGemmOp()
445 const int64 stride_c = GetTensorDim(strides_, data_format_, 'C'); in Conv2DUsingGemmOp()
479 const int64 in_depth = GetTensorDim(input, data_format_, 'C'); in Compute()
490 const int64 input_rows_raw = GetTensorDim(input, data_format_, 'H'); in Compute()
500 const int64 input_cols_raw = GetTensorDim(input, data_format_, 'W'); in Compute()
509 const int64 batch_raw = GetTensorDim(input, data_format_, 'N'); in Compute()
517 const int stride_rows = GetTensorDim(strides_, data_format_, 'H'); in Compute()
518 const int stride_cols = GetTensorDim(strides_, data_format_, 'W'); in Compute()
[all …]
Ddepthwise_conv_op.cc271 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in DepthwiseConv2dNativeOp()
277 stride_ = GetTensorDim(strides_, data_format_, 'H'); in DepthwiseConv2dNativeOp()
278 const int64 stride_w = GetTensorDim(strides_, data_format_, 'W'); in DepthwiseConv2dNativeOp()
279 const int64 stride_n = GetTensorDim(strides_, data_format_, 'N'); in DepthwiseConv2dNativeOp()
280 const int64 stride_c = GetTensorDim(strides_, data_format_, 'C'); in DepthwiseConv2dNativeOp()
317 const int64 in_depth = GetTensorDim(input, data_format_, 'C'); in Compute()
329 const int64 input_rows_raw = GetTensorDim(input, data_format_, 'H'); in Compute()
337 const int64 input_cols_raw = GetTensorDim(input, data_format_, 'W'); in Compute()
356 ShapeFromFormat(data_format_, batch, out_rows, out_cols, out_depth); in Compute()
408 data_format_); in Compute()
[all …]
Dconv_grad_filter_ops.cc194 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in Conv2DCustomBackpropFilterOp()
196 OP_REQUIRES(context, data_format_ == FORMAT_NHWC, in Conv2DCustomBackpropFilterOp()
219 /*num_dims=*/4, data_format_)); in Conv2DCustomBackpropFilterOp()
254 strides_, padding_, data_format_, &dims)); in Compute()
289 data_format_)) { in Compute()
405 TensorFormat data_format_; member in tensorflow::Conv2DCustomBackpropFilterOp
450 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in Conv2DSlowBackpropFilterOp()
453 int stride_n = GetTensorDim(strides_, data_format_, 'N'); in Conv2DSlowBackpropFilterOp()
454 int stride_c = GetTensorDim(strides_, data_format_, 'C'); in Conv2DSlowBackpropFilterOp()
455 int stride_h = GetTensorDim(strides_, data_format_, 'H'); in Conv2DSlowBackpropFilterOp()
[all …]
Dconv_grad_input_ops.cc272 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in Conv2DCustomBackpropInputOp()
274 OP_REQUIRES(context, data_format_ == FORMAT_NHWC, in Conv2DCustomBackpropInputOp()
310 /*num_dims=*/4, data_format_)); in Conv2DCustomBackpropInputOp()
331 strides_, padding_, data_format_, &dims)); in Compute()
370 data_format_)) { in Compute()
539 TensorFormat data_format_; member in tensorflow::Conv2DCustomBackpropInputOp
584 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in Conv2DSlowBackpropInputOp()
590 int stride_n = GetTensorDim(strides_, data_format_, 'N'); in Conv2DSlowBackpropInputOp()
591 int stride_c = GetTensorDim(strides_, data_format_, 'C'); in Conv2DSlowBackpropInputOp()
592 int stride_h = GetTensorDim(strides_, data_format_, 'H'); in Conv2DSlowBackpropInputOp()
[all …]
Ddepthwise_conv_grad_op.cc70 const int64 input_rows_raw = GetTensorDim(input_shape, data_format_, 'H'); \
76 const int64 input_cols_raw = GetTensorDim(input_shape, data_format_, 'W'); \
85 GetTensorDim(out_backprop.shape(), data_format_, 'H'); \
92 GetTensorDim(out_backprop.shape(), data_format_, 'W'); \
98 const int64 in_depth = GetTensorDim(input_shape, data_format_, 'C'); \
104 GetTensorDim(out_backprop.shape(), data_format_, 'C'); \
548 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in DepthwiseConv2dNativeBackpropInputOp()
551 stride_ = GetTensorDim(strides_, data_format_, 'H'); in DepthwiseConv2dNativeBackpropInputOp()
552 const int64 stride_w = GetTensorDim(strides_, data_format_, 'W'); in DepthwiseConv2dNativeBackpropInputOp()
553 const int64 stride_n = GetTensorDim(strides_, data_format_, 'N'); in DepthwiseConv2dNativeBackpropInputOp()
[all …]
Dmkl_conv_ops.cc425 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in MklConvOp()
431 const int64 stride_n = GetTensorDim(strides_, data_format_, 'N'); in MklConvOp()
432 const int64 stride_c = GetTensorDim(strides_, data_format_, 'C'); in MklConvOp()
478 : GetTensorDim(input, data_format_, 'C'); in Compute()
490 : GetTensorDim(input, data_format_, 'H'); in Compute()
502 : GetTensorDim(input, data_format_, 'W'); in Compute()
513 : GetTensorDim(input, data_format_, 'N'); in Compute()
522 const int stride_rows = GetTensorDim(strides_, data_format_, 'H'); in Compute()
523 const int stride_cols = GetTensorDim(strides_, data_format_, 'W'); in Compute()
533 ShapeFromFormat(data_format_, batch, out_rows, out_cols, out_depth); in Compute()
[all …]
Dmkl_avgpooling_op.cc51 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in MklAvgPoolingOp()
81 pool_params.Init(context, ksize_, stride_, padding_, data_format_, in Compute()
84 pool_params.Init(context, ksize_, stride_, padding_, data_format_, in Compute()
89 ExtractMklOpParams(context, data_format_, pool_params, &mkl_context.params); in Compute()
131 mkl_out_shape.SetTfDimOrder(mkl_context.params.in_dim, data_format_); in Compute()
214 TensorFormat data_format_; member in tensorflow::MklAvgPoolingOp
227 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in MklAvgPoolingGradOp()
258 pool_params.Init(context, ksize_, stride_, padding_, data_format_, in Compute()
267 ExtractMklOpParams(context, data_format_, pool_params, &mkl_context.params); in Compute()
322 mkl_out_shape.SetTfDimOrder(mkl_context.params.in_dim, data_format_); in Compute()
[all …]
Dpooling_ops_common.h85 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in MaxPoolingOp()
88 context, data_format_ == FORMAT_NHWC, in MaxPoolingOp()
93 data_format_ = FORMAT_NHWC; in MaxPoolingOp()
261 TensorFormat data_format_; variable
295 OP_REQUIRES(context, FormatFromString(data_format, &data_format_),
299 data_format_ == FORMAT_NHWC || data_format_ == FORMAT_NCHW_VECT_C,
304 data_format_ = FORMAT_NHWC;
351 padding_, data_format_, tensor_in.shape()};
508 TensorFormat data_format_;
Dmkl_maxpooling_op.cc53 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in MklMaxPoolingOp()
86 pool_params.Init(context, ksize_, stride_, padding_, data_format_, in Compute()
93 pool_params.Init(context, ksize_, stride_, padding_, data_format_, in Compute()
99 ExtractMklOpParams(context, data_format_, pool_params, &mkl_context.params); in Compute()
112 mkl_out_shape.SetTfDimOrder(mkl_context.params.in_dim, data_format_); in Compute()
194 TensorFormat data_format_; member in tensorflow::MklMaxPoolingOp
212 OP_REQUIRES(context, FormatFromString(data_format, &data_format_), in MklMaxPoolingGradOp()
253 pool_params.Init(context, ksize_, stride_, padding_, data_format_, in Compute()
260 pool_params.Init(context, ksize_, stride_, padding_, data_format_, in Compute()
265 ExtractMklOpParams(context, data_format_, pool_params, &mkl_context.params); in Compute()
[all …]
/external/tensorflow/tensorflow/compiler/tf2xla/kernels/
Dbias_ops.cc34 OP_REQUIRES(ctx, FormatFromString(data_format, &data_format_), in BiasOp()
37 data_format_ = FORMAT_NHWC; in BiasOp()
53 int feature_dim = (data_format_ == FORMAT_NHWC) in Compile()
72 TensorFormat data_format_; member in tensorflow::__anonc660738f0111::BiasOp
83 OP_REQUIRES(ctx, FormatFromString(data_format, &data_format_), in BiasAddGradOp()
86 data_format_ = FORMAT_NHWC; in BiasAddGradOp()
98 int feature_dim = (data_format_ == FORMAT_NHWC) in Compile()
122 TensorFormat data_format_; member in tensorflow::__anonc660738f0111::BiasAddGradOp
Ddepthtospace_op.cc31 OP_REQUIRES(ctx, FormatFromString(data_format_str, &data_format_), in DepthToSpaceOp()
43 TensorFormat data_format = data_format_; in Compile()
55 ToString(data_format_))); in Compile()
170 if (data_format != data_format_) { in Compile()
171 DCHECK(data_format == FORMAT_NCHW && data_format_ == FORMAT_NCHW_VECT_C); in Compile()
181 TensorFormat data_format_; member in tensorflow::__anon2845a7410111::DepthToSpaceOp
Dspacetodepth_op.cc31 OP_REQUIRES(ctx, FormatFromString(data_format_str, &data_format_), in SpaceToDepthOp()
43 TensorFormat data_format = data_format_; in Compile()
55 ToString(data_format_))); in Compile()
174 if (data_format != data_format_) { in Compile()
175 DCHECK(data_format == FORMAT_NCHW && data_format_ == FORMAT_NCHW_VECT_C); in Compile()
185 TensorFormat data_format_; member in tensorflow::__anon9807cb610111::SpaceToDepthOp
Dbatch_norm_op.cc37 ctx, FormatFromString(data_format_str, &data_format_), in FusedBatchNormOp()
54 GetTensorFeatureDimIndex(input_shape.dims(), data_format_); in Compile()
104 TensorFormat data_format_; member in tensorflow::__anonf18b77da0111::FusedBatchNormOp
120 ctx, FormatFromString(data_format_str, &data_format_), in FusedBatchNormGradOp()
143 GetTensorFeatureDimIndex(input_dims, data_format_); in Compile()
218 TensorFormat data_format_; member in tensorflow::__anonf18b77da0111::FusedBatchNormGradOp
Dpooling_ops.cc128 TensorFormat data_format_ = FORMAT_NHWC; member in tensorflow::__anon05e5a9280111::PoolingOp
157 OP_REQUIRES(ctx, FormatFromString(data_format_str, &data_format_), in MaxPoolOp()
178 XlaTensorFormat(data_format_, input_shape.dims() - 2)); in Compile()
210 OP_REQUIRES(ctx, FormatFromString(data_format_str, &data_format_), in AvgPoolOp()
230 XlaTensorFormat(data_format_, input_shape.dims() - 2); in Compile()
349 TensorFormat data_format_ = FORMAT_NHWC; member in tensorflow::__anon05e5a9280111::MaxPoolGradOp
358 OP_REQUIRES(ctx, FormatFromString(data_format, &data_format_), in MaxPool2DGradOp()
397 OP_REQUIRES(ctx, FormatFromString(data_format, &data_format_), in AvgPoolGradOp()
430 XlaTensorFormat(data_format_, gradients_shape.dims() - 2); in Compile()
451 TensorFormat data_format_ = FORMAT_NHWC; member in tensorflow::__anon05e5a9280111::AvgPoolGradOp
[all …]
/external/tensorflow/tensorflow/contrib/fused_conv/kernels/
Dfused_conv2d_bias_activation_op.cc101 OP_REQUIRES(context, FormatFromString(data_format_str, &data_format_), in FusedConv2DBiasActivationOp()
115 stride_rows_ = GetTensorDim(strides, data_format_, 'H'); in FusedConv2DBiasActivationOp()
116 stride_cols_ = GetTensorDim(strides, data_format_, 'W'); in FusedConv2DBiasActivationOp()
119 (GetTensorDim(strides, data_format_, 'N') == 1 && in FusedConv2DBiasActivationOp()
120 GetTensorDim(strides, data_format_, 'C') == 1), in FusedConv2DBiasActivationOp()
130 OP_REQUIRES(context, (is_int8x4 == (data_format_ == FORMAT_NCHW_VECT_C)), in FusedConv2DBiasActivationOp()
207 const int32 batch_size = GetTensorDim(conv_input, data_format_, 'N'); in Compute()
208 const int32 conv_input_rows = GetTensorDim(conv_input, data_format_, 'H'); in Compute()
209 const int32 conv_input_cols = GetTensorDim(conv_input, data_format_, 'W'); in Compute()
220 data_format_, batch_size, output_rows, output_cols, output_depth); in Compute()
[all …]

12