We have tried using te.scan and te.compute to implement cumsum. But it seems that there is no way to use the same formula to adapt to all situations. Finally, we implement it with te.extern.
We have tried using te.scan and te.compute to implement cumsum. But it seems that there is no way to use the same formula to adapt to all situations. Finally, we implement it with te.extern.