© University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map...

25
June 21, 2022 © University of Reading 2008 www.reading.ac.uk Reading e-Science Centre Integrating a Web Map Service into the THREDDS Data Server Jon Blower, University of Reading, UK Pauline Mak, University of Tasmania, Australia Ethan Davis, John Caron, Unidata

Transcript of © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map...

Page 1: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

April 21, 2023 © University of Reading 2008 www.reading.ac.uk

Reading e-Science CentreIntegrating a Web Map Service into the THREDDS Data ServerJon Blower, University of Reading, UKPauline Mak, University of Tasmania, AustraliaEthan Davis, John Caron, Unidata

Page 2: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Motivation• THREDDS is a very popular system for sharing environmental

data– Catalogue– Data access via OPeNDAP

• However, client-side tools are required for visualization– Not easy to use by people outside “our” community

• Web Map Service provides quick route to visualization– Produces georeferenced images– Images can be overlain to compare data– Very suitable for Web-GIS (low barrier to entry to users)

• Use of WMS mandated in Europe by INSPIRE directive– THREDDS already used by data providers

• WMS for NetCDF data already exists (http://ncwms.sf.net)– Both TDS and ncWMS are Java-based

• Hence we aim to integrate ncWMS with TDS

Page 3: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Web Map Service: a closer look

• GetCapabilities -> metadata

• GetMap -> map image, based on client-selected parameters, inc:– Image width/height– Image coordinate reference system– Geographic bounding box– Depth/height and time– Style

• GetFeatureInfo -> information about a particular map pixel– Format not standardized

• Specification supports 4D data– (Although tools often do not)

Page 4: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

WMS Interoperability

NASA World Wind

Cadcorp SIS

Google Earth

3rd-party clients can’t use the custom WMS extensions

Page 5: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Why ncWMS?

• Based on same technology as TDS– Esp. Java NetCDF libraries

• Significant effort put into fast image generation

• Extensions to WMS to support scientific use cases– But fully backward-compatible with WMS specification

Page 6: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

April 21, 2023 © University of Reading 2008 www.reading.ac.uk

Reading e-Science Centre

Scientific visualization using (nc)WMS

Page 7: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Notable features of ncWMS

• Fast generation of images

• Ability to read CF-NetCDF on variety of grids– inc. arbitrary grids and Murray tripolar

• Reproject images into large number of coordinate systems– E.g. polar stereographic

• Configuration via administrative web interface

Page 8: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Non-standard features• Piecemeal metadata-serving in JSON format

– avoids large XML Capabilities document

• Extra metadata for science data– e.g. units of measurement

• New parameters in GetMap for styling:– Choose colour palette– Set contrast range– Linear or logarithmic scaling– Far simpler than Styled Layer Descriptor

• Generation of timeseries plots via GetFeatureInfo

• … but fully backward-compatible with WMS1.1.1 and 1.3.0

Page 9: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Godiva2: a web client for ncWMS

• Interactively explore 4D geospatial raster datasets on the web

• ~40 datasets– Research data,

operational forecasts, satellite products

• Backed by ncWMS server

• OGC Website of the Month, January 2008

http://www.reading.ac.uk/godiva2

Page 10: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Selection of depth

Select from all the depth levels of the model

Page 11: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Selection of time (range)Select from all the timesteps in the model

Selection of a time range leads to an animation

Page 12: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Finding the data value at a point

Click on the data layer, data value and precise position is shown

Lon: -64.08 Lat: 36.21 Value: 19.27

Page 13: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Timeseries plots

If a time range is selected, can create a timeseries plot at a point

Page 14: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Vector plots

Page 15: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Selection of colour palette

Page 16: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Contrast-stretching

• Manual or automatic

Page 17: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Polar projections

Page 18: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Choice of background images

Page 19: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Export to Google Earth• Allows visualization of multiple

data sources

• Hurricane Katrina, August 2005

• Storm track positions (analysed from ECMWF vorticity data) by Lizzie Froude, ESSC

• Sea surface temperature data from UK Met Office FOAM model

• Combination shows cooling of surface waters on right-hand side of cyclonic storm track

• High winds cause upwelling of cool, deep water

Page 20: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Who’s using ncWMS/Godiva2?

• 100,000 GetMap requests served in 3 months– From 5 continents

• Customized versions of Godiva2 site set up for MERSEA and ECOOP projects– Major EU framework projects – INSPIRE compliance important!– Will be used in MyOcean

• UK National Centre for Ocean Forecasting

• Server software installed by:– Plymouth Marine Labs– AIMS, Australia– NOAA, US– USGS

• Code contributions from:– MeteoGalicia, Spain– TPAC, Tasmania– AIMS, Australia

Page 21: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

April 21, 2023 © University of Reading 2008 www.reading.ac.uk

Reading e-Science Centre

Case study:European operational oceanography

Page 22: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Current architecture as used inMERSEA and ECOOP projects

OPeNDAP(THREDDS)

NetCDF

DataProvider 1 OPeNDAP

(THREDDS)

NetCDF

OPeNDAP(THREDDS)

NetCDF

WMS

Dynamic Quick ViewWeb portal(rebranded Godiva2)

Data providers already use TDS and OPeNDAP

Requires minimal setup

Single point of failure

Relies on fast, reliable OPeNDAP servers

DataProvider 2

DataProvider 3

Page 23: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Improved architecture:Anticipated MyOcean deployment

NetCDF NetCDF NetCDF

THREDDS

WMS

OPeNDAP

WCS?

THREDDS

WMS

OPeNDAP

WCS?

THREDDS

WMS

OPeNDAP

WCS?

WMS bundled with THREDDS

Data providers install single piece of software

Page 24: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Technical challenges

• Merging Spring-based code (ncWMS) with servlet-based code (TDS)– Spring is fairly non-intrusive so not too hard to decouple– TDS moving toward Spring architecture– Spring cleanly separates internal logic from presentation

• Merging catalogue and configuration systems– TDS system is more scalable

• Changes to underlying Java-NetCDF libraries– Upgrade from version 2.2 to version 4

• Aligning all of this with THREDDS-WCS– Single point of configuration for WMS and WCS metadata

Page 25: © University of Reading 2008 Reading e-Science Centre September 10, 2015 Integrating a Web Map Service into the THREDDS Data Server Jon.

Conclusions• First prototype of TDS-WMS now developed• To do:

– Testing (inc. scalability)– Tidying-up and refactoring– Integration of logging and usage monitoring– Integration of administrative web pages

• Anticipated immediate use in major European project MyOcean

• (By the way - version 4.0 of Java NetCDF libs appear significantly faster than version 2.2!)