-
Notifications
You must be signed in to change notification settings - Fork 1
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
Add instructions for swapfile, and let Node use it #120
base: main
Are you sure you want to change the base?
Conversation
Damn it Windows. Probably worth using cross-env since I imagine the other envvars are broken as well? |
Signed-off-by: Jonathan Dahan <[email protected]> Co-Authored-By: Trammell Hudson <[email protected]>
@lewi0622 I noticed on your blog (cool!) that you were working around Out-of-Memory issues. Can you try this and see if it helps? |
I have a 5.1 megabyte file that reliably makes Saxi run out of memory when I plot all three layers. It handles plotting two layers fine. I guess I'm a little confused exactly what to do. So my RPi3 already has a swap file created (not my explicit doing). Do I need to make another one? And do I need to do anything to allow Node to use it? The below memory stats are when Saxi isn't running (when it is running, but not plotting, the used Mem goes up to 75M): |
My (imperfect) understanding is there are/were two problems with memory. First, RPi Zeros only have 512MB RAM and can benefit from a swapfile. Since your RPi3 (1) has more memory and (2) already have a swapfile, this is of no use. Second, this PR also uses a flag to give Node.js more memory than the default 512MB. See https://stackoverflow.com/a/62650303. Namely, |
I did try with With the attached file, even just running on the main branch, plotting two of the three layers is fine (approx. 14 hrs of plot time), but doing all three layers is too much (approx. 22 hrs of plot time) even with dedicating 3072 (3GB). Each layer of the file is of similar size/complexity. So it's hard to say for sure, but increasing the --max-old-space-size doesn't seem to be helping in this case? |
Damn. Well, it was worth a shot. :) In the coming weeks I'm bringing in a colleague to hack on this a bit more. Perhaps we can try your test file. |
Closes #118