Re: [gdal-dev] ogr2ogr PROMOTE_TO_MULTI with linestrings?
On 5/15/2017 6:15 PM, Stephen Woodbridge wrote: Hi, I'm trying to load both polygons and linestrings and would like PROMOTE_TO_MULTI to work for both, but it appears to define Multipolygon type and does not work for linestrings/multilinestrings. Maybe it would make more sense to have: PROMOTE_TO_MULTI - work for either polygon or linestring depending on what the first object is or have two options like: PROMOTE_POLY_TO_MULTI PROMOTE_LINE_TO_MULTI Or maybe, I'm totally missing something in the docs. Sorry, forgot to add: ogrinfo --version GDAL 2.1.0, released 2016/04/25 ogr2ogr -t_srs EPSG:4326 -nln census.roads -nlt PROMOTE_TO_MULTI -f PostgreSQL -append PG:dbname=buildings host=localhost port=5432 user=postgres active_schema=census /u/ror/buildings/data/census/tmp-11/tl_2016_06061_roads.shp Warning 1: Geometry to be inserted is of type Multi Line String, whereas the layer geometry type is Multi Polygon. Insertion is likely to fail ERROR 1: ERROR: Geometry type (MultiLineString) does not match column type (MultiPolygon) --- This email has been checked for viruses by Avast antivirus software. https://www.avast.com/antivirus ___ gdal-dev mailing list gdal-dev@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/gdal-dev
[gdal-dev] GDAL build without big tiff support
Hi, it seem to me there is misprint here: https://github.com/OSGeo/gdal/blob/trunk/gdal/frmts/gtiff/geotiff.cpp#L16195 instead of > else if( nCompression == COMPRESSION_JPEG should be > else if( l_nCompression == COMPRESSION_JPEG Without this fix I get such error in build without BIG TIFF Support: error C2597: illegal reference to non-static member 'GTiffDataset::nCompression' -- Best regards, Dmitry ___ gdal-dev mailing list gdal-dev@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/gdal-dev
[gdal-dev] ogr2ogr PROMOTE_TO_MULTI with linestrings?
Hi, I'm trying to load both polygons and linestrings and would like PROMOTE_TO_MULTI to work for both, but it appears to define Multipolygon type and does not work for linestrings/multilinestrings. Maybe it would make more sense to have: PROMOTE_TO_MULTI - work for either polygon or linestring depending on what the first object is or have two options like: PROMOTE_POLY_TO_MULTI PROMOTE_LINE_TO_MULTI Or maybe, I'm totally missing something in the docs. -Steve --- This email has been checked for viruses by Avast antivirus software. https://www.avast.com/antivirus ___ gdal-dev mailing list gdal-dev@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/gdal-dev
[gdal-dev] Help with getting gdal python module working
Hi, I've managed to get GDAL 2.1.3 to build with ECW 5.3 support on my 64-bit system. The last hurdle I'm struggling with is getting the python module to install and work. The lines in my nmake.opt file relating to python are; !IFNDEF PYDIR PYDIR = "... \AppData\Local\Programs\Python\Python36" !ENDIF HAVE_NUMPY=1 But the python module does not install. I've tried going into the gdal-2.1.3\swig\python folder and installing manually with "python setup.py install", but when I try to import gdal in a script with "from osgeo import gdal" I get the error Traceback (most recent call last): File "...\AppData\Local\Programs\Python\Python36\lib\site-packages\IPython\core\interactiveshell.py", line 2881, in run_code exec(code_obj, self.user_global_ns, self.user_ns) File "", line 1, in from osgeo import gdal File "D:\Program Files (x86)\JetBrains\PyCharm Community Edition 2016.3.2\helpers\pydev\_pydev_bundle\pydev_import_hook.py", line 21, in do_import module = self._system_import(name, *args, **kwargs) File "...\Local\Programs\Python\Python36\lib\site-packages\gdal-2.1.3-py3.6-win-amd64.egg\osgeo\__init__.py", line 21, in _gdal = swig_import_helper() File "...\Local\Programs\Python\Python36\lib\site-packages\gdal-2.1.3-py3.6-win-amd64.egg\osgeo\__init__.py", line 17, in swig_import_helper _mod = imp.load_module('_gdal', fp, pathname, description) File "...\Local\Programs\Python\Python36\Lib\imp.py", line 242, in load_module return load_dynamic(name, filename, file) File "...\Local\Programs\Python\Python36\Lib\imp.py", line 342, in load_dynamic return _load(spec) ImportError: DLL load failed: The specified module could not be found. Which I'm assuming is because the GDAL scripts can't find the relevant GDAL dlls. Any idea on how to fix this ? Best regards, Liam. ___ gdal-dev mailing list gdal-dev@lists.osgeo.org https://lists.osgeo.org/mailman/listinfo/gdal-dev