Rndom forest classification steps


#8

Thanks my friend. Yes you are right. I used other GLCMs but I was curious about phase as well because I saw good result on one part.
As I told you I have three images from same location and I choose training data on one of them (they are added to vector section). As you can see in below image.

But I want to add same training data (same amount, same location) that I choose on above image on other images.
What should I do?


#9

When you say you have three images, you mean three SAR image of the same location captured in different periods?
Then you should produce three classification images and compare to each other? is that what you are trying to do?
If yes, then you follow the same process for all of your images.

  1. collect training data for each class
  2. perform classification for each image
  3. compare

#10

On the other hand, if the objective is to use the three images to create only 1 classification output, it is enough to add the training data to one of them only. No need to duplicate the training data in each one


#11

Actually I have one backscattering image with its coherence and phase (it means images are in same date and even second). I plan to apply same training data on coherence and phase images that I applied on backscattering image and then do classification with 3 images (intensity, coherence and phase) simultaneously.


#12

Yes my friend. I got it now. I think it is something you mentioned it. I hope I did well.


#13

Only one thing @johngan ;
I am wondering that if we have two images in same location or two images (backscattering and coherence in my case) and we added training samples (water, fast ice, close ice and others) on vector in backscattering image.
Is it possible use training samples on vector in backscattering image for doing classification ONLY on coherence image?
In my idea, it is possible by the way in below. Am I right?


#14

If you have datasets for a region and you derived the coherence image from those same datasets, then you need to create training data only once (lets say using the backscatter image) , you do not need to replicate the training data for the coherence image


#15

Thank you for answers
I only have another question.
As I look at the result of my classification (Random forest) with backscattering image. It works (you can see the result in below) but I do not know why when I add backscattering image in ‘productset reader’, whole options (I mean type, acquisition , track and orbit) are empty.
Is this a problem? Although I think classification is working even without appearing these options.

Image1: Adding backscattering image in ‘productset reader’


Image2: My classification result (Random forest) with backscattering image


#16

you can add these information by clicking on these blue arrows


#17

Hi all,
When I am using this Random forest classification process with only 2 vector data classes water and non-water, I see this error “bound must be positive” as in the screen capture below.
I try to do again all the previous steps as you said above and I even check the Pixel Info, the intensity of pixel in each band > 0 but this error still appear.
Do you know how to solve this problem?
Thank you in advance.


#18

hi, I also encountered the same problem. Did you solve it?

Thank you.


#19

it has something to do with the projection of your data. Which coordinate reference system did you select in the terrain correction step?


#20

Yes I solved it. Because in the terrain correction step I chose WGS 84, then it happend. So I need to reproject my data. Go to Raster >> Geometric Operations >> Reprojection, and then choose the project as Geographic Lat/Lon (WGS84)


Blank result after supervised classification
#21

glad to see this worked.
Did the reprojection change your values in any way? If I undestand you correctly you selected WGS84 in the terrain correction and then reprojected also to WGS84?


#22

I reproject the data into Geographic Lat/Lon. After that, the values do not change.
I try some times with some different data and I find out that in the classification step, it works with the Lat/Lon project.


Supervised and unsupervised classification, Sentinel 2
"bound must be positive" error in the Random Forest Classifier
Supervised Classification with Sentinel-2
Profile of a colour image
Image Fusion Using Sentinel 1 and Sentinel 2
#23

good to know, although it is ab bit strange that this step is required.


#24

hi , i need help
you have created polygon on sigma0_hh_db,s o how you had applied on _glcm product ,as both are different
or i have to stack sigma0_vv_db band to _glcm product.
where to give polygon on sigma0_vv_db or any one of the glcm product


#25

create the GLCM layer and stack it with your oiriginal Sigma0 file. The final product will contain both the intensity and the textures.


#26

after following your step ,i got this classification


can help in identifying the black area
as that is a river area, but i made two classes blue showing water area , then why black?
and what does confidence image tells.


#27

areas which are not classified do not fulfill the confidence criterion of Random Forest, that means they cannot be assigned to one of the classes.
You should read a bit about the classifier before applying it:
http://wgrass.media.osaka-cu.ac.jp/gisideas10/papers/04aa1f4a8beb619e7fe711c29b7b.pdf

Please also use the search function for common questions:


Issue with Supervised random forest classification