-
Notifications
You must be signed in to change notification settings - Fork 4
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 preferred max heap size setting to settings, and autodetect a good value by default #274
Comments
As an aside: it's unfortunate that the backing ImgLib2 implementation for Just so that it's logged somewhere on GitHub, here is the OOM stack trace: OutOfMemoryError
|
The JVM's default max heap varies by OpenJDK version, but is typically rather small compared to the size of memory on a computer. For example, I ran out of memory trying to perform a
filter.gauss
op on a 1G dataset. After increasing my max heap to 16G by adding-Xmx16g
to the additional JVM args area, I was able to perform the operation.But users will not know to do this, especially Python users who don't know Java. Fiji tries to be kind and autoset the max heap to 3/4 of your physical RAM by default, and I think napari-imagej should do the same. I also think the settings dialog should expose an option directly to control max memory, rather than instructing users in the documentation (which many people don't read, of course) to add the arcane
-Xmx...
flag to extra JVM args.Detecting physical memory size in Python is simple with
psutil
:The text was updated successfully, but these errors were encountered: