Hot answers tagged

11

You can convert OSM XML to GeoJson with ogr2ogr. To convert to GeoJSON without getting the following error: ERROR 6: GeoJSON driver doesn't support creating more than one layer You can use one of the following commands or all of them: ogr2ogr -f GeoJSON points.json data.osm.pbf points ogr2ogr -f GeoJSON lines.json data.osm.pbf lines ogr2ogr -f GeoJSON ...


10

The development (as march 2013) version of gdal has read support for OSM, both for plain XML and PBF format. So you can convert your OSM file with: ogr2ogr -f GeoJSON myfile.geojson myfile.osm.pbf


9

Are the xml files *.aux.xml? If so, it's not QGIS creating them, it's the GDAL library which uses them to store metadata, including statistics. You can disable completely by setting the environment variable GDAL_PAM_ENABLED=NO though I don't advise this if you'll be displaying the rasters again as there won't be any statistics cached. Instead, you can ...


9

Your best bet is to use InkScape and convert your graphics to SVG. Polygons can be filled with rasters, but points and markers need SVG. If your symbol is available in a font, you can also use Font markers. It's fairly straightforward:- Load bitmap (png, jpg etc) into Inkscape with File > Open File > Save as (use Plain SVG rather than default Inkscape SVG) ...


8

osmtogeojson is yet another OSM-to-GeoJSON converter, which has a few benefits when compared to this (OSM2GEO) or osm-and-geojson: can be used as a command line tool as well as a javascript (browser and nodejs) library. proper multipolygon support sophisticated polygon detection stable (can cope with incomplete OSM data) well tested faster The library ...


8

Data needs to located in a geodatabase in order to export to XML. You can do this manually, or use the tool Export XML Workspace Document (Data Management). For the manual approach, simply right-click the featureclass or raster dataset within the file geodatabase > Export > XML Workspace Document. Which then brings up the following GUI, where you can ...


7

For those who will stumble on this question like me.. It appears that the plugin has been generated (https://github.com/strk/mapnik/tree/2.3.x-pgraster) and has been merged in official Mapnik Repo. The branch is 2.3.x (https://github.com/mapnik/mapnik/tree/2.3.x) Now you can build Mapnik from the branch and use PGRaster plugin to use Raster data from ...


7

Here's what we've been doing to set up THREDDS Data Server (TDS) catalogs for regional oceanographic modeling providers in the US Integrated Ocean Observing System to serve their models results. There are four basic types of catalogs we have been setting up: A top level catalog that points to other catalogs that you want exposed An "all" catalog that ...


7

Business rules vs data integrity rules When you model your database, you specify the business logic in two spaces: a. The data integrity rules. This includes among others having an integer column so users won't be able to enter strings. b. The business domain rules. This includes having check/unique/foreign key constraints on columns so it won't be ...


7

The .xml file is the metadata file. An XML/metadata file is not a compulsory file needed to form shapefiles. The minimum files needed are: .shp — shape format; the feature geometry itself .shx — shape index format; a positional index of the feature geometry to allow seeking forwards and backwards quickly .dbf — attribute format; columnar ...


6

I enjoy using ElementTree. It's standardized in Python since 2.5 as xml.etree.ElementTree. Forgive me for being blunt, but you're using it wrong. I suggest trying the find, findtext, and findall methods when you know the structure of the data. Is Order your root element? If so, >>> geography = rootElement.find('OrderRequest/SiteGeography') >>...


6

Instead of getting the dataset: // Retrieve the first feature dataset from the workspace. IEnumDatasetName enumDatasetName = workspace.get_DatasetNames (esriDatasetType.esriDTFeatureDataset); You can get the feature class by: IEnumDatasetName enumDatasetName = workspace.get_DatasetNames(esriDatasetType.esriDTFeatureClass); See this thread: Exporting/...


6

Functions in rgdal read data into sp class objects, which can only contain one type of spatial object - a set of points, or lines, or polygons. The sf package provides classes for geometry vectors that can have different dimensions geometries within. Using sf::st_read("file.kml") should return an object with a geometry column, and you can filter lines or ...


5

If you are comfortable with Python, you could use ElementTree to parse the XML and pyshp to create the shapefile. Here is something you can start with: from xml.etree import ElementTree import shapefile import os xml_file = 'input.xml' shape_file = 'output.shp' projection = 'GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298....


5

There is a service that allows you to retrieve any administrative border from OpenStreetMap in a number of formats. https://osm.wno-edv-service.de/boundaries/


5

You have to unzip Qgz file first. Then you can edit the qgs file with any text editor.


5

You can use rasterio for getting geo-coordinates from pixel coordinates, and pyshp (shapefile) for creating a shapefile. import rasterio import shapefile # -> pyshp module import xml.etree.ElementTree as ET # get pixel coordinates from XML root = ET.parse('/path/to/file.xml').getroot() xmin = float(root.findall('object/bndbox/xmin')[0].text) ymin = float(...


4

ArcGIS xml is not a valid data source for QGIS and so you can't import or export it. KML, a variety of xml, is. My thought is to use Python to parse your xml into kml(s) files. QGIS GDAL/OGR could convert that to whatever you like, for instance Spatialite or PostGIS.


4

If you are at 10.1, try using the Export XML Workspace Document (Data Management) geoprocessing tool. I'm not sure exactly what it will do if you specify a feature class that participates in a relationship class, but I imagine it will include the relationship class and related object classes as well.


4

First off, I have not tried using Config.esriaddinx for this purpose, but I wouldn't recommend it. It is meant for the configuration of the add-in itself, not necessarily user data, and you probably don't want to mix the two. It has been a while since I've dealt with this myself so I may be a little fuzzy on the details, but there are multiple issues with ...


4

My solution was go to option server state -> reload and that is all.


4

The thing here is that you have given the example of amenity = school tag, but you are actually querying building = school. It is normal for buildings inside school to be tagged as building = yes, hence the query will not return them. In the second query, the format of bbox-query should be like below. <bbox-query e="7.25" n="50.8" s="50.7" w="7.1"/> ...


4

You can certainly use FME to wrangle the XML and write it to a database. Something for you to understand first is that GIS like flat data with rows and columns, including geometry. XML is not flat, it is a (maybe big) hierarchical tree, which is a fundamentally different data model than most GIS formats. That said, you can parse the XML and extract all the ...


4

I think your issue has been addressed here. As given in the second paragraph, For example, if the metadata describes the item as having one projection but the item's projection has changed since the last automatic update, the old projection information in the metadata will be replaced with the new projection information. Basically geoprocessing tools are ...


4

You can add this statement SET XML OPTION DOCUMENT; at the beginning of the SQL backup file. Source : https://hub.qgis.org/issues/10079


4

Your task to connect the house number automatically to the street name will surely fail in many cases. Just imagine a street crossing with four different named streets, where the house number could be related to any of them. The only working way is to add the full adress information to the house number during editig, using the Karlsruher Schema. The ...


4

As far as i know there is no such tool, as the last comment in your Linked Question mentioned. The problem with xml is that it is extensible... It means anyone can create a new schema or alter an existing one. Its a hierarchical document type with lots of possiblities to use different attributes and so on. When you want to change a schema you need to ...


4

XML files can hold any kind of data. If a software like QGIS should be able to read it, the software (or the developer) needs to know the XML schema of the data. QGIS is able to read Openstreetmap XML data, and (with the LandXML plugin) data provided by Land Information New Zealand. If you need support for other XML sources, you might have to do it on your ...


4

I have some comments/suggestions for you. You mention that you do not have any admin privileges on your machine to be able to install the metadata module. Good news here, you don't need admin to install python packages/modules. You do if you're using a binary install, however, most modules can be installed using pip. You can just download pip and put it ...


4

GPX files use XML namespaces (look at Parsing XML with namespace in Python via 'ElementTree' or Read GPX using Python ElementTree.register_namespace? for example). The namespace is {http://www.topografix.com/GPX/1/1} import xml.etree.ElementTree as ET tree = ET.parse("St_Louis_Zoo_sample.gpx") for elem in tree.findall("{http://www.topografix.com/GPX/1/1}...


Only top voted, non community-wiki answers of a minimum length are eligible