You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now, only inference (forward pass) has been implemented for all Triton kernels.
To support training, backward pass should be implemented.
Each kernel is already wrapped in torch.autograd.Function so it will be just adding a method to an existing class and no refactoring should be needed.
Expected improvement in training are those of Flash attention:
2-4X faster training (just for the attention, linear layer and layernorm/rmsnorm should bring their own gains)
Support of very long sequences (up to 16K tokens) with a limited computation budget
Right now, only inference (forward pass) has been implemented for all Triton kernels.
To support training, backward pass should be implemented.
Each kernel is already wrapped in
torch.autograd.Function
so it will be just adding a method to an existing class and no refactoring should be needed.Expected improvement in training are those of Flash attention:
Below are pointers that can be used for the implementation and a list of our main modifications to the original fw implementation:
Training support will require adding to the bw pass of each kernel the modifications, we did if it makes sense (to have parity).
supersede #11
The text was updated successfully, but these errors were encountered: