- Overfitting: Your model might be overfitting to the training and validation datasets. Consider the following approaches to resolve this:
- Data Augmentation: Increase data diveristy by applying transformation such as rotations or flip. Refer to the following example for more information on data augmentation for deep learning workflows:https://in.mathworks.com/help/deeplearning/ug/image-augmentation-using-image-processing-toolbox.html
- Regularization: Implement regularization techniques such as for deep learning, you can increase the L2 regularization factor in the specified training options or use dropout layers in your network to avoid overfitting. Refer to the following example for more information on regularization:https://in.mathworks.com/help/stats/regularization-1.html
- Dataset Imbalance: If your classes are imbalanced, the model might be biased towards the majority classes.To avoid this you can consider the following:
- Class Weighting: Assign higher weights to minority classes during trainin
- Resampling: Use techniques like oversampling or undersampling to balance the dataset.
- Refer to the following MATLAB Answer to learn more about resampling an unbalanced dataset:
- https://in.mathworks.com/matlabcentral/answers/168846-resampling-an-unbalanced-dataset
- Validation and test set differences:
- cross-validation: use k-fold cross-validation to get a more robust validation score. Refer to the following link for more information: https://in.mathworks.com/discovery/cross-validation.html
Wrong test results in Semantic Segmentation of Multispectral Images with U-NET
4 views (last 30 days)
Show older comments
Hi everyone,
I use the tutorial that Matlab has prepared with Unet to apply semantic segmentation of multispectral images.
There is no problem with images with 5 or more bands in my data. However, when I use the same images as 3 (RGB) or 4 (RGBIR) bands, although the validation value is high, the entire test image is estimated by one or two classes (the number of classes is 8). There is no problem in training and validation. Why does such a result appear in the test image despite the high validation result? Thank you.
0 Comments
Answers (1)
Sanjana
on 8 Oct 2024
Hi,
I understand that you are experiencing low performance on test data, but the performance on validation data is high.
Possible reasons for such behaviour would be the following:
Hope this helps!
0 Comments
See Also
Categories
Find more on Image Data Workflows in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!