Thursday, May 29, 2014

USGS Stream and Reservoir Gauges

Building on the code already in place for Snotel, I'm pleased to announce another real-time datasource: USGS water gauges.  While it's more of a frontcountry source than a backcountry one, streamflow information can still give you a good picture of the snowmelt situation and help determine whether rivers are easily crossable.  Of course boaters use it all the time, but large rivers only make up a small portion of the network, and those gauges are better covered by sites like

that's a lot of gauges

There are 7500 stream and reservoir gauges, v. 850 snotel sites.  I haven't modified the code to be more selective about how many stations get displayed at once, so users with slower, older machines may find their browser slowing down after enabling the water gauge layer.  If this proves to be problematic, let me know - if enough people complain, I'll look into fixing it.  On my 3 year old laptop, it was a non-issue.

Much like the snotel layer, zooming in displays the current real-time value for individual gauges.  Streams show the flow in cfs (cubic feet per second), and also the water temperature in degrees F, if available.  Reservoirs show the current capacity in acft (acre feet).  When you mouse over a station, the tooltip shows the time at which it was last updated.

Click on a station to bring up a graph of the last week.  Cubic feet per second is in blue, degrees F in red, and acre feet in black - although no station will support all 3 values at once.  Mousing over the graph brings up a vertical bar and provides the time and reported values at that point.  Because station update frequency varies, there is no time range selector like with the snotel sites, at least for now.

The layer is available via the "Water Gauges" checkbox underneath the Snotel layer, or click here to try it.

Tuesday, May 13, 2014

New Fire Activity Layer

As the summer fire season approaches, I decided to take another look at integrating current fire activity with CalTopo.  There's a wealth of government supplied fire information out there, and I've long thought about integrating this into a custom source that plays well with CalTopo's other map layers.  When the MODIS layer I'd previously been using went down and stayed offline for several months, it gave me the nudge I needed.

The old MODIS layer has now been replaced by a "Recent Fire Activity" layer which pulls data from several different sources.

The first of these sources is, no surprise, MODIS detections.  The MODIS system consists of two satellite imagers (Aqua and Terra) that take daily multispectral imagery of the planet; the IR band can be used determine surface temperature and, from that, detect wildfires.  Wide swaths of imagery are taken at approximately 10:30AM and 1:30PM local time; while they don't follow timezones exactly, the East Coast is imaged 3 hours before the West Coast.

The Forest Service's Remote Sensing Applications Center processes MODIS images into wildfire hotspots and makes the locations available at  While there are other sources available that have better global coverage or a faster update time, the RSAC dataset has additional metadata I couldn't find elsewhere, like the actual observed surface temperature.

Edit: Shortly after this post, Southern California saw a bout of fire activity, unfortunately giving me an opportunity to put the RSAC data through its paces.  Due to the time lag between satellite passes and their shapefile updates, I've switched to a new NASA Source which still includes temperature observations.

Starting at a wide zoom, these detections appear as multicolored Xs and *s on the map.  I wanted to convey two different attributes, severity and recency, so I needed to vary both the color and symbology.  Government maps use a red->orange->yellow color gradient to indicate the age of MODIS detections, and I decided to follow that for consistency.  Red spots were detected in the last 12 hours, orange in the last 24 and yellow in the last 36.

The asterisks represent hotter, more likely hotspots, while the Xs represent colder, less probable spots.  Zoom in a little further and each spot is marked with its average temperature.  In busy locations this can get a little crowded:

Each MODIS pixel is at least 1km square, sometimes larger, and the surface temperature is an average across the entire pixel.  So a 122 degree spot could be small, intense hotspot or a large, smoldering fire.  As the temperature drops, the certainty that there's a wildfire there drops; based on this and presumably other factors I don't understand, the RSAC assigns a confidence number to each detection.

At high zoom levels, detections are represented as a circle with additional information.  The X and Y dimensions of the MODIS pixel are averaged to get the circle's radius, so the circle shows approximate coverage size.  The detection date - which may be later than when the hotspot actually started - is shown in Mountain Daylight Time (MDT), regardless of actual timezone.  Temperature and confidence are given on the next line, followed by the satellite that made the detection and the center that processed it (RSAC or GSFC, for the Goddard Space Flight Center).

Another data source I'm pulling in is smoke polygons from NOAA's Office of Satellite and Product Operations.  Color (gray->black) represents smoke severity, while crosshatching is used for current smoke and empty polygons show where the smoke was several hours previously.

The final source is large fire perimeters from GeoMAC.  Unlike the previous two products, which are based on satellite data, fire perimeters are manually reported by an incident's management team.  As a result, they seem slow to update and I'm on the hunt for a more reliable source.  In the meantime, I'm marking perimeters with the last date at which they were updated, in addition to the incident name, so that you know how recent/reliable the data is:

Because fire season is just ramping up, I haven't had the opportunity to test this layer as thoroughly as I'd like.  Normally I wouldn't add it to CalTopo until I'd had the chance to vet it more thoroughly, but since the MODIS layer already on the site was still having issues, it made sense to sub this in as quickly as possible.  Expect things to change, and please send me any feedback or bug reports.