NVIDIA / TransformerEngine

A library for accelerating Transformer models on NVIDIA GPUs, including using 8-bit floating point (FP8) precision on Hopper and Ada GPUs, to provide better performance with lower memory utilization in both training and inference.
https://docs.nvidia.com/deeplearning/transformer-engine/user-guide/index.html
Apache License 2.0
1.85k stars 309 forks source link

Remove unwanted Memory Copies/Fix weight parameters #1034

Closed sanandaraj5597 closed 2 months ago

sanandaraj5597 commented 2 months ago

1) Made a fix to remove unwanted MemcpyDtoD kernels when CPU offloading is enabled.

2) When initializing the Parameter, we need to pass on the weight and the weight.requires_grad. So adding that.

3) Added the fixes in point#2 for grouped_linear module.

timmoon10 commented 2 months ago

/te-ci pytorch