Open CellKai opened 2 years ago
not sure what caused the issue, but it seems to be fixed using Trainable_Segmentation-3.2.34.jar.
not sure what caused the issue, but it seems to be fixed using Trainable_Segmentation-3.2.34.jar.
apologies for re-opening this issue, but I just noticed that I observed this issue in the latest version v3.3.2 and could confirm that it was not present using the older version v3.2.34. So I think this is in fact a current issue thats reproducible and ongoing.
I just want to state that I am having the same issue with scripting segmentation and is fixed with older distributions. Thanks for keeping an active distribution.
I have to say I noticed the same bug with the weka-dev-3.9.4.jar
or Trainable_Segmentation-3.3.2.ar
version. Any solution would be welcomed.
Thank you all for reporting! I'll work on it as soon as I can!
Hello, I realize this thread is quite old but unfortunately I have run into the same problem and wonder if anyone has found a work around since the issue was first posted. I'm very new to Fiji and code, so I don't really have the capacity to figure out what is going on by myself.
The current version is Trainable_Segmentation-3.3.4.jar
After training my classifier, I tried to use, it and the tiling script, to segment two 11 000 x 14 000p test images (using 11 tiles in x and 14 tiles in y, 0 tiles in z).
The Fiji log shows : Field of view: max sigma = 16.0, min sigma = 0.0 Membrane thickness: 2, patch size: 19 Read class name: Vessels Read class name: Background Error while adjusting data! Classifying Image 1 (3930 VCAM)-1.tif using 154 tiles... Processing slices of Image1(3930VCAM)-1-crop-0-0 in 1 thread(s)... Starting thread 0 processing 1 slices, starting with 1 Creating features for slice 1... Filtering feature stack by selected attributes... Classifying slice 1 in 16 thread(s)...
I then get a message from Fiji saying :
Console says this :
Any ideas would be greatly appreciated. Thank you in advance,
Myeline
Since a few days applying a Weka model in a script fails with the error "Error while adjusting data!". I am using Weka v3.3.2
You can reproduce the issue using the minimal example described on image.sc: https://forum.image.sc/t/applying-weka-model-in-a-script-fails-in-recent-version/54822
IJ.log windows output:
Field of view: max sigma = 16.0, min sigma = 0.0 Membrane thickness: 1, patch size: 19 Read class name: class 1 Read class name: class 2 Error while adjusting data! Classifying blobs.gif using 4 tiles... Processing slices of blobs-crop-0-0 in 1 thread(s)... Starting thread 0 processing 1 slices, starting with 1 Creating features for slice 1... Filtering feature stack by selected attributes... Classifying slice 1 in 8 thread(s)...
Console printout: Started Untitled.ijm.py at Mon Mar 07 11:23:39 CET 2022 Traceback (most recent call last): File "Untitled.ijm.py", line 31, in
File "Untitled.ijm.py", line 26, in apply_weka_model
at trainableSegmentation.WekaSegmentation.applyClassifier(WekaSegmentation.java:5692)
at trainableSegmentation.WekaSegmentation.applyClassifier(WekaSegmentation.java:6695)
at trainableSegmentation.WekaSegmentation.applyClassifier(WekaSegmentation.java:6595)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
java.lang.NullPointerException: java.lang.NullPointerException
Caused by: java.lang.NullPointerException at trainableSegmentation.WekaSegmentation.applyClassifier(WekaSegmentation.java:5692) at trainableSegmentation.WekaSegmentation.applyClassifier(WekaSegmentation.java:6695) at trainableSegmentation.WekaSegmentation.applyClassifier(WekaSegmentation.java:6595) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.python.core.PyReflectedFunction.call(PyReflectedFunction.java:190) ... 27 more