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

Print memory usage #83

Merged
merged 2 commits into from
Jul 11, 2023
Merged

Conversation

vasdommes
Copy link
Collaborator

in debug mode:

  • sdpb: print MemAvailable, GB and MemUsed, GB (= MemTotal - MemAvailable) from /proc/meminfo at each timer start, e.g.:
0 run.objectives MemAvailable, GB: 62.6031
0 run.objectives MemUsed, GB: 188.866
  • sdp2input: print matrix sizes and RAM estimates, e.g.:
---------------------
Matrix sizes and RAM estimates:
---------------------
BigFloat, bytes: 156
P (primal objective), elements: 195368
P (primal objective), bytes: 30477408
N (dual objective), elements: 9437
N (dual objective), bytes: 1472172
B matrix (PxN), elements: 1843687816
B matrix (PxN), bytes: 287615299296
Q matrix (NxN), elements: 89056969
Q matrix (NxN), bytes: 13892887164
Bilinear bases, elements: 9045327
Bilinear bases, bytes: 1411071012
Bilinear pairing blocks, elements: 72157126
Bilinear pairing blocks, bytes: 11256511656
PSD blocks, elements: 18039573
PSD blocks, bytes: 2814173388
Schur (PxP block diagonal), elements: 121897852
Schur (PxP block diagonal), bytes: 19016064912
Total (no Q) = 2#(B) + 5#(PSD) + 2#(S) + 2#(Bilinear pairing), elements: 4165683453
Total (no Q) = 2#(B) + 5#(PSD) + 2#(S) + 2#(Bilinear pairing), bytes: 649846618668
Total RAM (no Q), GB: 605.217
Q, GB: 12.9388
NB: Q is copied over each core group, i.e. (nodes*procsPerNode/procGranularity) times
---------------------

Printed for rank=0 at timer start, example:

0 run.step.frobenius_product_symmetric  MemAvailable, GB: 216.604
0 run.step.frobenius_product_symmetric  MemUsed, GB: 34.8657
TODO: same for pvm2sdp

Related: davidsd#76 Print out info about the sdp at startup
@davidsd
Copy link
Owner

davidsd commented Jul 6, 2023

Looks good!

@vasdommes vasdommes merged commit a4ff5fb into davidsd:master Jul 11, 2023
@vasdommes vasdommes deleted the print-memory-usage branch July 11, 2023 22:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants