MODIS through Google Earth Engine to monitor crops

What Google is doing with the earth’s satellite imagery is really quite amazing. Check out Google’s Earth Engine. On the landing page you get some great videos. I recommend Amazon Deforestation: Timelapse and Drying of the Aral Seas: Timelapse.

Once you have had enough of these visit their data catalog where you can load any of the common earth observing satellites into a Google Workspace which is the Google Map environment with additional features allowing you to display the satellite images.

Google say they have developed their Earth Engine mainly for monitoring deforestation which is valuable but there are several ways this technology is useful in agriculture. For example load the MODIS Daily EVI into the Workspace. Once in the workspace go to a farming area you know well and you can monitor how much (healthy) crop is established. Although MODIS imagery is free to download, Google take out all the processing time and make it easy to keep an eye on the district.

MODIS EVI captured on 2012-12-05. Showing area north of Moree NSW Australia. Google Earth Engine used to display image.
MODIS EVI captured on 2012-12-05. Showing area north of Moree NSW Australia. Google Earth Engine used to display image.

Sorghum wants rain

This year we planted sorghum in late September on marginal planting rain. We have been relying on stored moisture and patchy storms to keep the crop moving along. The crop is spread across a few stages with the early planted sorghum starting to fill grain and later sorghum struggling, still putting up a head or flowering. The photos show the earlier planted sorghum, variety ‘Buster’, that has 120kg/ha of pre-applied urea.

Hope you all have a safe, wet and Merry Christmas!

QGIS SEXTANTE Modeler: Automate yield data processing

This is a followup post to Processing harvest yield data to grid / raster where I outlined my yield data processing steps. This post shows how I use the Modeler in SEXTANTE to automate this process utilising SAGA algorithms.

The idea of the modeler for me is to save time and keep consistent processes. In the screen shot below you can see that the model requires the yield data point file (where the Dry Yield table column needs selecting), paddock boundary and the grid and filtered points output file location. The model takes care of all the processing steps.

Select yield data point file to be processed and choose output location. The modeler does the rest!
Select yield data point file to be processed and choose output location. The modeler does the rest!

While constructing the model the only tricky part was making sure I had a separate ‘Extent’ field to input into the ‘Shapes to Grid’ algorithm. Even though I always leave this blank, it is required for the algorithm to realise the extent is just the minimum covering extent of the input shape file.

SEXTANTE model editing screen displaying input fields and algorithms involved in the yield data processing
SEXTANTE model editing screen displaying input fields and algorithms involved in the yield data processing
Yield Map: L3 Chickpeas 2012
Yield Map: L3 Chickpeas 2012

A few years ago I used to use model builder in ArcGIS and really missed it when I no longer had access to ESRI software. The SEXTANTE Modeler fills that gap and allows a combination of algorithms from several different toolboxes.

Some more advanced applications of Sextante Modeler are available here.

Processing harvest yield data to grid / raster

The process to convert point data to raster (or grid) for can differ dramatically depending on who you ask and the purpose of the conversion. Generally data is processed for two main functions. The first being ‘stacking’ or ‘layering’ to later develop prescription maps or other further processing. The second is improved visual representation of the data. My process aims to satisfy both with minimal processing time. My method does contain some compromises; since I use a coarse resolution it is not as pleasing on the eye as some other methods. In addition, my data smoothing technique is quite broad which means you will loose some detail in the grid.

At this point in time I follow these steps:

  1. Clean up point data either manually manually or with a filter to remove any obvious errors such as where header turns in paddock. EDIT: I am currently trying Yield Editor for this step.
  2. Produce a grid over the top of the point data. Any cells that share a points average the point values.
  3. Gaps in the grid are filled in.
  4. Gaussian Filter is used to ‘smooth’ the data.

In QGIS this is the process:

Note: You will need to have SEXTANTE and additional toolboxes setup to follow these steps. Instructions are available here.

  1. Load paddock boundary (shape file polygon)
  2. Load yield data points (You will need these in shape file format – use export function in SMS or FOViewer if your yield monitor does not produce ESRI shape file)
  3. SEXTANTE > SAGA Toolbox > Shapes – Points > Points Filter
    1. Radius: 100
    2. Minimum Number of Points: 25
    3. Maximum Number of Points: 200
    4. Quadrants: No
    5. Filter Criterion: Remove Below Percentile
    6. Percentile: 15-20
  4. SEXTANTE > SAGA Toolbox > Shapes – Points > Points Filter (use output from step 3)
    1. Radius: 100
    2. Minimum Number of Points: 25
    3. Maximum Number of Points: 200
    4. Quadrants: No
    5. Filter Criterion: Remove Above Percentile
    6. Percentile: 90
  5. SEXTANTE > SAGA Toolbox > Grid – Gridding > Shapes to Grid
    1. Preferred Target Grid Type: Floating Point
    2. Cell Size: 15
    3. Method for Multiple Values: Mean
  6. SEXTANTE > SAGA Toolbox > Grid – Tools > Close Gaps
  7. SEXTANTE > SAGA Toolbox > Shapes – Grid > Clip Grid with Polygon
  8. SEXTANTE > SAGA Toolbox > Gaussian Filter
    1. Standard Deviation: 3
    2. Search Mode: Circle
    3. Search Radius: 50

Make sure you do a visual comparison with original point data to ensure the final grid is a good representation of the original data.

Visually check to see that processed grid file is a fair representation of the original point data.
Visually check to see that processed grid file is a fair representation of the original point data. Note I was lazy in this photo and used un-filtered yield data.

To generate useful color maps to represent the grid data try http://colorbrewer2.org/. One day I will explain this process, but it is not too hard to try it yourself.

Now when we get clever we can use the SEXTANTE Modeler to automate this process. More on this later! –Edit: Here is the modeler info.

 

Setting up QGIS for Precision Agriculture GIS: Free Software

QGIS rivals ArcGIS as desktop GIS software especially within Precision Agriculture. The difference is that QGIS is Open Source and therefore free to use for personal and commercial use. Open Source has many other advantages. If you are familiar with ArcGIS you should give QGIS a go.

If you run Windows I recommend installing using the OSGeo4W installer. Run the ‘Desktop Express Install’.

‘Out of the box’ QGIS is very capable. But it is not until you install a few powerful plugins that it’s real potential is revealed. So far the plugins I use on a daily basis are: SEXTANTE and Table Manager. SEXTANTE is not much good to me without SAGA. Together these make available a comprehensive list of common Vector and Raster GIS algorithms. Optionally install TauDEM and Orfeo (I have installed these but not yet used them).

Setting up SEXTANTE in QGIS 1.8 (Windows 7 & 8)

Install Sextante Plugin (In QGIS: Plugins > Fetch Python Plugins).

So SEXTANTE has access to the SAGA algorithms it needs to be downloaded and installed: SAGA.

Configure SAGA in SEXTANTE (In QGIS: Analysis > SEXTANTE options > SAGA), insert SAGA folder and check Activate box.

Similar to SAGA, download and install TauDEM 5.0.6 & MPICH2 (make sure you follow install instructions on the download page).

Configure TauDEM in SEXTANTE (In QGIS: Analysis > SEXTANTE options > TauDEM), insert MPICH2 bin directory, TauDEM command line tools folder and check Activate box.

Install Table Manager

Plugins > Fetch Python Plugins

Search for Table Manager and click Install.

With these two plugins, especially SEXTANTE, QGIS becomes extremely capable.

SEXTANTE with SAGA in QGIS 1.8

http://rcm-na.amazon-adsystem.com/e/cm?lt1=_blank&bc1=FFFFFF&IS2=1&bg1=FFFFFF&fc1=000000&lc1=0000FF&t=agma-20&o=1&p=8&l=as1&m=amazon&f=ifr&ref=tf_til&asins=178216748X

Disc Planter Photo Log

In 2009 we wanted to try out planting with a disc planter with minimum outlay. Up until this stage all planting was done with a narrow point on a tyne. The advantages of using a disc machine is there is less soil disturbance, high planting speeds, better seed placement and lower fuel usage. Down side is there is higher service requirements and conditions need to be just right.

We purchased what seemed to be an old home made shielded sprayer. We removed all the spraying bits so we had an empty bar, painted it and added four support wheels. We then attached 16 Excel Single Disc units to the bar on a 0.66m spacing with the idea to apply urea and plant chickpeas.

The units were a success and in 2010 we bought a complete Excel planter bar and units on a 0.333m spacing which we used to plant 100% of our winter crop in 2011 and 2012.

My first QGIS plugin: BigButtons

I’ve recently started playing around with QGIS plugins on my Windows 8 (and 7) machines. After working through the initial process which I discussed here I had a go at making my own (very) simple plugin.

The purpose of the plugin was to allow easy access to zoom and pan functions for a touch screen laptop such as my Panasonic Toughbook.

I use the BigButton plugin in conjunction with QGIS Tracker and OpenLayers. I mounted a GPS on a quad bike with my Toughbook and went out to record a trip with live Google Maps underneath. This worked to a point.

Warning: Using these three plugins together is riddled with bugs. Just the ones I notice from 10 minutes use include:

  • BigButtons will not work properly while QGIS Tracker is Tracking GPS Location as it is programmed to keep the marker centered. Once tracking is stopped BigButtons functions as normal.
  • As the marker direction from QGIS Tracker changes in reference to the GPS bearing the Google Satellite from OpenLayers plugin will go white underneath.
  • BigButtons ‘Cycle Layer’ currently only works if you have all layers in a single group – and even then can do some strange things – needs work!

Download QGIS Plugin tested on Windows with QGIS 1.8: BigButtons-Experimental

Photo of my quick and dirty GPS setup on quad bike: