[Git][debian-gis-team/python-pdal][master] 8 commits: New upstream version 2.1.0~rc2+ds
Bas Couwenberg
gitlab at salsa.debian.org
Thu Nov 1 13:50:35 GMT 2018
Bas Couwenberg pushed to branch master at Debian GIS Project / python-pdal
Commits:
c5eeda18 by Bas Couwenberg at 2018-10-31T21:30:42Z
New upstream version 2.1.0~rc2+ds
- - - - -
5890dff6 by Bas Couwenberg at 2018-10-31T21:30:48Z
Merge tag 'upstream/2.1.0_rc2+ds'
Upstream version 2.1.0~rc2+ds
- - - - -
22bb5c12 by Bas Couwenberg at 2018-10-31T21:31:12Z
New upstream release candidate.
- - - - -
f6d12f36 by Bas Couwenberg at 2018-11-01T05:34:58Z
Add patch to fix test_merged_arrays.
- - - - -
8ce7620c by Bas Couwenberg at 2018-11-01T13:23:00Z
New upstream version 2.1.0~rc3+ds
- - - - -
f99d0f90 by Bas Couwenberg at 2018-11-01T13:23:02Z
Merge tag 'upstream/2.1.0_rc3+ds'
Upstream version 2.1.0~rc3+ds
- - - - -
9ffcdf31 by Bas Couwenberg at 2018-11-01T13:23:40Z
New upstream release candidate.
- - - - -
20310874 by Bas Couwenberg at 2018-11-01T13:26:28Z
Drop test_pipeline.patch, applied upstream.
- - - - -
9 changed files:
- PKG-INFO
- VERSION.txt
- debian/changelog
- pdal/PyPipeline.cpp
- pdal/__init__.py
- pdal/libpdalpython.cpp
- pdal/libpdalpython.pyx
- setup.py
- test/test_pipeline.py
Changes:
=====================================
PKG-INFO
=====================================
@@ -1,6 +1,6 @@
Metadata-Version: 1.2
Name: PDAL
-Version: 2.1.0rc1
+Version: 2.1.0rc3
Summary: Point cloud data processing
Home-page: http://pdal.io
Author: Howard Butler
=====================================
VERSION.txt
=====================================
@@ -1 +1 @@
-2.1.0rc1
\ No newline at end of file
+2.1.0rc3
\ No newline at end of file
=====================================
debian/changelog
=====================================
@@ -1,4 +1,4 @@
-python-pdal (2.1.0~rc1+ds-1) UNRELEASED; urgency=medium
+python-pdal (2.1.0~rc3+ds-1) UNRELEASED; urgency=medium
* New upstream release candidate.
* Bump Standards-Version to 4.2.1, no changes.
@@ -8,7 +8,7 @@ python-pdal (2.1.0~rc1+ds-1) UNRELEASED; urgency=medium
* Remove package name from lintian overrides.
* Require at least libpdal-dev 1.8~ and its python plugin.
- -- Bas Couwenberg <sebastic at debian.org> Wed, 31 Oct 2018 17:52:12 +0100
+ -- Bas Couwenberg <sebastic at debian.org> Thu, 01 Nov 2018 14:23:07 +0100
python-pdal (2.0.0+ds-2) unstable; urgency=medium
=====================================
pdal/PyPipeline.cpp
=====================================
@@ -47,6 +47,7 @@
#include "PyArray.hpp"
#include <pdal/Stage.hpp>
+#include <pdal/pdal_features.hpp>
#include <pdal/PipelineWriter.hpp>
#include <pdal/io/NumpyReader.hpp>
@@ -78,6 +79,7 @@ Pipeline::Pipeline(std::string const& json, std::vector<Array*> arrays)
if (!r)
throw pdal::pdal_error("pipeline had no stages!");
+#if PDAL_VERSION_MAJOR > 1 || PDAL_VERSION_MINOR >=8
int counter = 1;
for (auto array: arrays)
{
@@ -102,6 +104,7 @@ Pipeline::Pipeline(std::string const& json, std::vector<Array*> arrays)
counter++;
}
+#endif
manager.validateStageOptions();
}
=====================================
pdal/__init__.py
=====================================
@@ -1,5 +1,18 @@
-__version__='2.1.0rc1'
+__version__='2.1.0rc3'
from .pipeline import Pipeline
from .array import Array
from .dimension import dimensions
+
+from pdal.libpdalpython import getVersionString, getVersionMajor, getVersionMinor, getVersionPatch, getSha1, getDebugInformation, getPluginInstallPath
+
+class Info(object):
+ version = getVersionString()
+ major = getVersionMajor()
+ minor = getVersionMinor()
+ patch = getVersionPatch()
+ debug = getDebugInformation()
+ sha1 = getSha1()
+ plugin = getPluginInstallPath()
+
+info = Info()
=====================================
pdal/libpdalpython.cpp
=====================================
The diff for this file was not included because it is too large.
=====================================
pdal/libpdalpython.pyx
=====================================
@@ -12,6 +12,30 @@ np.import_array()
from cpython cimport PyObject, Py_INCREF
from cython.operator cimport dereference as deref, preincrement as inc
+cdef extern from "pdal/pdal_config.hpp" namespace "pdal::Config":
+ cdef int versionMajor() except +
+ cdef int versionMinor() except +
+ cdef int versionPatch() except +
+ cdef string sha1() except+
+ cdef string debugInformation() except+
+ cdef string pluginInstallPath() except+
+ cdef string versionString() except+
+
+def getVersionString():
+ return versionString()
+
+def getVersionMajor():
+ return versionMajor()
+def getVersionMinor():
+ return versionMinor()
+def getVersionPatch():
+ return versionPatch()
+def getSha1():
+ return sha1()
+def getDebugInformation():
+ return debugInformation()
+def getPluginInstallPath():
+ return pluginInstallPath()
cdef extern from "PyArray.hpp" namespace "pdal::python":
cdef cppclass Array:
@@ -32,6 +56,8 @@ cdef extern from "PyPipeline.hpp" namespace "libpdalpython":
int getLogLevel()
void setLogLevel(int)
+
+
cdef class PyArray:
cdef Array *thisptr
def __cinit__(self, object array):
=====================================
setup.py
=====================================
@@ -108,13 +108,9 @@ libraries = []
extra_link_args = []
extra_compile_args = []
-if os.name in ['nt']:
- library_dirs = ['c:/OSGeo4W64/lib']
- libraries = ['pdalcpp','pdal_plugin_reader_numpy','pdal_util','ws2_32']
- extra_compile_args = ['/DNOMINMAX',]
-
from setuptools.extension import Extension as DistutilsExtension
+PDALVERSION = None
if pdal_config and "clean" not in sys.argv:
# Collect other options from PDAL
try:
@@ -134,6 +130,7 @@ if pdal_config and "clean" not in sys.argv:
# older versions of pdal-config do not include --python-version switch
except ValueError:
pass
+ PDALVERSION = Version(get_pdal_config('--version'))
separator = ':'
if os.name in ['nt']:
@@ -162,7 +159,19 @@ if DEBUG:
if os.name != 'nt':
extra_compile_args += ['-g','-O0']
-libraries.append('pdal_plugin_reader_numpy')
+if os.name in ['nt']:
+ if os.environ['OSGEO4W_ROOT']:
+ library_dirs = ['c:/OSGeo4W64/lib']
+ libraries = ['pdalcpp','pdal_util','ws2_32']
+ if PDALVERSION >= Version('1.8'):
+ libraries.append('pdal_plugin_reader_numpy')
+ extra_compile_args = ['/DNOMINMAX',]
+
+
+# readers.numpy doesn't exist until PDAL 1.8
+if PDALVERSION >= Version('1.8'):
+ libraries.append('pdal_plugin_reader_numpy')
+
sources=['pdal/libpdalpython'+ext, "pdal/PyPipeline.cpp" ]
extensions = [DistutilsExtension("*",
sources,
=====================================
test/test_pipeline.py
=====================================
@@ -2,6 +2,7 @@ import unittest
import pdal
import os
import numpy as np
+from packaging.version import Version
DATADIRECTORY = "./test/data"
@@ -127,8 +128,12 @@ class TestPipeline(PDALTest):
#
class TestArrayLoad(PDALTest):
+ @unittest.skipUnless(os.path.exists(os.path.join(DATADIRECTORY, 'perlin.npy')),
+ "missing test data")
def test_merged_arrays(self):
"""Can we load data from a a list of arrays to PDAL"""
+ if Version(pdal.info.version) < Version('1.8'):
+ return True
data = np.load(os.path.join(DATADIRECTORY, 'perlin.npy'))
arrays = [data, data, data]
@@ -157,7 +162,10 @@ class TestDimensions(PDALTest):
def test_fetch_dimensions(self):
"""Ask PDAL for its valid dimensions list"""
dims = pdal.dimensions
- self.assertEqual(len(dims), 72)
+ if Version(pdal.info.version) < Version('1.8'):
+ self.assertEqual(len(dims), 71)
+ else:
+ self.assertEqual(len(dims), 72)
def test_suite():
return unittest.TestSuite(
View it on GitLab: https://salsa.debian.org/debian-gis-team/python-pdal/compare/9dd2013da6bb3dba88ba04e0678d06e8850e148e...20310874307fea3c028fc590616eb693ed11022c
--
View it on GitLab: https://salsa.debian.org/debian-gis-team/python-pdal/compare/9dd2013da6bb3dba88ba04e0678d06e8850e148e...20310874307fea3c028fc590616eb693ed11022c
You're receiving this email because of your account on salsa.debian.org.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://alioth-lists.debian.net/pipermail/pkg-grass-devel/attachments/20181101/24b5a3fa/attachment-0001.html>
More information about the Pkg-grass-devel
mailing list