uproot's memory usage #1328
pfackeldey
started this conversation in
General
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
This post is an update on uproot's memory usage
The recent PR #1305 improved uproot's memory usage significantly. Before, memory was accumulating where it shouldn't, a comparison is shown in #1305 (comment).
The memory usage can be measured with the following setup:
Requirements
uproot
(including PR perf: removing output arrays from reference cycles so they don't have to wait for GC #1305)memray
absl-py
(for CLI args)Script
How to run (with GC disabled)
The resulting flame graph (with GC disabled) is as follows for each loop kind:
![flamegraph](https://private-user-images.githubusercontent.com/18463582/383355444-6e9ca7b0-99fc-4e57-8f42-4c1bae8409d4.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkxOTA0OTIsIm5iZiI6MTczOTE5MDE5MiwicGF0aCI6Ii8xODQ2MzU4Mi8zODMzNTU0NDQtNmU5Y2E3YjAtOTlmYy00ZTU3LThmNDItNGMxYmFlODQwOWQ0LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTAlMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjEwVDEyMjMxMlomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTM2M2ZhMjk1MzdhMjMyMWJhYmNmZTdiYTI5N2M0YmI0M2UzZDBjZDA4ZGU0YjY2NDEzYjVjNzE0ZDJmNGZjYjQmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.8Xt_ruinKQg3jYRQUhZdOINUbg5-8qn-9oU5mWuPilE)
Uproot's memory consumption is stable (not growing) and follows an expected sawtooth structure 🎉
Beta Was this translation helpful? Give feedback.
All reactions