[SoC] Integrating ZOO-Services with QGIS - FInal Report

Sandeepan Dhoundiyal dsandeepan995 at gmail.com
Mon Sep 12 11:58:57 PDT 2022


1. Title and software community:Title: Integrating ZOO-Services with QGIS.
Software Community: OSGeo Foundation Incubation Project - ZOO-Project
2. Abstract

The ZOO-Project is an open-source implementation of the OGC's (Open
Geospatial Consortium) Web Processing Service (WPS) standard. It provides
ready-to-use services implemented in C and Python. These services are based
on open source libraries and are compliant with OGC standards, with minor
modifications in their source code. Before GSoC, the available services
were those based on Geospatial Data Abstraction Library (GDAL),
Computational Geometry Algorithms Library (CGAL), the Orfeo Toolbox and
GRASS GIS. This GSoC focused on expanding the services available in the
ZOO-project by incorporating tools from QGIS as first-citizen services of
the ZOO-project. This goal was achieved by developing a bridge connecting
the QGIS processing toolbox to the ZOO-project. Three processing tools:
affine transforms, estimating centroids of geometries, and topological
colouring were incorporated as services. Comprehensive descriptions and
python implementations of other tools were also created, which can be
incorporated as ZOO-services. Finally, the bridge implemented during this
GSoC can be used to incorporate any of the over 300 tools of the QGIS
processing toolbox as native services of the ZOO-Project.
<https://github.com/sdhoundiyal/GSoC_ZOO-Project/wiki/Final-Report#2-state-of-the-art-before-gsoc>3.
State of the art Before GSoC:

The ZOO-Project provides ready-to-use services implemented in C and Python.
These services are based on open source libraries and are compliant with
OGC standards, with minor modifications in their source code.

These services are:
<https://github.com/sdhoundiyal/GSoC_ZOO-Project/wiki/Final-Report#21-based-on-gdal>3.1
Based on GDAL

GDAL (Geospatial Data Abstraction Library) is an open-source library for
handling basic raster and vector geospatial data formats, translating
between them, and performing basic geospatial processing. Documentation for
the GDAL implementation of these services and other methods can be found
here <https://gdal.org/programs/index.html>.

Table 1: GDAL based ZOO-services
Service Description
Gdal_Contour Builds vector contour lines from a raster elevation model
Gdal_Grid Creates regular raster grid front the scattered data read from an
OGR data source
Gdal_Dem Tools for the analysis of raster elevation models
Gdal_Ndvi Calculates Normalized Difference Vegetation Index on a raster
file.
Gdal_profile Fetches the elevation profile of a raster DEM in the form of
XYZ values along a straight line
Gdal_translate Converts raster data between different formats
Gdal_Warp Mosaics, reprojects or warps raster images
Ogr2Ogr Converts vector data between different formats
Base-vect-ops Tools for spatial analysis of single and multiple vector
geometries
<https://github.com/sdhoundiyal/GSoC_ZOO-Project/wiki/Final-Report#22-based-on-cgal>3.2
Based on CGAL

CGAL (Computational Geometry Algorithms Library) is a C++ implementation of
a collection of geometric algorithms, addressing needs in areas such as GIS
(Geographic Information Systems), CAD (Computer-Aided Design), molecular
biology, medical imaging, computer graphics, and robotics.

Table 2: CGAL based ZOO-services
Service Description
Cgal_Delaunay Computes edges of Delaunay triangulation given a set of data
points. Documentation for the CGAL implementation can be found here
<https://doc.cgal.org/latest/Manual/packages.html#PartTriangulationsAndDelaunayTriangulations>
.
Cgal_Voronoi Computes edges of a Voronoi Polygon given a set of data
points. Documentation for the CGAL implementation can be found here
<https://doc.cgal.org/latest/Manual/packages.html#PartVoronoiDiagrams>.
<https://github.com/sdhoundiyal/GSoC_ZOO-Project/wiki/Final-Report#23-based-on-grass-gis>3.3
Based on GRASS GIS

