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
I usually refer to https://discuss.pytorch.org/t/about-torch-cuda-empty-cache/34232/2 when I consider emptying the cache. In my understanding, when you leave the function, the internal variables no longer exist so the tensor stop being reference and the underlying memory is freed.
Shouldn't we
torch.cuda.empty_cache()
after computing thelogprobs
in [here] (trl/trl/trainer/grpo_trainer.py
Line 430 in 801582e
The text was updated successfully, but these errors were encountered: