You can directly classify pixels using the Trainable Weka Segmentation plugin (formerly the advanced Weka Segmentation plugin) from Fiji/ImageJ .
The plugin is designed for segmentation through interactive learning . This means that the user must select a set of functions (edge ββdetectors, texture filters, etc.), select the number of classes (2 by default) and interactively draw (with ROI tools) samples of all classes. After training the classifier based on these samples, all the pixels in the image will be classified, and the segmentation result will be displayed by overlaying the original image. The idea is to repeat this process (drawing + training) until satisfactory segmentation is obtained.
The plugin also provides a set of tools for saving / loading samples in the ARFF format and saving / loading the classifier in .model format, so it is fully compatible with the latest version of WEKA.
If you want to do image classification , you can also reuse some of the plugin methods.
source share