(self, y, grad, autograd_op)
| 978 | return additional_sum_ops, grad_map |
| 979 | |
| 980 | def _AppendAutoGradGenerator(self, y, grad, autograd_op): |
| 981 | # Gradient here is not sparse as it was generated by |
| 982 | # a ConstantFill operator. Autogeneration for sparse gradients is |
| 983 | # not supported |
| 984 | generator = GradGenMeta( |
| 985 | autograd_op, 0 if autograd_op else None, str(grad), |
| 986 | autograd_op.device_option) |
| 987 | |
| 988 | self.gradient_generators[str(y)][self.frontier[str(y)]].append( |
| 989 | generator) |
| 990 | |
| 991 | AUTOGEN_GRAD_SUFFIX = "_autogen_grad" |
| 992 |
no test coverage detected