Fix bugs encountered by RNN (#4719)
* Accumulate partial grad to acc tensor promptly. * Accumulate partial grad to acc tensor promptly. * Fix stateful grad function to be stateless. * Fix Co-authored-by: hjchen2 <hjchen2>
Showing
- oneflow/core/autograd/autograd_engine.cpp 4 additions, 4 deletionsoneflow/core/autograd/autograd_engine.cpp
- oneflow/core/autograd/gradient_funcs/default.cpp 32 additions, 26 deletionsoneflow/core/autograd/gradient_funcs/default.cpp
- oneflow/core/framework/tensor_arg.cpp 11 additions, 21 deletionsoneflow/core/framework/tensor_arg.cpp
- oneflow/core/framework/tensor_arg.h 4 additions, 3 deletionsoneflow/core/framework/tensor_arg.h
Please register or sign in to comment