MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / ExpandDimsGrad

Function ExpandDimsGrad

tensorflow/cc/gradients/array_grad.cc:227–234  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

225REGISTER_GRADIENT_OP("Reshape", ReshapeGrad);
226
227Status ExpandDimsGrad(const Scope& scope, const Operation& op,
228 const std::vector<Output>& grad_inputs,
229 std::vector<Output>* grad_outputs) {
230 auto input_shape = Shape(scope, op.input(0));
231 grad_outputs->push_back(Reshape(scope, grad_inputs[0], input_shape));
232 grad_outputs->push_back(NoGradient());
233 return scope.status();
234}
235REGISTER_GRADIENT_OP("ExpandDims", ExpandDimsGrad);
236
237Status SqueezeGrad(const Scope& scope, const Operation& op,

Callers

nothing calls this directly

Calls 6

NoGradientFunction · 0.85
ShapeClass · 0.50
ReshapeFunction · 0.50
inputMethod · 0.45
push_backMethod · 0.45
statusMethod · 0.45

Tested by

no test coverage detected