2024-09-17 13:02:26 (WARNING) TrainImagesClassifier: The layer 0 of C:/Users/User/AppData/Local/Temp/processing_vcMRGr/ac3c0189c6684da1acff0d3e8df7b069/io_out.file_samplesValid_1.shp is empty, input is skipped.
2024-09-17 13:02:26 (FATAL) TrainImagesClassifier: itk::ERROR: ShiftScaleSampleListFilter(0000029C716DFC90): Input Sample List is empty
Hello Victoria,
The error above indicates that the samples extracted for training your image do not find any lists (there are no attribute fields in your vector layer). Make sure you’ve done several things before launching your TrainImageClassifer tool:
Here are the steps:
- Use the sample selection tool if you want to extract points from polygons, with a ‘code’ field for example, for which each code will correspond to a land use class, for example code ‘1’ will be water, code ‘2’ will be buildings etc… no other fields in your polygons
- Using the sample extraction tool with the result of sample selection sela will allow you to have points superimposed on your image which will extract all the pixel values of the number of points you have per class (the code field).
- When you have your result after using the sample extraction tool, you can enter it into your TrainImageClassifier using an SVM or RF etc…