GRASS(Geographic Resources Analysis Support System) GIS is a C++ based
platform for processing, modelling, visualizing and managing geospatial
data. In the past the wps-grass-bridge library of the ZOO-Project allowed
GRASS GIS 7 modules to be used as ZOO-Services. However, programmes
introduced in subsequent releases of GRASS GIS are not supported as
ZOO-Services. Documentation for GRASS 8 can be found here
<https://grass.osgeo.org/grass80/manuals/index.html>.
<https://github.com/sdhoundiyal/GSoC_ZOO-Project/wiki/Final-Report#24-based-on-orfeo-toolbox>3.4
Based on Orfeo Toolbox

The OrfeoToolbox is a collection of tools for processing remote sensing
data. Use-cases include ortho-rectification, pan-sharpening,
classification, SAR processing. Similar to GRASS GIS, Orfeo Toolbox
Applications can be used as ZOO-Services without any modification using the
Orfeo Toolbox support. Documentation for the Orfeo Toolbox applications can
be found here <https://www.orfeo-toolbox.org/CookBook/Applications.html>.

Fig. 3.1: The overview of the ZOO-project before GSoC, Natively supported
services are shown in green. Deprecated services (GRASS GIS-based) are
shown in red.
<https://github.com/sdhoundiyal/GSoC_ZOO-Project/wiki/Final-Report#3-additions-made-to-the-zoo-project-during-gsoc>4.
Additions made to the ZOO-Project during GSOC

During this GSoC, the ZOO-services were expanded to include those based on
QGIS. This was done by developing a bridge connecting the QGIS processing
toolbox to the ZOO-Project. Three services: affine transforms, estimating
centroids of geometries, and topological colouring, were added to the
ZOO-Services.

Additional services were partially implemented

4.1. Kernel density estimation.

4.2. Sampling Points inside polygons.

4.3. Random selection of features.



<https://github.com/sdhoundiyal/GSoC_ZOO-Project/wiki/Final-Report#4-work-still-to-be-done>5.
Work still to be done

Two tasks were undertaken but could not be completed during this time
period. These are:

5.1 An example web page for the services added during the GSoC:- Each of
the existing set of Zoo-services has a sample web page containing examples
of the ZOO-services. One of the goals of this GSoC was to implement a
similar example for QGIS-based services. However, this could not be
finished in time.

5.2 Removing the need for manual intervention during setup:- Currently,
connecting the QGIS processing toolbox to the ZOO-project requires the user
to execute a script in the QGIS python console. This process could not be
automated during the summer.
<https://github.com/sdhoundiyal/GSoC_ZOO-Project/wiki/Final-Report#5-further-details>6.
Permanent links
The code is hosted in this repository
<https://github.com/sdhoundiyal/GSoC_ZOO-Project/tree/gsoc22>.

The Slide stack presented at FOSS4G is linked here
<https://docs.google.com/presentation/d/1jAQBz7KqZCa8EGSjXJSQmPRobsVU_4nm-J4Jm8SmjbQ/edit?usp=sharing>
.

Further details on how to setup the environment and a guide to the code
written during the GSOC can be found at this wiki page
<https://github.com/sdhoundiyal/GSoC_ZOO-Project/wiki/Guide-to-the-added-Code>


<https://github.com/sdhoundiyal/GSoC_ZOO-Project/wiki/Final-Report#5-further-details>7.
Graphical abstract

Fig. 7.1: The overview of the ZOO-project after the GSoC, The QGIS-based
services (shown in blue) were added to the ZOO-services.

Fig. 7.2: Outputs of three implemented services for the Indian state of
Uttar Pradesh. The input (green), centroids of the districts (black circles
with dots), affine transformed boundaries (red), and topologically
colouring (below) are shown in the following figure.

Regards,
Sandeepan Dhoundiyal.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/soc/attachments/20220913/501c375d/attachment.htm>


More information about the SoC mailing list