Information for Geospatial Developers and Data Scientists

Useful technical information for accessing ODIMS data.

ODIMS Software

All the code that runs ODIMS is based on Django and Python, with REST API  accessibility. Geoserver and Geoportal provide the OGC mapping and metadata webservices respectively.

What are OGC Services?

The data in this application is served using open standards endorsed by the Open Geospatial Consortium; in particular, WMS (Web Map Service) is used for accessing maps, WFS (Web Feature Service) is used for accessing vector data, and WCS (Web Coverage Service) is used for accessing raster data. WMC (Web Map Context Documents) is used for sharing maps. You can use these services in your own applications using libraries such as Leaflet, GeoTools, and OGR (all of which are open-source software and available at zero cost).

What is GeoWebCache?

GeoWebCache provides mapping tiles that are compatible with a number of mapping engines, including Google Maps, Bing Maps and OpenLayers. All the data hosted by ODIMS is also available through GeoWebCache. GeoWebCache improves on WMS by caching data and providing more responsive maps.

CSW Example Code

To interact with ODIMS's CSW you can use any CSW client (QGIS MetaSearch, GRASS, etc.). The following example illustrates a simple invocation using the OWSLib Python package:

from owslib.csw import CatalogueServiceWeb

from owslib.fes import PropertyIsLike

csw = CatalogueServiceWeb('https://odims.ospar.org/geoportal/csw')

anytext = PropertyIsLike('csw:AnyText', 'fish')')

csw.getrecords2(constraints=[anytext])

print csw.results

print csw.records

OpenLayers Example Code

To include a ODIMS map layer in an OpenLayers map, first find the name for that layer. This is found in the layer's namefield (nottitle) of the layer list. For this example we will use odims:ospar_seawater_2012_01_001. Then, create an instance of OpenLayers.Layer.WMS:

var odimsLayer = new OpenLayers.Layer.WMS("ODIMS Data", "https://odims.ospar.org/geoserver/wms",{ layers: "odims:ospar_seawater_2012_01_001" });

Shapefile/GeoJSON/GML Output

To get data from the ODIMS web services use the WFS or WMS protocols. Each Submission and Map lists the available source formats and types for WMS or WFS download data types.

https://odims.ospar.org/geoserver/wfs?request=GetFeature&typeName=odims:ospar_seawater_2012_01_001&outputformat=SHAPE-ZIP

Changing output format to jsonGML2GML3, or csv will get data in those formats. The WFS protocol also can handle more precise queries, specifying a bounding box or various spatial and non-spatial filters based on the attributes of the data.