File tree Expand file tree Collapse file tree 2 files changed +17
-42
lines changed
Expand file tree Collapse file tree 2 files changed +17
-42
lines changed Original file line number Diff line number Diff line change 1- from .libpdalpython import (
2- getDebugInformation ,
3- getDimensions ,
4- getPluginInstallPath ,
5- getSha1 ,
6- getVersionMajor ,
7- getVersionMinor ,
8- getVersionPatch ,
9- getVersionString ,
10- )
1+ from .libpdalpython import getDimensions , getInfo
112from .pipeline import Pipeline
123
13-
144__version__ = "2.4.2"
155
166dimensions = getDimensions ()
17- del getDimensions
18-
19-
20- class Info (object ):
21- version = getVersionString ()
22- major = getVersionMajor ()
23- minor = getVersionMinor ()
24- patch = getVersionPatch ()
25- debug = getDebugInformation ()
26- sha1 = getSha1 ()
27- plugin = getPluginInstallPath ()
28-
29-
30- info = Info ()
7+ info = getInfo ()
8+ del getDimensions , getInfo
Original file line number Diff line number Diff line change 33
44from libcpp.vector cimport vector
55from libcpp.string cimport string
6- from libc.stdint cimport uint32_t, int64_t
6+ from libc.stdint cimport int64_t
77from libcpp cimport bool
8- from cpython.version cimport PY_MAJOR_VERSION
8+ from types import SimpleNamespace
99cimport numpy as np
1010np.import_array()
1111
12- from cpython cimport PyObject, Py_INCREF
1312from cython.operator cimport dereference as deref, preincrement as inc
1413
1514cdef extern from " pdal/pdal_config.hpp" namespace " pdal::Config" :
@@ -21,20 +20,18 @@ cdef extern from "pdal/pdal_config.hpp" namespace "pdal::Config":
2120 cdef string pluginInstallPath() except +
2221 cdef string versionString() except +
2322
24- def getVersionString ():
25- return versionString()
26- def getVersionMajor ():
27- return versionMajor()
28- def getVersionMinor ():
29- return versionMinor()
30- def getVersionPatch ():
31- return versionPatch()
32- def getSha1 ():
33- return sha1()
34- def getDebugInformation ():
35- return debugInformation()
36- def getPluginInstallPath ():
37- return pluginInstallPath()
23+
24+ def getInfo ():
25+ return SimpleNamespace(
26+ version = versionString(),
27+ major = versionMajor(),
28+ minor = versionMinor(),
29+ patch = versionPatch(),
30+ debug = debugInformation(),
31+ sha1 = sha1(),
32+ plugin = pluginInstallPath(),
33+ )
34+
3835
3936cdef extern from " PyArray.hpp" namespace " pdal::python" :
4037 cdef cppclass Array:
You can’t perform that action at this time.
0 commit comments