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

[BBPBGLIB-712] Estimate memory usage for synapse and connection #22

Merged
merged 6 commits into from
Aug 10, 2023

Conversation

st4rl3ss
Copy link
Contributor

@st4rl3ss st4rl3ss commented Aug 9, 2023

As detailed in BBPBGLIB-712, this MR aims to introduce memory estimation for synapses and relative connections.

A basic counter is introduced that tracks all the synapses that get instantiated on all the ranks. Then memory usage is estimated using a LUT containing the approximate memory estimate for each type of synapse. The values were calculated using the script synstat.py included in the _benchmark folder.

Based on the counter and the memory estimate, an approximated figure for memory utilization can be reported to the user.

ferdonline and others added 3 commits August 8, 2023 16:39
 - Enabled Target methods to return raw gids
 - Accumulate counts in Counter() object (from collections)
 - MPI gather all counts, merge them and display
…pses

- Added script used to measure synapse memory usage
- Dry run now calculates estimate of memory usage of synapses
- Fix typos
neurodamus/utils/memory.py Outdated Show resolved Hide resolved
neurodamus/utils/memory.py Outdated Show resolved Hide resolved
@bbpbuildbot

This comment has been minimized.

@bbpbuildbot

This comment has been minimized.

@st4rl3ss st4rl3ss changed the title Draft: [BBPBGLIB-712] Estimate memory usage for synapse and connection [BBPBGLIB-712] Estimate memory usage for synapse and connection Aug 10, 2023
@st4rl3ss st4rl3ss marked this pull request as ready for review August 10, 2023 09:14
@st4rl3ss st4rl3ss marked this pull request as draft August 10, 2023 09:36
@bbpbuildbot

This comment has been minimized.

@ferdonline
Copy link
Collaborator

Nitpick: In the benchmark script we could work in Kilobytes to avoid multiplying by 1024 bellow.
Apart from it LGTM.
IMO the only missing part here is that we output results to maybe a json file and not simply print stuff on the screen. But since that needs to be done for cell estimation maybe we can work that in a separate PR

@st4rl3ss
Copy link
Contributor Author

Thanks for the review @ferdonline . I think also we can integrate the json export into a different MR.
I will switch this MR to ready for review.

@st4rl3ss st4rl3ss marked this pull request as ready for review August 10, 2023 13:21
@bbpbuildbot
Copy link

Logfiles from GitLab pipeline #143299 (:white_check_mark:) have been uploaded here!

Status and direct links:

@st4rl3ss st4rl3ss merged commit 1cd09df into main Aug 10, 2023
3 checks passed
@st4rl3ss st4rl3ss deleted the BBPBGLIB-712/count-synapses-bytype branch August 10, 2023 13:57
WeinaJi pushed a commit that referenced this pull request Oct 14, 2024
As detailed in
[BBPBGLIB-712](https://bbpteam.epfl.ch/project/issues/browse/BBPBGLIB-712),
this MR aims to introduce memory estimation for synapses and relative
connections.

A basic counter is introduced that tracks all the synapses that get
instantiated on all the ranks. Then memory usage is estimated using a
LUT containing the approximate memory estimate for each type of synapse.
The values were calculated using the script `synstat.py` included in the
`_benchmarks` folder.

Based on the counter and the memory estimate, an approximated figure for
memory utilization can be reported to the user.

---------

Co-authored-by: Fernando Pereira <[email protected]>
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.

3 participants