Example of MetPX plugin integration in a Python 3 virtualenv.
python3 -m venv bulletins_es_test
cd bulletins_es_test
. bin/activate
pip install elasticsearch
sr_subscribe --version # Version 2.18.11b6
sr_subscribe bulletins.conf foreground
Example of MetPX plugin integration in a Python 3 virtualenv.
python3 -m venv bulletins_es_test
cd bulletins_es_test
. bin/activate
pip install elasticsearch
sr_subscribe --version # Version 2.18.11b6
sr_subscribe bulletins.conf foreground
import unicodecsv as csv | |
import sys | |
import polib | |
def po2csv(po_file): | |
po = polib.pofile(po_file) | |
with open('messages.csv', 'wb') as csvfile: | |
writer = csv.writer(csvfile) |
#! /bin/sh | |
# /etc/init.d/pygeoapi | |
PROGRAMNAME=pygeoapi | |
check_service() { | |
ps cax | grep $PROGRAMNAME > /dev/null | |
if [ $? -eq 0 ]; then | |
return 0 | |
else |
# load https://aws.amazon.com/public-datasets/landsat/ scene_list into ES index | |
import csv | |
from datetime import datetime | |
import json | |
from elasticsearch import Elasticsearch | |
index_name = 'landsat-aws' | |
type_name = 'FeatureCollection' |
Minimal exmaple as per http://osgeo-org.1560.x6.nabble.com/Use-extra-columns-in-pycsw-admin-setup-db-td5323610.html
# ensure column exists in database table
<?xml version="1.0" encoding="UTF-8"?> | |
<che:CHE_MD_Metadata xmlns:che="http://www.geocat.ch/2008/che" xmlns:srv="http://www.isotc211.org/2005/srv" xmlns:gco="http://www.isotc211.org/2005/gco" xmlns:gml="http://www.opengis.net/gml" xmlns:gmd="http://www.isotc211.org/2005/gmd" xmlns:geonet="http://www.fao.org/geonetwork" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" gco:isoType="gmd:MD_Metadata" xsi:schemaLocation="http://www.geocat.ch/2008/che http://www.isotc211.org/2005/gmd http://www.isotc211.org/2005/gmd/gmd.xsd http://www.isotc211.org/2005/srv http://schemas.opengis.net/iso/19139/20060504/srv/srv.xsd"> | |
<gmd:fileIdentifier> | |
<gco:CharacterString>8698bf0b-fceb-4f0f-989b-111e7c4af0a4</gco:CharacterString> | |
</gmd:fileIdentifier> | |
<gmd:language xmlns:comp="http://www.geocat.ch/2003/05/gateway/GM03Comprehensive" xmlns:xalan="http://xml.apache.org/xalan"> | |
<gco:CharacterString>ger</gco:CharacterString> | |
</gmd:language> | |
<gmd:characterSet xmlns:comp="http://www.geocat.ch/2003/05/gateway/GM03Co |
#-*- coding: utf-8 -*- | |
# set pycsw configuration like: | |
# [repository] | |
# source=ogr_repository.OGRRepository | |
from pycsw.core.repository import Repository | |
class OGRRepository(Repository): | |
''' Class to interact with underlying repository ''' |
<?xml version="1.0" encoding="UTF-8"?> | |
<GetRecords | |
service="CSW" | |
version="3.0.0" | |
maxRecords="5" | |
startPosition="1" | |
outputFormat="application/xml" | |
outputSchema="http://www.opengis.net/cat/csw/3.0" | |
xmlns="http://www.opengis.net/cat/csw/3.0" | |
xmlns:csw="http://www.opengis.net/cat/csw/2.0.2" |
Please post questions to the $PROJECT
mailing list.
$PROJECT
's GitHub issues are for software bugs/enhancements and related tasks.
GDAL has some limitation concerning the reading of netCDF4 files.
Most of the tests were done on a personal computer using QGIS 2.12.1 and GDAL 1.11.3.