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

Clear torch memory cache in tests #179

Merged

Conversation

GenevieveBuckley
Copy link
Collaborator

I've been running out of memory when running the test suite locally. If I clear the torch cache before the two worst memory hogs (the tiling tests) this helps the situation a lot.

I've been running out of memory when running the test suite locally. If I clear the torch cache before the two worst memory hogs (the tiling tests) this helps the situation a lot.
Copy link
Contributor

@constantinpape constantinpape left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense! These tests would need a lot of memory. This is not an issue on the CPU where memory management is easier, but will become a problem on small GPUs (and I assume on MPS as well). Your fix looks good. It currently fails here because util._get_device is not on dev yet, but will be once #176 is merged. I will then merge this one.

@constantinpape
Copy link
Contributor

The relevant functionality is now on dev so I will merge.

@constantinpape constantinpape merged commit a99a849 into computational-cell-analytics:dev Sep 7, 2023
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants