Public Lab Research note


Video NDVI

by cfastie | June 02, 2013 14:01 | 145 views | 2 comments | #8016 | 145 views | 2 comments | #8016 02 Jun 14:01

Read more: publiclab.org/n/8016


Image above: Three frames from an infrablue video we are trying to convert to NDVI

Jeff converted a Canon Powershot SD4000 to infrablue and inquired about using the good video it captures to make NDVI movies. I took some video clips with my infrablue Powershot A810 and made false color infrared video from it just by switching color channels in Adobe Premiere. Premiere does not seem to know how to do division on pixel values, so it might not be able to make NDVI. Don has been working on using ffmpeg to make NDVI video but is not sure he is getting the correct NDVI values.

There is not necessarily a correct NDVI value for any plant part, or at least it is very hard to calibrate NDVI that well. So these days we are just trying to get the values in the proper range. The values in Don's video are reasonable, especially considering that the video has been converted in Premiere, then by YouTube, then by ffmpeg, and then by YouTube again, and the values in the color channels could have been tweaked in the process. To provide a baseline for comparison, I captured three frames from the infrablue video I took (above) and ran them through Ned's ImageJ plugin. I used ImageJ to apply a particular color table to the floating point NDVI image made by the plugin, and then displayed a histogram of the values in each frame. This process also needs some scrutiny because Premiere saved bmp files which I converted to jpg in Photoshop, and also the ImageJ plugin produces different color mapping depending on some variables we are looking into now. But the histograms are revealing about how the infrablue NDVI is related to plant vs non-plant parts of a scene.

beeinfhista.jpg

NDVI of frame of the bumble bee video clip with histogram of values. The spike for the single value of 255 reaches as high as the tip of the arrow.

pondinfhista.jpg

NDVI of frame of the pond forest video clip with histogram of values. The spikes for the single values of 0 and 255 reach as high as the tip of the arrows.

fusciainfhista.jpg

NDVI of frame of the fuschia video clip with histogram of values. The spike for the single value of 255 reaches as high as the tip of the arrow.

Although the NDVI values range from -1 to +1, each pixel in these images has a value between 0 and 255 which represents the scaled NDVI values (so 0=-1 and 255=+1). A color table assigns an arbitrary color to each value to make the color image. The histogram shows how many pixels in the entire image (Y axis) are each color (x axis). These values are in the general range they should be in. Each image has a spike of values equal to 255 which represents an NDVI value of +1.0. These magenta pixels are often in dark parts of the scene (the tree trunks in the forest) but also make weird outlines of the fuschia plant. The most likely explanation for the NDVI formula (NIR-blue)/(NIR+blue) producing lots of values equal to 1 is that the value for blue in the infrablue photo was zero. So the blue channel was very underexposed (not exposed at all) and the red channel (NIR) was non-zero. There is also a spike of values equal to 0 (NDVI= -1) in the forest frame due to the sky. This must be because the red channel value (NIR) was zero and the blue value was non-zero.

We have noticed that deep shadows in either two camera or one camera infrared systems often produce anomalously high values for NDVI. It appears that most of these high values are exactly equal to one, and therefore apparently represent extreme underexposure of the visible light channel (blue=0 or red=0). Maybe it would be a good idea to use a color table in which only the value of 255 is magenta (or some other conspicuous color) so this anomaly can be recognized.


2 Comments

Is there any interest in a video processing option in the ImageJ/Fiji plugin?

Is this a question? Click here to post it to the Questions page.

Reply to this comment...


I think NDVI videos have the potential to be effective instructional vehicles and possibly important scientific records. The Kickstarter Infragram cameras will probably all be webcams and capable of capturing video, so many of the backers might find uses for NDVI (or NRG, NBG or NIR) video. The web app that Don and Craig are working on might have some of these capabilities, but an offline version might be more robust for higher resolution, longer clips, more options, multiple color tables, etc.

Reply to this comment...


Login to comment.

Public Lab is open for anyone and will always be free. By signing up you'll join a diverse group of community researchers and tap into a lot of grassroots expertise.

Sign up