Public Lab Research note


PhenoPi: a citizen science phenology monitoring network

by khufkens | April 24, 2015 02:03 24 Apr 02:03 | #11766 | #11766

This project needs some context, so here goes...

What is phenology?

Phenology is the study of (the timing of) recurring life cycle events. This includes both animals and plants alike. However, my particular research interest goes out to plant phenology. Plant phenology studies when plants leaf out, when they drop their leaves or when other life cycle events happen (flowering, shoot elongation, needle drop, ... ).

Plant phenology is also tightly coupled to our climate, as it influence how much CO2 is captured through photosynthesis from the atmosphere and how bright the surface of the earth is (it's albedo). In addition it also mediates the flow of water and energy (through transpiration). In the animation below you see the seasonal changes across the globe as the growing season switches from one hemisphere to the next.

This process removes substantial amounts of CO2 from the atmosphere, more so in our warming world the growing season length is increasing by 3-5 days per decade. These extra days of photosynthesis provide a negative feedback to the CO2 induced warming of our world. However, how much more CO2 will be removed and how plants will respond to a warmer but also more CO2 rich world remains a question. To answer these questions we can formulate mathematical constructions which model plant phenology in response to various climatological drivers. The output of detailed atmospheric model displaying variations in CO2 across a year is shown below.

However, such a model must be validated against real data. One of these sources of data is remote sensing data from various satellites circling the earth. Sadly, these satellites are limited by a spatio-temporal trade off, where one can get either high resolution data at a low temporal scale or low resolution data at a high frequency. In order to optimize current phenological models a high frequency, high resolution view on plant growth would be ideal. This is where PhenoCam project comes into the picture.

The PhenoCam Project

The PhenoCam project is a project started and run by Dr. Andrew D. Richarson at Harvard University which uses PhenoCams to keep watch of vegetation at both a high spatial and temporal resolution using conventional cameras. PhenoCams register a standard RGB jpeg every half hour. These images are than converted to time series of vegetation greenness using a green chromatic coordinate (Gcc) index; which is the ratio of green pixels and the images brightness (sum of all channels).

Below you find an image illustrating how various biomes respond to changes in both temperature and precipitation (image by A. D. Richardson). You see that vegetation growth in a temperate deciduous forest (A) is mostly triggered by temperature rather than precipitation. A Mediterranean oak forest (B) on the other hand is more dependent on pulses of precipitation. A similar response is recorded when comparing a northern temperate grassland with a moisture limited tropical grassland location. These PhenoCams provide us with the necessary data to validate our phenology models (including some recent work I did on grasslands). Currently the PhenoCam project has > 200 cameras installed across US and elsewhere.

Gcc across various biomes

Most of the PhenoCams are installed by the project or researchers around the country. Unlike other projects such as project budburst and the National Phenology Network which rely heavily on citizen scientists to observer changes in (plant) phenology the PhenoCam project does not offer such opportunity. Although citizen science involvement for data processing is being worked on, the financial burden of the current PhenoCams (~$500-900) makes involving citizen science in data collection difficult.

PhenoPi

I recognized that people often have a window pointing towards some street trees or their garden. This is a missed opportunity I feel. I was hoping to engage citizens in collecting digital repeat imagery data. This could only be achieved if the price point of the camera used was lowered, and the process of installing the software would be rather trouble free.

Involvement of citizens would widen the coverage of the PhenoCam network, adding to our knowledge of how plants respond to a changing climate but also filling in gaps in spatial and temporal coverage. The limited distance to most garden trees also ensures a close up view of the vegetation, which is lacking in most of the current PhenoCams.

So, in order to fill this gap I design some basic hardware and software to complete automated image collection (time lapse if you will) using a simple window mounted raspberry pi camera, hence PhenoPi.

Hardware

I use a simple housing for a raspberry pi, which uses suction cups to stick to any window pointing at trees. The schematics in FreeCAD format can be found here. I also provide DXF drawings which can be used in a laser cutter or CNC machine. For those with a 3D printer an SLT file is provided as well however but I'm not sure about the strength of the design. The design is the third version, and should be final. Below I show the original version which is larger and did not have a viewfinder or any buttons or indicator LEDs. An earlier version of the PhenoPi is shown below, illustrating the operation / mounting on a window.

phenopi v1

I would say that from a hardware point of view the project is finished! I did consider some alternative setups but they all lead to either increasing cost, complexity and / or degraded data (moving camera lenses would cause drift which is a major issue in post processing).

Software

The current sofware can be found on my bitbucket PhenoPi page. The code available currently covers an upload script which triggers the camera, a script which pulls additional localized weather data, an installation script for the former and a script to install a real time clock if necessary.

Currently the majority of the work is software based, trying to streamline the install to make it as painless as possible. A complete hands off install will not be possible so it will always remain sort of a DIY project I fear. The current software has been running for over four weeks at my parent’s place, capturing the onset of spring greenup nicely!

lint

So, my proof of concept works. However, here is a lot of room for improvement. For example I still have to write the code interfacing the button switch and LED to accept and provide feedback.

Post processing software is already in place as this is an integral part of the PhenoCam project. All software is freely available online and can be found here.

Concerns / ideas to implement

  • Privacy, how to ensure privacy while still collecting data, note my dad in the image above. I was considering a privacy filter blacking out the lower part of the image only registering the canopy.
  • How easy should the software install be, where do you draw the line => major time sink
  • Ownership / licensing of the collected data, do you upload everything and retain nothing or do you retain everything (as a copy) which would cause storage issues
  • Provide added value:
    • Time lapse feature, monitor your vegetables grow
    • Security feature - keeping watch of your back door / grandchildren playing in the garden
    • Data streams would be separate to address the above mentioned privacy concerns, all data and code would be open as well

Feedback

I would like some community feedback on my project

  • For one, how many people would be interested? Give me shout if so.
  • If you see possible improvements, without adding cost, let me know
  • If there is enough interest, how do I make this into a PublicLab kit?

Info / Contact

My personal site can be found at www.khufkens.com, should you want to keep track of my other projects and research.


9 Comments

I really like the idea of making useful data by pointing a camera out my window. I have a Raspberry Pi lying around (no camera yet) and lots of windows with trees outside. I guess the window should be one that is not going to be opened all summer so the equipment is not disturbed. Also, changes other than vegetative should not be a big part of the scene (no cars parking intermittently, or new structures being built). Does it make any difference whether half of the scene is white pine trees (the other half is Vermont deciduous forest or lawn). How will the Pi do if installed on a window in an unheated garage (drops to -20 F in winter)? There are also lots of bugs in the garage. This could be a fun project.

Chris

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

Reply to this comment...


Hi Chris,

With respect to vegetation types, everything goes. As long as there is vegetation in the field of view this should work. If you check the PhenoCam webpage you see a lot of diverse sites (but mostly still research locations, but some schools as well). I'm currently working on an evergreen study which involves white pines, so yes those would work. Actually the more vegetation types in the field of view the better as this provides a way to assess the response of different vegetation types to varying climatological conditions e.g. the evergreens might not care so much about temperature as the deciduous trees do in spring.

I'm not sure about the temperature limits on the electronics. Most of electronics generate some heat which prevents them from freezing (but -20F is low). We have StarDot cameras in Alaska working the whole year round, but they run rather hot. Conceptually I did design the housing to be simple and for indoor (room temperature) use. So time will tell if it will keep functioning at such extreme temperatures. The bugs won't be a problem I think, and if not sure I might suggest to cover the gpio pins on the pi with some insulating material so they can't get shorted by a bugs goo.

Cheers, Koen

Reply to this comment...


So it could be useful to point the camera at a scene with solid white pine trees on the left and mixed deciduous on the right and lawn at the bottom and then the images could be batch cropped for finer scale analysis.

How about opening the window in summer? Finding a window that stays in the same place all year and never has a screen in front of it might be a problem here.

Are the photos saved to SD card? So anytime you want you can steal the SD card and dump the photos and return the card before the next scheduled photo? There is no live feed of the photos?

So anybody with a Pi and a Pi cam can grab your software and start collecting?

I guess I should make a 3D printed housing for the Pi. I have a couple of suction cups. Do you have the hardware plans in STL format (or Sketchup)?

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

Reply to this comment...


I'm still working on the software part to add functionality, as suggested in the note.

As it is currently set up, the script now uploads images to my ftp server, unless there is not connection. The no connection situation is not ideal, and would require the addition of a hardware clock to keep accurate time.

There is a live feed of the images, better the last image is saved in the home directory. In my latest install script (untested) I will install a http server on the pi. This would allow you to browse to your pi and look at what the camera was seeing during the last snapshot.

There is also no reason why concurrent services couldn't be run if the handoff of the camera is done properly, hence my suggestion to stream the data as a security service in addition to having it record at an interval.

An STL file can be found here, but I'm not sure if this will hold up. The 3mm plywood is rigid enough but I'm not sure how the plastics compare.

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

Reply to this comment...


Ah, uploading each image sounds like the way to go. Will the default connection be wired or wireless? Thanks for the stl, it looks good.

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

Reply to this comment...


Hi Chris,

I think I didn't answer your questions fully. With some tweaking of the script, yes you can grab the upload_image.sh and get_weather.sh scripts to start logging data.

The upload_image.sh script needs to be edited. You have to set a proper site name, and you might want to check the orientation of the image before you upload. I'll put some more hours in development to make everything easier to deal with.

As I mentioned in my post, the software is rough around the edges and is currently what needs the most attention, mainly making the install as easy as possible (if not make it so that you can do it remotely). I'm aiming for similar functionality as described in my PhenoCam installation tool. This little script takes care of setting up the camera on commercial (expensive) StarDot cameras. Unlike the pi it relies on telnet, which is easier to script I feel.

Also, the window blinds as well as moving are kind of an issue. I hope people would be able to put it up somewhere on a lost (not often used) window (think attic windows or as you mentioned garage windows).

Reply to this comment...


The connection doesn't matter, however a wireless connection will need some more attention during setup (you have to input the password to your router). A wired connection is easier and probably more reliable, but wifi has the advantage of being relatively location independent.

You obviously need a wifi usb stick, as wifi is not integrated into the raspberry pi. If you have one you can just follow the normal installation instructions.

Reply to this comment...


This is a really elegant project! How do you address the differences in light temperature (RGB) and intensity throughout the day? I wasn't sure if you would include a separate light sensor to adjust for that or if that's not necessary. Is there any value in the hourly resolution data as compared to the yearly stuff? I'm wondering if someone like Planet Labs (https://www.planet.com/) might be able to get daily level satellite data, but they definitely will not get hourly (plus of course that data will always be expensive to access).

I also wonder if you've considered anything else you could measure if you're going to have a camera set up besides just greenness? Not sure of ideas, just seems like if you've got the hardware sitting there may as well get the most out of it!

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

Reply to this comment...


Hi gbathree,

we did a study on the "behaviour" of the greenness (Gcc) values across a day and across the year. In general the best values (greenest) are acquired on sunny days with a camera facing north (little shading as possible).

Below you can see the daily patterns of Gcc for sunny and and cloudy days for cameras pointing north. The pattern on sunny days is fairly symmetrical around solar noon. This changes when not pointing north. However, if you acquire enough images than using the 90th percentile of 3 consecutive days guarantees more or less that you will approximate a "good" Gcc value. Streaks of bad weather can pull the values down however. A few of the cameras take far less pictures (e.g. just around noon) and still deliver reasonable time series. However given that you rely on the distribution of good to bad images having more images makes for better final data.

Screen_Shot_2015-04-26_at_22.06.01.png

You can download the full study here

My setup relies on the cameras being indoors, so additional measurements should be derived from image properties other than colour. I've worked on using texture instead of colour to look at seasonality. The figure below illustrates that there is a discrepancy between what you see using colour (red line) and what you see using texture (black dots). The "proof of concept" texture index is variable as I didn't smooth across days, due to the calculation intensive nature of the analysis. The black dots fall of way later in autumn than the Gcc (red line) values. This is due to the fact that a changes in the physical structure of the canopy in autumn do not align with changes in colour. In spring leaf development coincides with an increase in greenness, in autumn leaf drop isn't necessarily synchronous with leaf coloration (most of the time far from it actually).

Entropy.png

Additional measurements, using other sensors will be difficult I fear due to the fact that you are indoors and mostly orthogonal to the sky. You could measure broadband radiation using a simple LED sensor, but this would add little data but would increase complexity a lot. The link to the full article is here. A more complex setup can be found in my other remote sensing notes, the multispectral camera. This opens up some opportunities but again increases complexity and cost (beyond a citizen science / schoolyard budget).

The planet labs data is interesting for sure but as with most high resolution data it is prohibitively expensive (especially if you want to do continuous monitoring).

Reply to this comment...


Login to comment.