Error of saving images while using Trainable Weka Segmentation

plugin
fiji
segmentation
Tags: #<Tag:0x00007fd542817d00> #<Tag:0x00007fd542817b98> #<Tag:0x00007fd542817a30>

#1

I came across a strange problem while using Trainable Weka Segmentation. I tried applying the classifier to a series of images but I could only save some of the images… Below was the error I got… Could someone tell me how to resolve this issue urgently? Thank you!!!

Exception in thread "Thread-12" Exception in thread "Thread-15" Exception in thread "Thread-14" java.lang.OutOfMemoryError: Java heap space
	trainableSegmentation.FeatureStack.createInstance(FeatureStack.java:3254)
	trainableSegmentation.FeatureStack.createInstances(FeatureStack.java:2283)
	trainableSegmentation.WekaSegmentation$1ApplyClassifierThread.run(WekaSegmentation.java:4773)

	at trainableSegmentation.FeatureStack.createInstance(FeatureStack.java:3254)
	at trainableSegmentation.FeatureStack.createInstances(FeatureStack.java:2283)
	at trainableSegmentation.WekaSegmentation$1ApplyClassifierThread.run(WekaSegmentation.java:4773)
java.lang.OutOfMemoryError: Java heap space
	trainableSegmentation.FeatureStack.createInstance(FeatureStack.java:3254)
	trainableSegmentation.FeatureStack.createInstances(FeatureStack.java:2283)
	trainableSegmentation.WekaSegmentation$1ApplyClassifierThread.run(WekaSegmentation.java:4773)

Exception in thread "Thread-10" 	at trainableSegmentation.FeatureStack.createInstance(FeatureStack.java:3254)
	at trainableSegmentation.FeatureStack.createInstances(FeatureStack.java:2283)
	at trainableSegmentation.WekaSegmentation$1ApplyClassifierThread.run(WekaSegmentation.java:4773)
java.lang.OutOfMemoryError: Java heap space
	trainableSegmentation.FeatureStack.createInstance(FeatureStack.java:3254)
	trainableSegmentation.FeatureStack.createInstances(FeatureStack.java:2283)
	trainableSegmentation.WekaSegmentation$1ApplyClassifierThread.run(WekaSegmentation.java:4773)

Exception in thread "Thread-11" 	at trainableSegmentation.FeatureStack.createInstance(FeatureStack.java:3254)
	at trainableSegmentation.FeatureStack.createInstances(FeatureStack.java:2283)
	at trainableSegmentation.WekaSegmentation$1ApplyClassifierThread.run(WekaSegmentation.java:4773)
java.lang.NullPointerException
	trainableSegmentation.WekaSegmentation.applyClassifier(WekaSegmentation.java:4830)
	trainableSegmentation.Weka_Segmentation$1ImageProcessingThread.run(Weka_Segmentation.java:1806)

Exception in thread "Thread-9" 	at trainableSegmentation.WekaSegmentation.applyClassifier(WekaSegmentation.java:4830)
	at trainableSegmentation.Weka_Segmentation$1ImageProcessingThread.run(Weka_Segmentation.java:1806)
java.lang.NullPointerException
	trainableSegmentation.WekaSegmentation.applyClassifier(WekaSegmentation.java:4830)
	trainableSegmentation.Weka_Segmentation$1ImageProcessingThread.run(Weka_Segmentation.java:1806)

	at trainableSegmentation.WekaSegmentation.applyClassifier(WekaSegmentation.java:4830)
	at trainableSegmentation.Weka_Segmentation$1ImageProcessingThread.run(Weka_Segmentation.java:1806)
java.lang.NullPointerException
	trainableSegmentation.WekaSegmentation.applyClassifier(WekaSegmentation.java:4830)
	trainableSegmentation.Weka_Segmentation$1ImageProcessingThread.run(Weka_Segmentation.java:1806)

	at trainableSegmentation.WekaSegmentation.applyClassifier(WekaSegmentation.java:4830)
	at trainableSegmentation.Weka_Segmentation$1ImageProcessingThread.run(Weka_Segmentation.java:1806)

#2

Hello @Bombard,

Sorry for the late answer. It seems you run out of RAM memory to execute the plugin. You should try with a smaller image or run Fiji with more memory (under Edit > Options > Memory & Threads).