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

DM-39146: Memory efficiency for rbTransiNetTask/Interface #17

Merged
merged 4 commits into from May 11, 2023

Conversation

NimSed
Copy link
Contributor

@NimSed NimSed commented May 11, 2023

  • Use batches in rbTransiNetInterface.
  • Test batches, rename test methods and classes.
  • Add minor logging to rbTransiNetTask

batches : `list` [`list` [`CutoutInputs`]]
List of batches of inputs.
"""
batches = [inputs[i:i + batchSize] for i in range(0, len(inputs), batchSize)]
Copy link

Choose a reason for hiding this comment

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

For even better memory efficiency you might make this a generator

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Good point. See if it looks better now.

@NimSed NimSed merged commit 2cfc252 into main May 11, 2023
1 check passed
@NimSed NimSed deleted the tickets/DM-39146 branch May 11, 2023 20:00
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.

None yet

2 participants