Spatial Modeler Discussions

Gain, exchange, and share knowledge, or discuss topics with other Hexagon Geospatial Product pioneers and experts to get the most out of Hexagon Geospatial products.
Showing results for 
Search instead for 
Do you mean 
Reply
Contributor
Posts: 32
Registered: ‎01-31-2017

NDVI classification and Change Detection then area calculation

Dear All.

 

I trust this finds you well.

 

I have a model i am working on crop vigour in rice plantations. This model requires that i do the following:

 

  1. Claculate NDVI 
  2. Classifiy it into 4 classes (+ unclassified class makes it 5classes)
  3. Then perform a change detection of every class
  4. Then calculate area of each change ( no change | Increase | Decrease )

I have created a model as attached, but im not gettting concrete results and when i do, only one element of the models runs to completion, the rest are just left idle.

 

Kindly have a look and let me know if the model is viable and what i can do to improve this or where im going wrong.

 

NB: The image is just a sample

  • Naivasha images
  • Agriculture 1 model

Regards,

Lilian

Technical Evangelist
Posts: 839
Registered: ‎10-01-2015

Re: NDVI classification and Change Detection then area calculation

Hi Lilian,

 

Can you please also provide the vector layer the model is expecting as one of its inputs?

 

I would add operators to your model to get the desired pixel size (perhaps from one of the two input images) and apply those to the Convert to Raster operator so that the rasterization occurs at an appropriate resolution.

 

"only one element of the models runs to completion" Which element runs to completion? I tried running the model (by removing the vector inptu and just multiplying those operators by 1) and every branch in th emodel exectued. 

 

As per the other thread, this type of logic for Criteria statements I dont think is going to work for you in categorizing the NDVI results:

 

Criteria.PNG

PErhaps this is what you are intending. But please check each Criteria and make sure the Class column is set to produce the output DN value you are expecting. In almost all cases you are currently outputting 0 if the criteria is met and 0 if it is not. Which doesn't seem like the correct thing to do? Were you expecting to get 4 (5 with background) distinct classes?

 

Let's figure that out first and then take it from there.

 

Cheers

 

Ian Anderson
Chief Product Owner, Desktop Remote Sensing
Hexagon Geospatial
Technical Evangelist
Posts: 839
Registered: ‎10-01-2015

Re: NDVI classification and Change Detection then area calculation

Hi Lilian,

 

I think the attached model is closer to what you are trying to achieve? Note that I had to remove the vector input since I did not have an appropriate input shapefile for your data. 

 

Cheers

 

Ian Anderson
Chief Product Owner, Desktop Remote Sensing
Hexagon Geospatial
Technical Evangelist
Posts: 839
Registered: ‎10-01-2015

Re: NDVI classification and Change Detection then area calculation

Actually, this version matches your output class names better (0 = no change, 1 = decrease, 2 = increase)

Ian Anderson
Chief Product Owner, Desktop Remote Sensing
Hexagon Geospatial
Contributor
Posts: 32
Registered: ‎01-31-2017

Re: NDVI classification and Change Detection then area calculation

Dear Ian,

 

Thankyou for indulging me.

 

Please find the vector layer attached. (Incase you still need it)

 

My model was only running say the "before image" elements to completion then disregarding the other elemennts. 

 

I also switched up some things in the model i sent and included the corrections you had indicated in the previous thread. Essentially i want an image;

 

  1. of NDVI classified in the 4 classes (+ unclassified making this 5 classes)
  2. indvidual NDVI classes ectracted from the (1) image
  3. comparison or chnage detection between this classes (before & after images)
  4. highlifght (3) either as increase(Green), decrease (Red) and no change (black)
  5. then if possible indicate the areas of (4)

 

I'm still looking at the model you sent. I will get back to you on the progress tomorrow.

 

Regards,

Lilian