/external/tensorflow/tensorflow/cc/gradients/ |
D | array_grad.cc | 42 const std::vector<Output>& grad_inputs, in PackGrad() argument 50 auto grad_op = Unstack(scope, grad_inputs[0], N, Unstack::Axis(axis)); in PackGrad() 59 const std::vector<Output>& grad_inputs, in UnpackGrad() argument 63 grad_outputs->push_back(Stack(scope, grad_inputs, Stack::Axis(axis))); in UnpackGrad() 69 const std::vector<Output>& grad_inputs, in IdentityGrad() argument 71 grad_outputs->push_back(Identity(scope, grad_inputs[0])); in IdentityGrad() 77 const std::vector<Output>& grad_inputs, in RefIdentityGrad() argument 79 grad_outputs->push_back(Identity(scope, grad_inputs[0])); in RefIdentityGrad() 85 const std::vector<Output>& grad_inputs, in QuantizeAndDequantizeGrad() argument 87 grad_outputs->push_back(Identity(scope, grad_inputs[0])); in QuantizeAndDequantizeGrad() [all …]
|
D | math_grad.cc | 56 const std::vector<Output>& grad_inputs, in AbsGrad() argument 59 grad_outputs->push_back(Mul(scope, grad_inputs[0], Sign(scope, op.input(0)))); in AbsGrad() 65 const std::vector<Output>& grad_inputs, in NegGrad() argument 68 grad_outputs->push_back(Neg(scope, grad_inputs[0])); in NegGrad() 74 const std::vector<Output>& grad_inputs, in InvGrad() argument 78 internal::ReciprocalGrad(scope, op.output(0), grad_inputs[0])); in InvGrad() 85 const std::vector<Output>& grad_inputs, in SquareGrad() argument 92 Mul(scope, grad_inputs[0], ConjugateHelper(scope, dydx))); in SquareGrad() 98 const std::vector<Output>& grad_inputs, in SqrtGrad() argument 102 internal::SqrtGrad(scope, op.output(0), grad_inputs[0])); in SqrtGrad() [all …]
|
D | nn_grad.cc | 28 const std::vector<Output>& grad_inputs, in SoftmaxGrad() argument 41 auto dyy = Mul(scope, grad_inputs[0], y); in SoftmaxGrad() 43 auto sub = Sub(scope, grad_inputs[0], sum); in SoftmaxGrad() 78 const std::vector<Output>& grad_inputs, in SoftmaxCrossEntropyWithLogitsGrad() argument 90 auto grad_loss = grad_inputs[0]; in SoftmaxCrossEntropyWithLogitsGrad() 91 auto grad_grad = grad_inputs[1]; in SoftmaxCrossEntropyWithLogitsGrad() 117 const std::vector<Output>& grad_inputs, in LogSoftmaxGrad() argument 120 auto sum = Sum(scope, grad_inputs[0], {1}, Sum::KeepDims(true)); in LogSoftmaxGrad() 122 auto dx = Sub(scope, grad_inputs[0], mul); in LogSoftmaxGrad() 129 const std::vector<Output>& grad_inputs, in ReluGradHelper() argument [all …]
|
D | image_grad.cc | 27 const std::vector<Output>& grad_inputs, in ResizeNearestNeighborGradHelper() argument 40 scope, grad_inputs[0], x_shape, in ResizeNearestNeighborGradHelper() 49 const std::vector<Output>& grad_inputs, in ResizeBilinearGradHelper() argument 58 scope, grad_inputs[0], op.input(0), in ResizeBilinearGradHelper() 67 const std::vector<Output>& grad_inputs, in ResizeBicubicGradHelper() argument 77 scope, grad_inputs[0], op.input(0), in ResizeBicubicGradHelper() 86 const std::vector<Output>& grad_inputs, in ScaleAndTranslateGradHelper() argument 94 scope, grad_inputs[0], op.input(0), op.input(2), op.input(3), in ScaleAndTranslateGradHelper() 107 const std::vector<Output>& grad_inputs, in CropAndResizeGradHelper() argument 115 scope, grad_inputs[0], op.input(1), op.input(2), image_shape, input_type, in CropAndResizeGradHelper() [all …]
|
D | data_flow_grad.cc | 45 const std::vector<Output>& grad_inputs, in DynamicPartitionGrad() argument 99 DynamicStitch(scope, partitioned_indices.outputs, grad_inputs); in DynamicPartitionGrad() 110 const std::vector<Output>& grad_inputs, in DynamicStitchGrad() argument 145 grad_outputs->push_back(Gather(scope, grad_inputs[0], index)); in DynamicStitchGrad()
|
D | grad_testutil.cc | 24 const std::vector<Output>& grad_inputs, in CallGradFunction() argument 29 TF_RETURN_IF_ERROR(grad_fn(scope, op, grad_inputs, grad_outputs)); in CallGradFunction()
|
D | manip_grad.cc | 26 const std::vector<Output>& grad_inputs, in RollGrad() argument 30 auto grad_op = Roll(scope, grad_inputs[0], Neg(scope, shift), axis); in RollGrad()
|
D | grad_testutil.h | 31 const std::vector<Output>& grad_inputs,
|
D | README.md | 17 const std::vector<Output>& grad_inputs,
|
/external/tensorflow/tensorflow/c/experimental/gradients/ |
D | math_grad.cc | 42 absl::Span<AbstractTensorHandle*> grad_inputs) override { in Compute() argument 46 grad_inputs[0] = grad_outputs[0]; in Compute() 47 grad_inputs[1] = grad_outputs[0]; in Compute() 49 grad_inputs[0]->Ref(); in Compute() 50 grad_inputs[1]->Ref(); in Compute() 63 absl::Span<AbstractTensorHandle*> grad_inputs) override { in Compute() argument 71 TF_RETURN_IF_ERROR(Mul(ctx, {conj_outputs[0], grad_outputs[0]}, grad_inputs, in Compute() 88 absl::Span<AbstractTensorHandle*> grad_inputs) override { in Compute() argument 91 absl::MakeSpan(grad_inputs), name.c_str())); in Compute() 114 absl::Span<AbstractTensorHandle*> grad_inputs) override { in Compute() argument [all …]
|
D | nn_grad.cc | 49 absl::Span<AbstractTensorHandle*> grad_inputs) override { in Compute() argument 56 ReluGrad(ctx, {upstream_grad, activations}, grad_inputs, name.c_str())); in Compute() 102 absl::Span<AbstractTensorHandle*> grad_inputs) override { in Compute() argument 106 grad_inputs.subspan(0, 1))); // upstream_grad * local softmax grad in Compute() 109 grad_inputs[1] = nullptr; in Compute() 126 absl::Span<AbstractTensorHandle*> grad_inputs) override { in Compute() argument 141 grad_inputs[0] = upstream_grad; in Compute() 142 grad_inputs[0]->Ref(); in Compute() 147 grad_inputs.subspan(1, 1), in Compute()
|
D | custom_gradient_test.cc | 49 absl::Span<AbstractTensorHandle*> grad_inputs) override { in Compute() argument 51 CHECK_EQ(grad_inputs.size(), 1); in Compute() 52 grad_inputs[0] = grad_outputs[0]; in Compute() 53 if (grad_inputs[0]) { in Compute() 54 grad_inputs[0]->Ref(); in Compute()
|
D | array_grad.cc | 26 absl::Span<AbstractTensorHandle*> grad_inputs) override { in Compute() argument 34 grad_inputs[i] = grad_input; in Compute()
|
D | not_differentiable.h | 27 absl::Span<AbstractTensorHandle*> grad_inputs) override;
|
/external/tensorflow/tensorflow/cc/framework/ |
D | gradients.cc | 55 const std::vector<Output>& grad_inputs, 81 const std::vector<Output>& grad_inputs, 144 const std::vector<Output>& grad_inputs, std::vector<Output>* grad_outputs) in SymbolicGradientBuilder() argument 149 grad_inputs_(grad_inputs), in SymbolicGradientBuilder() 382 const std::vector<Output>& grad_inputs, in CallGradFunction() argument 386 TF_RETURN_IF_ERROR(grad_fn(scope_, op, grad_inputs, grad_outputs)); in CallGradFunction() 561 const std::vector<Output>& grad_inputs, in AddSymbolicGradients() argument 564 inputs, grad_inputs, grad_outputs); in AddSymbolicGradients() 572 std::vector<Output> grad_inputs; in AddSymbolicGradients() local 573 grad_inputs.reserve(outputs.size()); in AddSymbolicGradients() [all …]
|
D | while_gradients.cc | 137 const std::vector<Output>& grad_inputs, in AddWhileGradientLoop() argument 141 DCHECK_EQ(grad_inputs.size(), while_ctx->body_outputs().size()); in AddWhileGradientLoop() 171 TF_RETURN_IF_ERROR(BuildWhileLoop(scope, grad_inputs, cond_fn, body_fn, in AddWhileGradientLoop() 180 const std::vector<Output>& grad_inputs, in AddWhileLoopGradient() argument 194 return AddWhileGradientLoop(while_ctx, grad_inputs, backprop_counter_cond, in AddWhileLoopGradient()
|
D | while_gradients.h | 35 const std::vector<Output>& grad_inputs,
|
D | gradients.h | 33 const std::vector<Output>& grad_inputs,
|
D | grad_op_registry.h | 31 const std::vector<Output>& grad_inputs,
|
/external/tensorflow/tensorflow/c/eager/ |
D | gradients.h | 59 absl::Span<AbstractTensorHandle*> grad_inputs) = 0;
|
/external/tensorflow/tensorflow/c/ |
D | c_api_test.cc | 1649 TF_Output grad_inputs[1]; in AddGradients() local 1653 grad_inputs[0] = TF_Output{grad_inputs_op, 0}; in AddGradients() 1655 ninputs, grad_inputs, s_, grad_outputs); in AddGradients()
|