Skip to content
Commits on Source (8)
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
......
2.1.0rc1
\ No newline at end of file
2.1.0rc3
\ No newline at end of file
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@debian.org> Wed, 31 Oct 2018 17:52:12 +0100
-- Bas Couwenberg <sebastic@debian.org> Thu, 01 Nov 2018 14:23:07 +0100
python-pdal (2.0.0+ds-2) unstable; urgency=medium
......
......@@ -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();
}
......
__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()
This diff is collapsed.
......@@ -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):
......
......@@ -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']
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,
......
......@@ -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,6 +162,9 @@ class TestDimensions(PDALTest):
def test_fetch_dimensions(self):
"""Ask PDAL for its valid dimensions list"""
dims = pdal.dimensions
if Version(pdal.info.version) < Version('1.8'):
self.assertEqual(len(dims), 71)
else:
self.assertEqual(len(dims), 72)
def test_suite():
......