Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Should truncated_bptt_steps take effect during validation phase? #6539

Closed
colllin opened this issue Mar 15, 2021 · 1 comment
Closed

Should truncated_bptt_steps take effect during validation phase? #6539

colllin opened this issue Mar 15, 2021 · 1 comment
Labels
bug Something isn't working help wanted Open to be worked on priority: 1 Medium priority task

Comments

@colllin
Copy link

colllin commented Mar 15, 2021

🐛 Bug

It appears that the Trainer flag truncated_bptt_steps doesn’t affect the validation phase. Should it? The problem I’m running into is that I need truncated_bptt_steps to virtually increase the length of the sequence I can fit into my GPU memory, but this purpose is defeated when the validation step doesn’t also make use of truncated_bptt_steps — in this case my memory is limited by my validation step, which attempts to process the full sequence in-memory.

Is there a reason why validation step shouldn’t also make use of the truncated_bptt_steps flag? Or is this just not finished yet? I could probably manage to adapt the evaluation_loop code to copy the training_loop code regarding truncated_bptt_steps. Would this be an acceptable addition?

See also: #6483

Please reproduce using the BoringModel

https://colab.research.google.com/drive/1JYAVdMy-UPg0Rzwpo3T9A-FmwrOdi_aR?usp=sharing

To Reproduce

Expected behavior

I expected the validation loop to also split the batch along the time dimension according to truncated_bptt_steps.

@colllin colllin added bug Something isn't working help wanted Open to be worked on labels Mar 15, 2021
@Lightning-AI Lightning-AI deleted a comment from edenlightning Mar 23, 2021
@edenlightning edenlightning added the priority: 1 Medium priority task label Jul 1, 2021
@RomeroBarata
Copy link

I'm facing the same issue. Any updates on that?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working help wanted Open to be worked on priority: 1 Medium priority task
Projects
None yet
Development

No branches or pull requests

5 participants