read_evlrs (bool, default True) –
Only applies to ‘r’ mode.
│ │ │ If True the evlrs will be read during the __init__ / file opening
│ │ │ along with the LasHeader.
│ │ │ It is fine for most of the cases,
│ │ │ but can be problematic when opening file from a data stream like
│ │ │ AWS S3 as EVLRs are located at the end of the files, thus
│ │ │ will require to pull the whole file.
│ │ │ Does nothing if the input file does not support
│ │ │ @@ -254,15 +254,15 @@
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ laspy.create
│ │ │
│ │ │ -
│ │ │ -laspy.create(*, point_format: PointFormat | int | None = None, file_version: Version | str | None = None)
│ │ │ +laspy.create(*, point_format: PointFormat | int | None = None, file_version: Version | str | None = None)
│ │ │ Function to create a new empty las data object
│ │ │
│ │ │
Note
│ │ │
If you provide both point_format and file_version
│ │ │ an exception will be raised if they are not compatible
│ │ │
│ │ │ >>> las = create_las(point_format=6,file_version="1.2")
│ │ │ @@ -343,16 +343,16 @@
│ │ │ laspy.errors.LaspyException: Point format 6 is not compatible with file version 1.2
│ │ │
│ │ │
│ │ │
│ │ │ - Parameters:
│ │ │
│ │ │ source_las (laspy.lasdatas.base.LasBase) – The source data to be converted
│ │ │ -point_format_id (int, optional) – The new point format id (the default is None, which won’t change the source format id)
│ │ │ -file_version (str, optional,) – The new file version. None by default which means that the file_version
│ │ │ +
point_format_id (int, optional) – The new point format id (the default is None, which won’t change the source format id)
│ │ │ +file_version (str, optional,) – The new file version. None by default which means that the file_version
│ │ │ may be upgraded for compatibility with the new point_format. The file version will not
│ │ │ be downgraded.
│ │ │
│ │ │
│ │ │ - Return type:
│ │ │ laspy.lasdatas.base.LasBase
│ │ │
│ │ │ ├── html2text {}
│ │ │ │ @@ -50,31 +50,31 @@
│ │ │ │ || GGPPSS__TTIIMMEE || RRGGBB || NNIIRR || WWAAVVEEPPAACCKKEETT || AALLLL__EEXXTTRRAA__BBYYTTEESS)_
│ │ │ │ Entry point for reading las data in laspy
│ │ │ │ Reads the whole file into memory.
│ │ │ │ >>> las = read_las("tests/data/simple.las")
│ │ │ │ >>> las.classification
│ │ │ │
│ │ │ │ Parameters:
│ │ │ │ - * ssoouurrccee (_ss_tt_rr oorr _ii_oo_.._BB_yy_tt_ee_ss_II_OO) – The source to read data from
│ │ │ │ + * ssoouurrccee (ssttrr oorr iioo..BByytteessIIOO) – The source to read data from
│ │ │ │ * llaazz__bbaacckkeenndd (OOppttiioonnaall,, tthhee bbaacckkeenndd ttoo uussee wwhheenn tthhee ffiillee iiss aass
│ │ │ │ LLAAZZ ffiillee..) – By default laspy will find the backend to use by
│ │ │ │ itself. Use if you want a specific backend to be used
│ │ │ │ - * cclloosseeffdd (_bb_oo_oo_ll) – if True and the source is a stream, the
│ │ │ │ + * cclloosseeffdd (bbooooll) – if True and the source is a stream, the
│ │ │ │ function will close it after it is done reading
│ │ │ │ * ddeeccoommpprreessssiioonn__sseelleeccttiioonn (_DD_ee_cc_oo_mm_pp_rr_ee_ss_ss_ii_oo_nn_SS_ee_ll_ee_cc_tt_ii_oo_nn,,) – see
│ │ │ │ _l_a_s_p_y_._o_p_e_n_(_)
│ │ │ │ Returns:
│ │ │ │ The object you can interact with to get access to the LAS points &
│ │ │ │ VLRs
│ │ │ │ Return type:
│ │ │ │ laspy.LasData
│ │ │ │ New in version 2.4: The decompression_selection parameter.
│ │ │ │ ******** llaassppyy..ooppeenn_? ********
│ │ │ │ laspy.open(ssoouurrccee, mmooddee==''rr'', cclloosseeffdd==TTrruuee, llaazz__bbaacckkeenndd==NNoonnee, hheeaaddeerr==NNoonnee,
│ │ │ │ - ddoo__ccoommpprreessss==NNoonnee, eennccooddiinngg__eerrrroorrss:: _ss_tt_rr == ''ssttrriicctt'', rreeaadd__eevvllrrss:: _bb_oo_oo_ll == TTrruuee,
│ │ │ │ + ddoo__ccoommpprreessss==NNoonnee, eennccooddiinngg__eerrrroorrss:: ssttrr == ''ssttrriicctt'', rreeaadd__eevvllrrss:: bbooooll == TTrruuee,
│ │ │ │ ddeeccoommpprreessssiioonn__sseelleeccttiioonn:: _DD_ee_cc_oo_mm_pp_rr_ee_ss_ss_ii_oo_nn_SS_ee_ll_ee_cc_tt_ii_oo_nn ==
│ │ │ │ DDeeccoommpprreessssiioonnSSeelleeccttiioonn..XXYY__RREETTUURRNNSS__CCHHAANNNNEELL || ZZ || CCLLAASSSSIIFFIICCAATTIIOONN || FFLLAAGGSS ||
│ │ │ │ IINNTTEENNSSIITTYY || SSCCAANN__AANNGGLLEE || UUSSEERR__DDAATTAA || PPOOIINNTT__SSOOUURRCCEE__IIDD || GGPPSS__TTIIMMEE || RRGGBB || NNIIRR ||
│ │ │ │ WWAAVVEEPPAACCKKEETT || AALLLL__EEXXTTRRAA__BBYYTTEESS) → _L_a_s_R_e_a_d_e_r | _L_a_s_W_r_i_t_e_r | _L_a_s_A_p_p_e_n_d_e_r_
│ │ │ │ The laspy.open opens a LAS/LAZ file in one of the 3 supported mode:
│ │ │ │ * “r” => Reading => a laspy.LasReader will be returned
│ │ │ │ * “w” => Writing => a laspy.LasWriter will be returned
│ │ │ │ @@ -94,16 +94,16 @@
│ │ │ │ True
│ │ │ │ >>> f = open('tests/data/simple.las', mode='rb')
│ │ │ │ >>> with open_las(f) as flas:
│ │ │ │ ... las = flas.read()
│ │ │ │ >>> f.closed
│ │ │ │ True
│ │ │ │ ******** llaassppyy..ccrreeaattee_? ********
│ │ │ │ - laspy.create(**, ppooiinntt__ffoorrmmaatt:: _PP_oo_ii_nn_tt_FF_oo_rr_mm_aa_tt || _ii_nn_tt || _NN_oo_nn_ee == NNoonnee, ffiillee__vveerrssiioonn::
│ │ │ │ - VVeerrssiioonn || _ss_tt_rr || _NN_oo_nn_ee == NNoonnee)_
│ │ │ │ + laspy.create(**, ppooiinntt__ffoorrmmaatt:: _PP_oo_ii_nn_tt_FF_oo_rr_mm_aa_tt || iinntt || NNoonnee == NNoonnee, ffiillee__vveerrssiioonn::
│ │ │ │ + VVeerrssiioonn || ssttrr || NNoonnee == NNoonnee)_
│ │ │ │ Function to create a new empty las data object
│ │ │ │ Note
│ │ │ │ If you provide both point_format and file_version an exception will be
│ │ │ │ raised if they are not compatible
│ │ │ │ >>> las = create_las(point_format=6,file_version="1.2")
│ │ │ │ Traceback (most recent call last):
│ │ │ │ ...
│ │ │ │ @@ -161,18 +161,18 @@
│ │ │ │ Traceback (most recent call last):
│ │ │ │ ...
│ │ │ │ laspy.errors.LaspyException: Point format 6 is not compatible with file
│ │ │ │ version 1.2
│ │ │ │ Parameters:
│ │ │ │ * ssoouurrccee__llaass (llaassppyy..llaassddaattaass..bbaassee..LLaassBBaassee) – The source data to
│ │ │ │ be converted
│ │ │ │ - * ppooiinntt__ffoorrmmaatt__iidd (_ii_nn_tt,, ooppttiioonnaall) – The new point format id
│ │ │ │ + * ppooiinntt__ffoorrmmaatt__iidd (iinntt,, ooppttiioonnaall) – The new point format id
│ │ │ │ (the default is None, which won’t change the source format
│ │ │ │ id)
│ │ │ │ - * ffiillee__vveerrssiioonn (_ss_tt_rr,, ooppttiioonnaall,,) – The new file version. None by
│ │ │ │ + * ffiillee__vveerrssiioonn (ssttrr,, ooppttiioonnaall,,) – The new file version. None by
│ │ │ │ default which means that the file_version may be upgraded for
│ │ │ │ compatibility with the new point_format. The file version
│ │ │ │ will not be downgraded.
│ │ │ │ Return type:
│ │ │ │ laspy.lasdatas.base.LasBase
│ │ │ │ ********** RRee--eexxppoorrtteedd ccllaasssseess_? **********
│ │ │ │ * _L_a_s_H_e_a_d_e_r
│ │ ├── ./usr/share/doc/python-laspy-doc/html/api/laspy.compression.html
│ │ │ @@ -115,15 +115,15 @@
│ │ │
│ │ │ laspy.compression module
│ │ │
│ │ │ LazBackend
│ │ │
│ │ │ -
│ │ │ class laspy.compression.LazBackend(value, names=<not given>, *values, module=None, qualname=None, type=None, start=1, boundary=None)[source]
│ │ │ -Bases: ILazBackend
, Enum
│ │ │ +Bases: ILazBackend
, Enum
│ │ │ Supported backends for reading and writing LAS/LAZ
│ │ │
│ │ │ -
│ │ │ LazrsParallel = 0
│ │ │ lazrs in multi-thread mode
│ │ │
│ │ │
│ │ │ @@ -137,28 +137,28 @@
│ │ │ -
│ │ │ Laszip = 2
│ │ │ laszip backend
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ -classmethod detect_available() → Tuple[LazBackend, ...][source]
│ │ │ +classmethod detect_available() → Tuple[LazBackend, ...][source]
│ │ │ Returns a tuple containing the available backends in the current
│ │ │ python environment
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ DecompressionSelection
│ │ │
│ │ │ -
│ │ │ class laspy.compression.DecompressionSelection(value, names=<not given>, *values, module=None, qualname=None, type=None, start=1, boundary=None)[source]
│ │ │ -Bases: IntFlag
│ │ │ +Bases: IntFlag
│ │ │ Holds which fields to decompress or not.
│ │ │ Only used for files with version >= 1.4 && point format id >= 6.
│ │ │ Ignored on other cases.
│ │ │ Each flag in the enum has a corresponding decompress_$name
and
│ │ │ skip_$name
methods to easily create a selection.
│ │ │ >>> import laspy
│ │ │ >>> # Creating a selection that decompresses the base + z field
│ │ │ @@ -281,20 +281,20 @@
│ │ │
│ │ │ -
│ │ │ to_lazrs() → lazrs.DecompressionSelection[source]
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ -to_laszip() → int[source]
│ │ │ +to_laszip() → int[source]
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ -is_set(mask) → bool
│ │ │ +is_set(mask) → bool
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ ├── html2text {}
│ │ │ │ @@ -36,30 +36,30 @@
│ │ │ │ * laspy.compression module
│ │ │ │ * _V_i_e_w_ _p_a_g_e_ _s_o_u_r_c_e
│ │ │ │ ===============================================================================
│ │ │ │ ************ llaassppyy..ccoommpprreessssiioonn mmoodduullee_? ************
│ │ │ │ ********** LLaazzBBaacckkeenndd_? **********
│ │ │ │ ccllaassss laspy.compression.LazBackend(vvaalluuee, nnaammeess==<
>, **vvaalluueess,
│ │ │ │ mmoodduullee==NNoonnee, qquuaallnnaammee==NNoonnee, ttyyppee==NNoonnee, ssttaarrtt==11, bboouunnddaarryy==NNoonnee)_[_s_o_u_r_c_e_]_
│ │ │ │ - Bases: ILazBackend, _E_n_u_m
│ │ │ │ + Bases: ILazBackend, Enum
│ │ │ │ Supported backends for reading and writing LAS/LAZ
│ │ │ │ LazrsParallel == 00_
│ │ │ │ lazrs in multi-thread mode
│ │ │ │ Lazrs == 11_
│ │ │ │ lazrs in single-thread mode
│ │ │ │ Laszip == 22_
│ │ │ │ laszip backend
│ │ │ │ - ccllaassssmmeetthhoodd detect_available() → _T_u_p_l_e[_L_a_z_B_a_c_k_e_n_d, ...]_[_s_o_u_r_c_e_]_
│ │ │ │ + ccllaassssmmeetthhoodd detect_available() → Tuple[_L_a_z_B_a_c_k_e_n_d, ...]_[_s_o_u_r_c_e_]_
│ │ │ │ Returns a tuple containing the available backends in the current
│ │ │ │ python environment
│ │ │ │ ********** DDeeccoommpprreessssiioonnSSeelleeccttiioonn_? **********
│ │ │ │ ccllaassss laspy.compression.DecompressionSelection(vvaalluuee, nnaammeess==<>,
│ │ │ │ **vvaalluueess, mmoodduullee==NNoonnee, qquuaallnnaammee==NNoonnee, ttyyppee==NNoonnee, ssttaarrtt==11, bboouunnddaarryy==NNoonnee)
│ │ │ │ _[_s_o_u_r_c_e_]_
│ │ │ │ - Bases: _I_n_t_F_l_a_g
│ │ │ │ + Bases: IntFlag
│ │ │ │ Holds which fields to decompress or not.
│ │ │ │ Only used for files with version >= 1.4 && point format id >= 6.
│ │ │ │ Ignored on other cases.
│ │ │ │ Each flag in the enum has a corresponding decompress_$name and skip_$name
│ │ │ │ methods to easily create a selection.
│ │ │ │ >>> import laspy
│ │ │ │ >>> # Creating a selection that decompresses the base + z field
│ │ │ │ @@ -108,16 +108,16 @@
│ │ │ │ ccllaassssmmeetthhoodd base() → _D_e_c_o_m_p_r_e_s_s_i_o_n_S_e_l_e_c_t_i_o_n_[_s_o_u_r_c_e_]_
│ │ │ │ Returns a decompression selection where only the base x, y, return
│ │ │ │ number, number of returns and scanner channel will be decompressed
│ │ │ │ ccllaassssmmeetthhoodd xy_returns_channel() → _D_e_c_o_m_p_r_e_s_s_i_o_n_S_e_l_e_c_t_i_o_n_[_s_o_u_r_c_e_]_
│ │ │ │ Returns a decompression selection where only the base x, y, return
│ │ │ │ number, number of returns and scanner channel will be decompressed
│ │ │ │ to_lazrs() → lazrs.DecompressionSelection_[_s_o_u_r_c_e_]_
│ │ │ │ - to_laszip() → _i_n_t_[_s_o_u_r_c_e_]_
│ │ │ │ - is_set(mmaasskk) → _b_o_o_l_
│ │ │ │ + to_laszip() → int_[_s_o_u_r_c_e_]_
│ │ │ │ + is_set(mmaasskk) → bool_
│ │ │ │ decompress_all_extra_bytes()_
│ │ │ │ skip_all_extra_bytes()_
│ │ │ │ is_set_all_extra_bytes()_
│ │ │ │ decompress_classification()_
│ │ │ │ skip_classification()_
│ │ │ │ is_set_classification()_
│ │ │ │ decompress_flags()_
│ │ ├── ./usr/share/doc/python-laspy-doc/html/api/laspy.copc.html
│ │ │ @@ -113,16 +113,16 @@
│ │ │
│ │ │
│ │ │ laspy.copc module
│ │ │
│ │ │ CopcReader
│ │ │
│ │ │ -
│ │ │ -class laspy.copc.CopcReader(stream, close_fd: bool = True, http_num_threads: int = 30, _http_strategy: str = 'queue', decompression_selection: DecompressionSelection = DecompressionSelection.XY_RETURNS_CHANNEL | Z | CLASSIFICATION | FLAGS | INTENSITY | SCAN_ANGLE | USER_DATA | POINT_SOURCE_ID | GPS_TIME | RGB | NIR | WAVEPACKET | ALL_EXTRA_BYTES)[source]
│ │ │ -Bases: object
│ │ │ +class laspy.copc.CopcReader(stream, close_fd: bool = True, http_num_threads: int = 160, _http_strategy: str = 'queue', decompression_selection: DecompressionSelection = DecompressionSelection.XY_RETURNS_CHANNEL | Z | CLASSIFICATION | FLAGS | INTENSITY | SCAN_ANGLE | USER_DATA | POINT_SOURCE_ID | GPS_TIME | RGB | NIR | WAVEPACKET | ALL_EXTRA_BYTES)[source]
│ │ │ +Bases: object
│ │ │ Class allowing to do queries over a COPC LAZ
│ │ │ In short, COPC files are LAZ 1.4 files organized in a particular way
│ │ │ (Octree) making it possible to do spatial queries
│ │ │ as well as queries with a level of details.
│ │ │ CopcReader requires the lazrz
backend to work.
│ │ │ Optionaly, if requests
is installed, CopcReader can handle
│ │ │ Copc files that are on a remote HTTP server
│ │ │ @@ -131,52 +131,52 @@
│ │ │ To create an instance of it you’ll likely
│ │ │ want to use the CopcReader.open()
constructor
│ │ │
│ │ │
New in version 2.2.
│ │ │
│ │ │
│ │ │ -
│ │ │ -__init__(stream, close_fd: bool = True, http_num_threads: int = 30, _http_strategy: str = 'queue', decompression_selection: DecompressionSelection = DecompressionSelection.XY_RETURNS_CHANNEL | Z | CLASSIFICATION | FLAGS | INTENSITY | SCAN_ANGLE | USER_DATA | POINT_SOURCE_ID | GPS_TIME | RGB | NIR | WAVEPACKET | ALL_EXTRA_BYTES)[source]
│ │ │ +__init__(stream, close_fd: bool = True, http_num_threads: int = 160, _http_strategy: str = 'queue', decompression_selection: DecompressionSelection = DecompressionSelection.XY_RETURNS_CHANNEL | Z | CLASSIFICATION | FLAGS | INTENSITY | SCAN_ANGLE | USER_DATA | POINT_SOURCE_ID | GPS_TIME | RGB | NIR | WAVEPACKET | ALL_EXTRA_BYTES)[source]
│ │ │ Creates a CopcReader.
│ │ │
│ │ │ - Parameters:
│ │ │
│ │ │ stream (the stream from where data can be read.) – It must have the following file object methods:
│ │ │ read, seek, tell
│ │ │ -http_num_threads (int, optional, default num cpu * 5) – Number of worker threads to do concurent HTTP requests,
│ │ │ +
http_num_threads (int, optional, default num cpu * 5) – Number of worker threads to do concurent HTTP requests,
│ │ │ ignored when reading non-HTTP file
│ │ │ close_fd (optional, default bool) – Whether the stream/file object shall be closed, this only work
│ │ │ when using the CopcReader in a with statement.
│ │ │ decompression_selection (DecompressionSelection,) – see laspy.open()
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │
New in version 2.4: The decompression_selection
parameter.
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ -classmethod open(source: str | PathLike | IOBase, http_num_threads: int = 30, _http_strategy: str = 'queue', decompression_selection: DecompressionSelection = DecompressionSelection.XY_RETURNS_CHANNEL | Z | CLASSIFICATION | FLAGS | INTENSITY | SCAN_ANGLE | USER_DATA | POINT_SOURCE_ID | GPS_TIME | RGB | NIR | WAVEPACKET | ALL_EXTRA_BYTES) → CopcReader[source]
│ │ │ +classmethod open(source: str | PathLike | IOBase, http_num_threads: int = 160, _http_strategy: str = 'queue', decompression_selection: DecompressionSelection = DecompressionSelection.XY_RETURNS_CHANNEL | Z | CLASSIFICATION | FLAGS | INTENSITY | SCAN_ANGLE | USER_DATA | POINT_SOURCE_ID | GPS_TIME | RGB | NIR | WAVEPACKET | ALL_EXTRA_BYTES) → CopcReader[source]
│ │ │ Opens the COPC file.
│ │ │
│ │ │ - Parameters:
│ │ │
│ │ │ -source (str, io.IOBase, uri or file-like object of the COPC file.) –
Supported sources are:
│ │ │ +source (str, io.IOBase, uri or file-like object of the COPC file.) –
Supported sources are:
│ │ │
│ │ │
│ │ │ ’local’ files accesible with a path.
│ │ │ HTTP / HTTPS endpoints. The pyhon package requests
is
│ │ │ required in order to be able to work with HTTP endpoints.
│ │ │ file-like objects, e.g. fsspec io.IOBase objects.
│ │ │
│ │ │
│ │ │
│ │ │ -http_num_threads (int, optional, default num cpu * 5) – Number of worker threads to do concurent HTTP requests,
│ │ │ +
http_num_threads (int, optional, default num cpu * 5) – Number of worker threads to do concurent HTTP requests,
│ │ │ ignored when reading non-HTTP file
│ │ │ decompression_selection (DecompressionSelection,) – see laspy.open()
│ │ │
│ │ │
│ │ │
│ │ │ Opening a local file
│ │ │ from laspy import CopcReader
│ │ │ @@ -197,34 +197,34 @@
│ │ │
│ │ │
New in version 2.4: The decompression_selection
parameter.
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ -query(bounds: Bounds | None = None, resolution: float | int | None = None, level: int | range | None = None) → ScaleAwarePointRecord[source]
│ │ │ +query(bounds: Bounds | None = None, resolution: float | int | None = None, level: int | range | None = None) → ScaleAwarePointRecord[source]
│ │ │ ”
│ │ │ Query the COPC file to retrieve the points matching the
│ │ │ requested bounds and level.
│ │ │
│ │ │ - Parameters:
│ │ │
│ │ │ bounds (Bounds, optional, default None) – The bounds for which you wish to aquire points.
│ │ │ If None, the whole file’s bounds will be considered
│ │ │ 2D bounds are suported, (No point will be filtered on its Z coordinate)
│ │ │ -resolution (float or int, optional, default None) –
Limits the octree levels to be queried in order to have
│ │ │ +
resolution (float or int, optional, default None) –
Limits the octree levels to be queried in order to have
│ │ │ a point cloud with the requested resolution.
│ │ │
│ │ │ The unit is the one of the data.
│ │ │ If None, the resulting cloud will be at the
│ │ │ full resolution offered by the COPC source
│ │ │ Mutually exclusive with level parameter
│ │ │
│ │ │
│ │ │ -level (int or range, optional, default None) –
The level of detail (LOD).
│ │ │ +level (int or range, optional, default None) –
The level of detail (LOD).
│ │ │
│ │ │ If None, all LOD are going to be considered
│ │ │ If it is an int, only points that are of the requested LOD
│ │ │ will be returned.
│ │ │ If it is a range, points for which the LOD is within the range
│ │ │ will be returned
│ │ │
│ │ │ @@ -237,41 +237,41 @@
│ │ │
│ │ │ -
│ │ │ spatial_query(bounds: Bounds) → ScaleAwarePointRecord[source]
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ -level_query(level: int | range) → ScaleAwarePointRecord[source]
│ │ │ +level_query(level: int | range) → ScaleAwarePointRecord[source]
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ class laspy.copc.Bounds(mins: numpy.ndarray, maxs: numpy.ndarray)[source]
│ │ │ -Bases: object
│ │ │ +Bases: object
│ │ │
│ │ │ -
│ │ │ -__init__(mins: ndarray, maxs: ndarray) → None
│ │ │ +__init__(mins: ndarray, maxs: ndarray) → None
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ mins: ndarray
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ maxs: ndarray
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ -overlaps(other: Bounds) → bool[source]
│ │ │ +overlaps(other: Bounds) → bool[source]
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ ensure_3d(mins: ndarray, maxs: ndarray) → Bounds[source]
│ │ │
│ │ │ ├── html2text {}
│ │ │ │ @@ -33,54 +33,54 @@
│ │ │ │ _l_a_s_p_y
│ │ │ │ * _A_P_I_ _D_o_c_u_m_e_n_t_a_t_i_o_n
│ │ │ │ * laspy.copc module
│ │ │ │ * _V_i_e_w_ _p_a_g_e_ _s_o_u_r_c_e
│ │ │ │ ===============================================================================
│ │ │ │ ************ llaassppyy..ccooppcc mmoodduullee_? ************
│ │ │ │ ********** CCooppccRReeaaddeerr_? **********
│ │ │ │ - ccllaassss laspy.copc.CopcReader(ssttrreeaamm, cclloossee__ffdd:: _bb_oo_oo_ll == TTrruuee, hhttttpp__nnuumm__tthhrreeaaddss::
│ │ │ │ - _ii_nn_tt == 3300, __hhttttpp__ssttrraatteeggyy:: _ss_tt_rr == ''qquueeuuee'', ddeeccoommpprreessssiioonn__sseelleeccttiioonn::
│ │ │ │ + ccllaassss laspy.copc.CopcReader(ssttrreeaamm, cclloossee__ffdd:: bbooooll == TTrruuee, hhttttpp__nnuumm__tthhrreeaaddss::
│ │ │ │ + iinntt == 116600, __hhttttpp__ssttrraatteeggyy:: ssttrr == ''qquueeuuee'', ddeeccoommpprreessssiioonn__sseelleeccttiioonn::
│ │ │ │ _DD_ee_cc_oo_mm_pp_rr_ee_ss_ss_ii_oo_nn_SS_ee_ll_ee_cc_tt_ii_oo_nn == DDeeccoommpprreessssiioonnSSeelleeccttiioonn..XXYY__RREETTUURRNNSS__CCHHAANNNNEELL || ZZ ||
│ │ │ │ CCLLAASSSSIIFFIICCAATTIIOONN || FFLLAAGGSS || IINNTTEENNSSIITTYY || SSCCAANN__AANNGGLLEE || UUSSEERR__DDAATTAA || PPOOIINNTT__SSOOUURRCCEE__IIDD
│ │ │ │ || GGPPSS__TTIIMMEE || RRGGBB || NNIIRR || WWAAVVEEPPAACCKKEETT || AALLLL__EEXXTTRRAA__BBYYTTEESS)_[_s_o_u_r_c_e_]_
│ │ │ │ - Bases: _o_b_j_e_c_t
│ │ │ │ + Bases: object
│ │ │ │ Class allowing to do queries over a _C_O_P_C LAZ
│ │ │ │ In short, COPC files are LAZ 1.4 files organized in a particular way
│ │ │ │ (Octree) making it possible to do spatial queries as well as queries with
│ │ │ │ a level of details.
│ │ │ │ CopcReader rreeqquuiirreess the lazrz backend to work.
│ │ │ │ Optionaly, if requests is installed, CopcReader can handle Copc files
│ │ │ │ that are on a remote HTTP server
│ │ │ │ This class oonnllyy reads COPC files, it does not support normal LAS/LAZ
│ │ │ │ files.
│ │ │ │ To create an instance of it you’ll likely want to use the _C_o_p_c_R_e_a_d_e_r_._o_p_e_n
│ │ │ │ _(_) constructor
│ │ │ │ New in version 2.2.
│ │ │ │ - __init__(ssttrreeaamm, cclloossee__ffdd:: _bb_oo_oo_ll == TTrruuee, hhttttpp__nnuumm__tthhrreeaaddss:: _ii_nn_tt == 3300,
│ │ │ │ - __hhttttpp__ssttrraatteeggyy:: _ss_tt_rr == ''qquueeuuee'', ddeeccoommpprreessssiioonn__sseelleeccttiioonn::
│ │ │ │ + __init__(ssttrreeaamm, cclloossee__ffdd:: bbooooll == TTrruuee, hhttttpp__nnuumm__tthhrreeaaddss:: iinntt == 116600,
│ │ │ │ + __hhttttpp__ssttrraatteeggyy:: ssttrr == ''qquueeuuee'', ddeeccoommpprreessssiioonn__sseelleeccttiioonn::
│ │ │ │ _DD_ee_cc_oo_mm_pp_rr_ee_ss_ss_ii_oo_nn_SS_ee_ll_ee_cc_tt_ii_oo_nn == DDeeccoommpprreessssiioonnSSeelleeccttiioonn..XXYY__RREETTUURRNNSS__CCHHAANNNNEELL || ZZ
│ │ │ │ || CCLLAASSSSIIFFIICCAATTIIOONN || FFLLAAGGSS || IINNTTEENNSSIITTYY || SSCCAANN__AANNGGLLEE || UUSSEERR__DDAATTAA ||
│ │ │ │ PPOOIINNTT__SSOOUURRCCEE__IIDD || GGPPSS__TTIIMMEE || RRGGBB || NNIIRR || WWAAVVEEPPAACCKKEETT || AALLLL__EEXXTTRRAA__BBYYTTEESS)
│ │ │ │ _[_s_o_u_r_c_e_]_
│ │ │ │ Creates a CopcReader.
│ │ │ │ Parameters:
│ │ │ │ * ssttrreeaamm (tthhee ssttrreeaamm ffrroomm wwhheerree ddaattaa ccaann bbee rreeaadd..) – It
│ │ │ │ must have the following file object methods: read,
│ │ │ │ seek, tell
│ │ │ │ - * hhttttpp__nnuumm__tthhrreeaaddss (_ii_nn_tt,, ooppttiioonnaall,, ddeeffaauulltt nnuumm ccppuu ** 55) –
│ │ │ │ + * hhttttpp__nnuumm__tthhrreeaaddss (iinntt,, ooppttiioonnaall,, ddeeffaauulltt nnuumm ccppuu ** 55) –
│ │ │ │ Number of worker threads to do concurent HTTP requests,
│ │ │ │ ignored when reading non-HTTP file
│ │ │ │ * cclloossee__ffdd (ooppttiioonnaall,, ddeeffaauulltt bbooooll) – Whether the stream/
│ │ │ │ file object shall be closed, this only work when using
│ │ │ │ the CopcReader in a with statement.
│ │ │ │ * ddeeccoommpprreessssiioonn__sseelleeccttiioonn (_DD_ee_cc_oo_mm_pp_rr_ee_ss_ss_ii_oo_nn_SS_ee_ll_ee_cc_tt_ii_oo_nn,,) – see
│ │ │ │ _l_a_s_p_y_._o_p_e_n_(_)
│ │ │ │ New in version 2.4: The decompression_selection parameter.
│ │ │ │ - ccllaassssmmeetthhoodd open(ssoouurrccee:: _ss_tt_rr || _PP_aa_tt_hh_LL_ii_kk_ee || _II_OO_BB_aa_ss_ee, hhttttpp__nnuumm__tthhrreeaaddss:: _ii_nn_tt
│ │ │ │ - == 3300, __hhttttpp__ssttrraatteeggyy:: _ss_tt_rr == ''qquueeuuee'', ddeeccoommpprreessssiioonn__sseelleeccttiioonn::
│ │ │ │ + ccllaassssmmeetthhoodd open(ssoouurrccee:: ssttrr || PPaatthhLLiikkee || IIOOBBaassee, hhttttpp__nnuumm__tthhrreeaaddss:: iinntt
│ │ │ │ + == 116600, __hhttttpp__ssttrraatteeggyy:: ssttrr == ''qquueeuuee'', ddeeccoommpprreessssiioonn__sseelleeccttiioonn::
│ │ │ │ _DD_ee_cc_oo_mm_pp_rr_ee_ss_ss_ii_oo_nn_SS_ee_ll_ee_cc_tt_ii_oo_nn == DDeeccoommpprreessssiioonnSSeelleeccttiioonn..XXYY__RREETTUURRNNSS__CCHHAANNNNEELL || ZZ
│ │ │ │ || CCLLAASSSSIIFFIICCAATTIIOONN || FFLLAAGGSS || IINNTTEENNSSIITTYY || SSCCAANN__AANNGGLLEE || UUSSEERR__DDAATTAA ||
│ │ │ │ PPOOIINNTT__SSOOUURRCCEE__IIDD || GGPPSS__TTIIMMEE || RRGGBB || NNIIRR || WWAAVVEEPPAACCKKEETT || AALLLL__EEXXTTRRAA__BBYYTTEESS)
│ │ │ │ → _C_o_p_c_R_e_a_d_e_r_[_s_o_u_r_c_e_]_
│ │ │ │ Opens the COPC file.
│ │ │ │ Opening a local file
│ │ │ │ from laspy import CopcReader
│ │ │ │ @@ -91,25 +91,25 @@
│ │ │ │ from laspy import CopcReader
│ │ │ │
│ │ │ │ url = "https://s3.amazonaws.com/hobu-lidar/autzen-
│ │ │ │ classified.copc.laz"
│ │ │ │ with CopcReader.open(url) as reader:
│ │ │ │ ...
│ │ │ │ New in version 2.4: The decompression_selection parameter.
│ │ │ │ - query(bboouunnddss:: _BB_oo_uu_nn_dd_ss || _NN_oo_nn_ee == NNoonnee, rreessoolluuttiioonn:: _ff_ll_oo_aa_tt || _ii_nn_tt || _NN_oo_nn_ee ==
│ │ │ │ - NNoonnee, lleevveell:: _ii_nn_tt || _rr_aa_nn_gg_ee || _NN_oo_nn_ee == NNoonnee) → _S_c_a_l_e_A_w_a_r_e_P_o_i_n_t_R_e_c_o_r_d
│ │ │ │ + query(bboouunnddss:: _BB_oo_uu_nn_dd_ss || NNoonnee == NNoonnee, rreessoolluuttiioonn:: ffllooaatt || iinntt || NNoonnee ==
│ │ │ │ + NNoonnee, lleevveell:: iinntt || rraannggee || NNoonnee == NNoonnee) → _S_c_a_l_e_A_w_a_r_e_P_o_i_n_t_R_e_c_o_r_d
│ │ │ │ _[_s_o_u_r_c_e_]_
│ │ │ │ ” Query the COPC file to retrieve the points matching the requested
│ │ │ │ bounds and level.
│ │ │ │ spatial_query(bboouunnddss:: _BB_oo_uu_nn_dd_ss) → _S_c_a_l_e_A_w_a_r_e_P_o_i_n_t_R_e_c_o_r_d_[_s_o_u_r_c_e_]_
│ │ │ │ - level_query(lleevveell:: _ii_nn_tt || _rr_aa_nn_gg_ee) → _S_c_a_l_e_A_w_a_r_e_P_o_i_n_t_R_e_c_o_r_d_[_s_o_u_r_c_e_]_
│ │ │ │ + level_query(lleevveell:: iinntt || rraannggee) → _S_c_a_l_e_A_w_a_r_e_P_o_i_n_t_R_e_c_o_r_d_[_s_o_u_r_c_e_]_
│ │ │ │ ccllaassss laspy.copc.Bounds(mmiinnss:: nnuummppyy..nnddaarrrraayy, mmaaxxss:: nnuummppyy..nnddaarrrraayy)_[_s_o_u_r_c_e_]_
│ │ │ │ - Bases: _o_b_j_e_c_t
│ │ │ │ - __init__(mmiinnss:: nnddaarrrraayy, mmaaxxss:: nnddaarrrraayy) → _N_o_n_e_
│ │ │ │ + Bases: object
│ │ │ │ + __init__(mmiinnss:: nnddaarrrraayy, mmaaxxss:: nnddaarrrraayy) → None_
│ │ │ │ mins:: nnddaarrrraayy_
│ │ │ │ maxs:: nnddaarrrraayy_
│ │ │ │ - overlaps(ootthheerr:: _BB_oo_uu_nn_dd_ss) → _b_o_o_l_[_s_o_u_r_c_e_]_
│ │ │ │ + overlaps(ootthheerr:: _BB_oo_uu_nn_dd_ss) → bool_[_s_o_u_r_c_e_]_
│ │ │ │ ensure_3d(mmiinnss:: nnddaarrrraayy, mmaaxxss:: nnddaarrrraayy) → _B_o_u_n_d_s_[_s_o_u_r_c_e_]_
│ │ │ │ _P_r_e_v_i_o_u_s _N_e_x_t
│ │ │ │ ===============================================================================
│ │ │ │ © Copyright 2018-2024, laspy.
│ │ │ │ Built with _S_p_h_i_n_x using a _t_h_e_m_e provided by _R_e_a_d_ _t_h_e_ _D_o_c_s.
│ │ ├── ./usr/share/doc/python-laspy-doc/html/api/laspy.errors.html
│ │ │ @@ -118,15 +118,15 @@
│ │ │
│ │ │
│ │ │ laspy.errors module
│ │ │ All the custom exceptions types
│ │ │
│ │ │ -
│ │ │ exception laspy.errors.LaspyException[source]
│ │ │ -Bases: Exception
│ │ │ +Bases: Exception
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ Bases: LaspyException
│ │ │
│ │ │ ├── html2text {}
│ │ │ │ @@ -39,15 +39,15 @@
│ │ │ │ * _A_P_I_ _D_o_c_u_m_e_n_t_a_t_i_o_n
│ │ │ │ * laspy.errors module
│ │ │ │ * _V_i_e_w_ _p_a_g_e_ _s_o_u_r_c_e
│ │ │ │ ===============================================================================
│ │ │ │ ************ llaassppyy..eerrrroorrss mmoodduullee_? ************
│ │ │ │ All the custom exceptions types
│ │ │ │ eexxcceeppttiioonn laspy.errors.LaspyException_[_s_o_u_r_c_e_]_
│ │ │ │ - Bases: _E_x_c_e_p_t_i_o_n
│ │ │ │ + Bases: Exception
│ │ │ │ eexxcceeppttiioonn laspy.errors.UnknownExtraType_[_s_o_u_r_c_e_]_
│ │ │ │ Bases: _L_a_s_p_y_E_x_c_e_p_t_i_o_n
│ │ │ │ eexxcceeppttiioonn laspy.errors.PointFormatNotSupported_[_s_o_u_r_c_e_]_
│ │ │ │ Bases: _L_a_s_p_y_E_x_c_e_p_t_i_o_n
│ │ │ │ eexxcceeppttiioonn laspy.errors.FileVersionNotSupported_[_s_o_u_r_c_e_]_
│ │ │ │ Bases: _L_a_s_p_y_E_x_c_e_p_t_i_o_n
│ │ │ │ eexxcceeppttiioonn laspy.errors.LazError_[_s_o_u_r_c_e_]_
│ │ ├── ./usr/share/doc/python-laspy-doc/html/api/laspy.header.html
│ │ │ @@ -113,16 +113,16 @@
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ ├── html2text {}
│ │ │ │ @@ -50,118 +50,118 @@
│ │ │ │ * laspy.vlrs.known module
│ │ │ │ * _V_i_e_w_ _p_a_g_e_ _s_o_u_r_c_e
│ │ │ │ ===============================================================================
│ │ │ │ ************ llaassppyy..vvllrrss..kknnoowwnn mmoodduullee_? ************
│ │ │ │ The definition of the VLR Header, VLR, the KnownVLRs are in this module.
│ │ │ │ A KnownVLR is a VLR for which we know how to parse its record_data
│ │ │ │ ccllaassss laspy.vlrs.known.IKnownVLR_[_s_o_u_r_c_e_]_
│ │ │ │ - Bases: _A_B_C
│ │ │ │ + Bases: ABC
│ │ │ │ Interface that any KnownVLR must implement. A KnownVLR is a VLR for which
│ │ │ │ we know how to parse its record_data
│ │ │ │ Implementing this interfaces allows to automatically call the right
│ │ │ │ parser for the right VLR when reading them.
│ │ │ │ - aabbssttrraacctt ssttaattiicc official_user_id() → _s_t_r_[_s_o_u_r_c_e_]_
│ │ │ │ + aabbssttrraacctt ssttaattiicc official_user_id() → str_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official user_id as described in the documentation
│ │ │ │ - aabbssttrraacctt ssttaattiicc official_record_ids() → _T_u_p_l_e[_i_n_t, ...]_[_s_o_u_r_c_e_]_
│ │ │ │ + aabbssttrraacctt ssttaattiicc official_record_ids() → Tuple[int, ...]_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official record_id for the VLR
│ │ │ │ Note
│ │ │ │ Even if the VLR has one record_id, the return type must be a tuple
│ │ │ │ Returns:
│ │ │ │ The record_ids this VLR type can have
│ │ │ │ Return type:
│ │ │ │ - _t_u_p_l_e of _i_n_t
│ │ │ │ - aabbssttrraacctt record_data_bytes() → _b_y_t_e_s_[_s_o_u_r_c_e_]_
│ │ │ │ + tuple of int
│ │ │ │ + aabbssttrraacctt record_data_bytes() → bytes_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the bytes corresponding to the record_data part of the
│ │ │ │ VLR as they should be written in the file.
│ │ │ │ Returns:
│ │ │ │ The bytes of the vlr’s record_data
│ │ │ │ Return type:
│ │ │ │ - _b_y_t_e_s
│ │ │ │ - aabbssttrraacctt parse_record_data(rreeccoorrdd__ddaattaa:: _bb_yy_tt_ee_ss) → _N_o_n_e_[_s_o_u_r_c_e_]_
│ │ │ │ + bytes
│ │ │ │ + aabbssttrraacctt parse_record_data(rreeccoorrdd__ddaattaa:: bbyytteess) → None_[_s_o_u_r_c_e_]_
│ │ │ │ Shall parse the given record_data into a user-friendlier structure
│ │ │ │ Parameters:
│ │ │ │ - rreeccoorrdd__ddaattaa (_bb_yy_tt_ee_ss) – The record_data bytes read from the
│ │ │ │ + rreeccoorrdd__ddaattaa (bbyytteess) – The record_data bytes read from the
│ │ │ │ file
│ │ │ │ ccllaassss laspy.vlrs.known.BaseKnownVLR(rreeccoorrdd__iidd==NNoonnee, ddeessccrriippttiioonn=='''')_[_s_o_u_r_c_e_]_
│ │ │ │ - Bases: BaseVLR, _I_K_n_o_w_n_V_L_R, _A_B_C
│ │ │ │ + Bases: BaseVLR, _I_K_n_o_w_n_V_L_R, ABC
│ │ │ │ Base Class to factorize common code between the different type of Known
│ │ │ │ VLRs
│ │ │ │ ccllaassssmmeetthhoodd from_raw(rraaww:: _VV_LL_RR)_[_s_o_u_r_c_e_]_
│ │ │ │ ccllaassss laspy.vlrs.known.ClassificationLookupVlr_[_s_o_u_r_c_e_]_
│ │ │ │ Bases: _B_a_s_e_K_n_o_w_n_V_L_R
│ │ │ │ This vlr maps class numbers to short descriptions / names
│ │ │ │ >>> lookup = ClassificationLookupVlr()
│ │ │ │ >>> lookup[0] = "never_classified"
│ │ │ │ >>> lookup[2] = "ground"
│ │ │ │ >>> lookup[0]
│ │ │ │ 'never_classified'
│ │ │ │ - parse_record_data(rreeccoorrdd__ddaattaa:: _bb_yy_tt_ee_ss) → _N_o_n_e_[_s_o_u_r_c_e_]_
│ │ │ │ + parse_record_data(rreeccoorrdd__ddaattaa:: bbyytteess) → None_[_s_o_u_r_c_e_]_
│ │ │ │ Shall parse the given record_data into a user-friendlier structure
│ │ │ │ Parameters:
│ │ │ │ - rreeccoorrdd__ddaattaa (_bb_yy_tt_ee_ss) – The record_data bytes read from the
│ │ │ │ + rreeccoorrdd__ddaattaa (bbyytteess) – The record_data bytes read from the
│ │ │ │ file
│ │ │ │ - record_data_bytes() → _b_y_t_e_s_[_s_o_u_r_c_e_]_
│ │ │ │ + record_data_bytes() → bytes_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the bytes corresponding to the record_data part of the
│ │ │ │ VLR as they should be written in the file.
│ │ │ │ Returns:
│ │ │ │ The bytes of the vlr’s record_data
│ │ │ │ Return type:
│ │ │ │ - _b_y_t_e_s
│ │ │ │ - ssttaattiicc official_user_id() → _s_t_r_[_s_o_u_r_c_e_]_
│ │ │ │ + bytes
│ │ │ │ + ssttaattiicc official_user_id() → str_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official user_id as described in the documentation
│ │ │ │ - ssttaattiicc official_record_ids() → _T_u_p_l_e[_i_n_t, ...]_[_s_o_u_r_c_e_]_
│ │ │ │ + ssttaattiicc official_record_ids() → Tuple[int, ...]_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official record_id for the VLR
│ │ │ │ Note
│ │ │ │ Even if the VLR has one record_id, the return type must be a tuple
│ │ │ │ Returns:
│ │ │ │ The record_ids this VLR type can have
│ │ │ │ Return type:
│ │ │ │ - _t_u_p_l_e of _i_n_t
│ │ │ │ - ccllaassss laspy.vlrs.known.LasZipVlr(ddaattaa:: _bb_yy_tt_ee_ss)_[_s_o_u_r_c_e_]_
│ │ │ │ + tuple of int
│ │ │ │ + ccllaassss laspy.vlrs.known.LasZipVlr(ddaattaa:: bbyytteess)_[_s_o_u_r_c_e_]_
│ │ │ │ Bases: _B_a_s_e_K_n_o_w_n_V_L_R
│ │ │ │ Contains the information needed by laszip (or any other laz backend) to
│ │ │ │ compress the point records.
│ │ │ │ - parse_record_data(rreeccoorrdd__ddaattaa:: _bb_yy_tt_ee_ss) → _N_o_n_e_[_s_o_u_r_c_e_]_
│ │ │ │ + parse_record_data(rreeccoorrdd__ddaattaa:: bbyytteess) → None_[_s_o_u_r_c_e_]_
│ │ │ │ Shall parse the given record_data into a user-friendlier structure
│ │ │ │ Parameters:
│ │ │ │ - rreeccoorrdd__ddaattaa (_bb_yy_tt_ee_ss) – The record_data bytes read from the
│ │ │ │ + rreeccoorrdd__ddaattaa (bbyytteess) – The record_data bytes read from the
│ │ │ │ file
│ │ │ │ - record_data_bytes() → _b_y_t_e_s_[_s_o_u_r_c_e_]_
│ │ │ │ + record_data_bytes() → bytes_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the bytes corresponding to the record_data part of the
│ │ │ │ VLR as they should be written in the file.
│ │ │ │ Returns:
│ │ │ │ The bytes of the vlr’s record_data
│ │ │ │ Return type:
│ │ │ │ - _b_y_t_e_s
│ │ │ │ - ssttaattiicc official_user_id() → _s_t_r_[_s_o_u_r_c_e_]_
│ │ │ │ + bytes
│ │ │ │ + ssttaattiicc official_user_id() → str_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official user_id as described in the documentation
│ │ │ │ - ssttaattiicc official_record_ids() → _T_u_p_l_e[_i_n_t, ...]_[_s_o_u_r_c_e_]_
│ │ │ │ + ssttaattiicc official_record_ids() → Tuple[int, ...]_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official record_id for the VLR
│ │ │ │ Note
│ │ │ │ Even if the VLR has one record_id, the return type must be a tuple
│ │ │ │ Returns:
│ │ │ │ The record_ids this VLR type can have
│ │ │ │ Return type:
│ │ │ │ - _t_u_p_l_e of _i_n_t
│ │ │ │ + tuple of int
│ │ │ │ ccllaassssmmeetthhoodd from_raw(rraaww__vvllrr)_[_s_o_u_r_c_e_]_
│ │ │ │ ccllaassss laspy.vlrs.known.ExtraBytesStruct_[_s_o_u_r_c_e_]_
│ │ │ │ Bases: Structure
│ │ │ │ NO_DATA_BIT_MASK == 11_
│ │ │ │ MIN_BIT_MASK == 22_
│ │ │ │ MAX_BIT_MASK == 44_
│ │ │ │ SCALE_BIT_MASK == 88_
│ │ │ │ OFFSET_BIT_MASK == 1166_
│ │ │ │ pprrooppeerrttyy no_data_
│ │ │ │ pprrooppeerrttyy min_
│ │ │ │ pprrooppeerrttyy max_
│ │ │ │ - pprrooppeerrttyy offset:: _AA_nn_yy || _NN_oo_nn_ee_
│ │ │ │ + pprrooppeerrttyy offset:: AAnnyy || NNoonnee_
│ │ │ │ pprrooppeerrttyy scale_
│ │ │ │ format_name()_[_s_o_u_r_c_e_]_
│ │ │ │ dtype() → dtype_[_s_o_u_r_c_e_]_
│ │ │ │ - num_elements() → _i_n_t_[_s_o_u_r_c_e_]_
│ │ │ │ + num_elements() → int_[_s_o_u_r_c_e_]_
│ │ │ │ ssttaattiicc size()_[_s_o_u_r_c_e_]_
│ │ │ │ data_type_
│ │ │ │ Structure/Union member
│ │ │ │ description_
│ │ │ │ Structure/Union member
│ │ │ │ name_
│ │ │ │ Structure/Union member
│ │ │ │ @@ -172,34 +172,34 @@
│ │ │ │ unused_
│ │ │ │ Structure/Union member
│ │ │ │ ccllaassss laspy.vlrs.known.ExtraBytesVlr_[_s_o_u_r_c_e_]_
│ │ │ │ Bases: _B_a_s_e_K_n_o_w_n_V_L_R
│ │ │ │ parse_record_data(ddaattaa)_[_s_o_u_r_c_e_]_
│ │ │ │ Shall parse the given record_data into a user-friendlier structure
│ │ │ │ Parameters:
│ │ │ │ - rreeccoorrdd__ddaattaa (_bb_yy_tt_ee_ss) – The record_data bytes read from the
│ │ │ │ + rreeccoorrdd__ddaattaa (bbyytteess) – The record_data bytes read from the
│ │ │ │ file
│ │ │ │ record_data_bytes()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the bytes corresponding to the record_data part of the
│ │ │ │ VLR as they should be written in the file.
│ │ │ │ Returns:
│ │ │ │ The bytes of the vlr’s record_data
│ │ │ │ Return type:
│ │ │ │ - _b_y_t_e_s
│ │ │ │ - type_of_extra_dims() → _L_i_s_t[_E_x_t_r_a_B_y_t_e_s_P_a_r_a_m_s]_[_s_o_u_r_c_e_]_
│ │ │ │ + bytes
│ │ │ │ + type_of_extra_dims() → List[_E_x_t_r_a_B_y_t_e_s_P_a_r_a_m_s]_[_s_o_u_r_c_e_]_
│ │ │ │ ssttaattiicc official_user_id()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official user_id as described in the documentation
│ │ │ │ ssttaattiicc official_record_ids()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official record_id for the VLR
│ │ │ │ Note
│ │ │ │ Even if the VLR has one record_id, the return type must be a tuple
│ │ │ │ Returns:
│ │ │ │ The record_ids this VLR type can have
│ │ │ │ Return type:
│ │ │ │ - _t_u_p_l_e of _i_n_t
│ │ │ │ + tuple of int
│ │ │ │ ccllaassss laspy.vlrs.known.WaveformPacketStruct_[_s_o_u_r_c_e_]_
│ │ │ │ Bases: Structure
│ │ │ │ ssttaattiicc size()_[_s_o_u_r_c_e_]_
│ │ │ │ bits_per_sample_
│ │ │ │ Structure/Union member
│ │ │ │ digitizer_gain_
│ │ │ │ Structure/Union member
│ │ │ │ @@ -212,31 +212,31 @@
│ │ │ │ waveform_compression_type_
│ │ │ │ Structure/Union member
│ │ │ │ ccllaassss laspy.vlrs.known.WaveformPacketVlr(rreeccoorrdd__iidd, ddeessccrriippttiioonn=='''')_[_s_o_u_r_c_e_]_
│ │ │ │ Bases: _B_a_s_e_K_n_o_w_n_V_L_R
│ │ │ │ parse_record_data(rreeccoorrdd__ddaattaa)_[_s_o_u_r_c_e_]_
│ │ │ │ Shall parse the given record_data into a user-friendlier structure
│ │ │ │ Parameters:
│ │ │ │ - rreeccoorrdd__ddaattaa (_bb_yy_tt_ee_ss) – The record_data bytes read from the
│ │ │ │ + rreeccoorrdd__ddaattaa (bbyytteess) – The record_data bytes read from the
│ │ │ │ file
│ │ │ │ record_data_bytes()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the bytes corresponding to the record_data part of the
│ │ │ │ VLR as they should be written in the file.
│ │ │ │ Returns:
│ │ │ │ The bytes of the vlr’s record_data
│ │ │ │ Return type:
│ │ │ │ - _b_y_t_e_s
│ │ │ │ + bytes
│ │ │ │ ssttaattiicc official_record_ids()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official record_id for the VLR
│ │ │ │ Note
│ │ │ │ Even if the VLR has one record_id, the return type must be a tuple
│ │ │ │ Returns:
│ │ │ │ The record_ids this VLR type can have
│ │ │ │ Return type:
│ │ │ │ - _t_u_p_l_e of _i_n_t
│ │ │ │ + tuple of int
│ │ │ │ ssttaattiicc official_user_id()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official user_id as described in the documentation
│ │ │ │ ccllaassssmmeetthhoodd from_raw(rraaww__vvllrr)_[_s_o_u_r_c_e_]_
│ │ │ │ ccllaassss laspy.vlrs.known.GeoKeyEntryStruct_[_s_o_u_r_c_e_]_
│ │ │ │ Bases: Structure
│ │ │ │ ssttaattiicc size()_[_s_o_u_r_c_e_]_
│ │ │ │ count_
│ │ │ │ @@ -259,141 +259,141 @@
│ │ │ │ number_of_keys_
│ │ │ │ Structure/Union member
│ │ │ │ ccllaassss laspy.vlrs.known.GeoKeyDirectoryVlr_[_s_o_u_r_c_e_]_
│ │ │ │ Bases: _B_a_s_e_K_n_o_w_n_V_L_R
│ │ │ │ parse_record_data(rreeccoorrdd__ddaattaa)_[_s_o_u_r_c_e_]_
│ │ │ │ Shall parse the given record_data into a user-friendlier structure
│ │ │ │ Parameters:
│ │ │ │ - rreeccoorrdd__ddaattaa (_bb_yy_tt_ee_ss) – The record_data bytes read from the
│ │ │ │ + rreeccoorrdd__ddaattaa (bbyytteess) – The record_data bytes read from the
│ │ │ │ file
│ │ │ │ record_data_bytes()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the bytes corresponding to the record_data part of the
│ │ │ │ VLR as they should be written in the file.
│ │ │ │ Returns:
│ │ │ │ The bytes of the vlr’s record_data
│ │ │ │ Return type:
│ │ │ │ - _b_y_t_e_s
│ │ │ │ + bytes
│ │ │ │ parse_crs()_[_s_o_u_r_c_e_]_
│ │ │ │ ssttaattiicc official_user_id()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official user_id as described in the documentation
│ │ │ │ ssttaattiicc official_record_ids()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official record_id for the VLR
│ │ │ │ Note
│ │ │ │ Even if the VLR has one record_id, the return type must be a tuple
│ │ │ │ Returns:
│ │ │ │ The record_ids this VLR type can have
│ │ │ │ Return type:
│ │ │ │ - _t_u_p_l_e of _i_n_t
│ │ │ │ + tuple of int
│ │ │ │ ccllaassss laspy.vlrs.known.GeoDoubleParamsVlr_[_s_o_u_r_c_e_]_
│ │ │ │ Bases: _B_a_s_e_K_n_o_w_n_V_L_R
│ │ │ │ Stores all of thedoublevalued GeoKeys.
│ │ │ │ parse_record_data(rreeccoorrdd__ddaattaa)_[_s_o_u_r_c_e_]_
│ │ │ │ Shall parse the given record_data into a user-friendlier structure
│ │ │ │ Parameters:
│ │ │ │ - rreeccoorrdd__ddaattaa (_bb_yy_tt_ee_ss) – The record_data bytes read from the
│ │ │ │ + rreeccoorrdd__ddaattaa (bbyytteess) – The record_data bytes read from the
│ │ │ │ file
│ │ │ │ record_data_bytes()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the bytes corresponding to the record_data part of the
│ │ │ │ VLR as they should be written in the file.
│ │ │ │ Returns:
│ │ │ │ The bytes of the vlr’s record_data
│ │ │ │ Return type:
│ │ │ │ - _b_y_t_e_s
│ │ │ │ + bytes
│ │ │ │ ssttaattiicc official_user_id()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official user_id as described in the documentation
│ │ │ │ ssttaattiicc official_record_ids()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official record_id for the VLR
│ │ │ │ Note
│ │ │ │ Even if the VLR has one record_id, the return type must be a tuple
│ │ │ │ Returns:
│ │ │ │ The record_ids this VLR type can have
│ │ │ │ Return type:
│ │ │ │ - _t_u_p_l_e of _i_n_t
│ │ │ │ + tuple of int
│ │ │ │ ccllaassss laspy.vlrs.known.GeoAsciiParamsVlr_[_s_o_u_r_c_e_]_
│ │ │ │ Bases: _B_a_s_e_K_n_o_w_n_V_L_R
│ │ │ │ Stores all of theASCIIvalued GeoKeys.
│ │ │ │ From GeoTIFF’s spec: To avoid problems with naive tiff dump programs the
│ │ │ │ separator between geokeys is not the null-terminator` but `|.
│ │ │ │ parse_record_data(rreeccoorrdd__ddaattaa)_[_s_o_u_r_c_e_]_
│ │ │ │ Shall parse the given record_data into a user-friendlier structure
│ │ │ │ Parameters:
│ │ │ │ - rreeccoorrdd__ddaattaa (_bb_yy_tt_ee_ss) – The record_data bytes read from the
│ │ │ │ + rreeccoorrdd__ddaattaa (bbyytteess) – The record_data bytes read from the
│ │ │ │ file
│ │ │ │ record_data_bytes()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the bytes corresponding to the record_data part of the
│ │ │ │ VLR as they should be written in the file.
│ │ │ │ Returns:
│ │ │ │ The bytes of the vlr’s record_data
│ │ │ │ Return type:
│ │ │ │ - _b_y_t_e_s
│ │ │ │ + bytes
│ │ │ │ ssttaattiicc official_user_id()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official user_id as described in the documentation
│ │ │ │ ssttaattiicc official_record_ids()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official record_id for the VLR
│ │ │ │ Note
│ │ │ │ Even if the VLR has one record_id, the return type must be a tuple
│ │ │ │ Returns:
│ │ │ │ The record_ids this VLR type can have
│ │ │ │ Return type:
│ │ │ │ - _t_u_p_l_e of _i_n_t
│ │ │ │ + tuple of int
│ │ │ │ ccllaassss laspy.vlrs.known.WktMathTransformVlr_[_s_o_u_r_c_e_]_
│ │ │ │ Bases: _B_a_s_e_K_n_o_w_n_V_L_R
│ │ │ │ From the Spec:
│ │ │ │ Note that the math transform WKT record is added for completeness,
│ │ │ │ and a coordinate system WKT may or may not require a math transform
│ │ │ │ WKT record
│ │ │ │ parse_record_data(rreeccoorrdd__ddaattaa)_[_s_o_u_r_c_e_]_
│ │ │ │ Shall parse the given record_data into a user-friendlier structure
│ │ │ │ Parameters:
│ │ │ │ - rreeccoorrdd__ddaattaa (_bb_yy_tt_ee_ss) – The record_data bytes read from the
│ │ │ │ + rreeccoorrdd__ddaattaa (bbyytteess) – The record_data bytes read from the
│ │ │ │ file
│ │ │ │ record_data_bytes()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the bytes corresponding to the record_data part of the
│ │ │ │ VLR as they should be written in the file.
│ │ │ │ Returns:
│ │ │ │ The bytes of the vlr’s record_data
│ │ │ │ Return type:
│ │ │ │ - _b_y_t_e_s
│ │ │ │ + bytes
│ │ │ │ ssttaattiicc official_user_id()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official user_id as described in the documentation
│ │ │ │ ssttaattiicc official_record_ids()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official record_id for the VLR
│ │ │ │ Note
│ │ │ │ Even if the VLR has one record_id, the return type must be a tuple
│ │ │ │ Returns:
│ │ │ │ The record_ids this VLR type can have
│ │ │ │ Return type:
│ │ │ │ - _t_u_p_l_e of _i_n_t
│ │ │ │ + tuple of int
│ │ │ │ ccllaassss laspy.vlrs.known.WktCoordinateSystemVlr(wwkktt__ssttrriinngg=='''')_[_s_o_u_r_c_e_]_
│ │ │ │ Bases: _B_a_s_e_K_n_o_w_n_V_L_R
│ │ │ │ Replaces Coordinates Reference System for new las files (point fmt >= 5)
│ │ │ │ “LAS is not using the “ESRI WKT”
│ │ │ │ parse_record_data(rreeccoorrdd__ddaattaa)_[_s_o_u_r_c_e_]_
│ │ │ │ Shall parse the given record_data into a user-friendlier structure
│ │ │ │ Parameters:
│ │ │ │ - rreeccoorrdd__ddaattaa (_bb_yy_tt_ee_ss) – The record_data bytes read from the
│ │ │ │ + rreeccoorrdd__ddaattaa (bbyytteess) – The record_data bytes read from the
│ │ │ │ file
│ │ │ │ record_data_bytes()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the bytes corresponding to the record_data part of the
│ │ │ │ VLR as they should be written in the file.
│ │ │ │ Returns:
│ │ │ │ The bytes of the vlr’s record_data
│ │ │ │ Return type:
│ │ │ │ - _b_y_t_e_s
│ │ │ │ + bytes
│ │ │ │ parse_crs()_[_s_o_u_r_c_e_]_
│ │ │ │ ssttaattiicc official_user_id()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official user_id as described in the documentation
│ │ │ │ ssttaattiicc official_record_ids()_[_s_o_u_r_c_e_]_
│ │ │ │ Shall return the official record_id for the VLR
│ │ │ │ Note
│ │ │ │ Even if the VLR has one record_id, the return type must be a tuple
│ │ │ │ Returns:
│ │ │ │ The record_ids this VLR type can have
│ │ │ │ Return type:
│ │ │ │ - _t_u_p_l_e of _i_n_t
│ │ │ │ + tuple of int
│ │ │ │ laspy.vlrs.known.vlr_factory(vvllrr:: _VV_LL_RR)_[_s_o_u_r_c_e_]_
│ │ │ │ Given a vlr tries to find its corresponding KnownVLR class that can parse
│ │ │ │ its data. If no KnownVLR implementation is found, returns the input vlr
│ │ │ │ unchanged
│ │ │ │ _P_r_e_v_i_o_u_s _N_e_x_t
│ │ │ │ ===============================================================================
│ │ │ │ © Copyright 2018-2024, laspy.
│ │ ├── ./usr/share/doc/python-laspy-doc/html/api/laspy.vlrs.vlr.html
│ │ │ @@ -127,38 +127,38 @@
│ │ │ 'MyUserId'
│ │ │ >>> int.from_bytes(my_vlr.record_data, byteorder='little')
│ │ │ 42
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ -record_data: bytes
│ │ │ +record_data: bytes
│ │ │ The record_data as bytes, length cannot exceed 65_535
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ -record_data_bytes() → bytes[source]
│ │ │ +record_data_bytes() → bytes[source]
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ -property description: str | bytes
│ │ │ +property description: str | bytes
│ │ │ The description, cannot exceed 32 bytes
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ -property record_id: int
│ │ │ +property record_id: int
│ │ │ The record id
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ -property user_id: str
│ │ │ +property user_id: str
│ │ │ The user id
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ ├── html2text {}
│ │ │ │ @@ -44,20 +44,20 @@
│ │ │ │ ... description="An Example VLR",
│ │ │ │ ... record_data=int(42).to_bytes(8, byteorder='little'),
│ │ │ │ ... )
│ │ │ │ >>> my_vlr.user_id
│ │ │ │ 'MyUserId'
│ │ │ │ >>> int.from_bytes(my_vlr.record_data, byteorder='little')
│ │ │ │ 42
│ │ │ │ - record_data:: _bb_yy_tt_ee_ss_
│ │ │ │ + record_data:: bbyytteess_
│ │ │ │ The record_data as bytes, length cannot exceed 65_535
│ │ │ │ - record_data_bytes() → _b_y_t_e_s_[_s_o_u_r_c_e_]_
│ │ │ │ - pprrooppeerrttyy description:: _ss_tt_rr || _bb_yy_tt_ee_ss_
│ │ │ │ + record_data_bytes() → bytes_[_s_o_u_r_c_e_]_
│ │ │ │ + pprrooppeerrttyy description:: ssttrr || bbyytteess_
│ │ │ │ The description, cannot exceed 32 bytes
│ │ │ │ - pprrooppeerrttyy record_id:: _ii_nn_tt_
│ │ │ │ + pprrooppeerrttyy record_id:: iinntt_
│ │ │ │ The record id
│ │ │ │ - pprrooppeerrttyy user_id:: _ss_tt_rr_
│ │ │ │ + pprrooppeerrttyy user_id:: ssttrr_
│ │ │ │ The user id
│ │ │ │ _P_r_e_v_i_o_u_s _N_e_x_t
│ │ │ │ ===============================================================================
│ │ │ │ © Copyright 2018-2024, laspy.
│ │ │ │ Built with _S_p_h_i_n_x using a _t_h_e_m_e provided by _R_e_a_d_ _t_h_e_ _D_o_c_s.
│ │ ├── ./usr/share/doc/python-laspy-doc/html/api/laspy.vlrs.vlrlist.html
│ │ │ @@ -112,19 +112,19 @@
│ │ │
│ │ │
│ │ │
│ │ │ laspy.vlrs.vlrlist module
│ │ │
│ │ │ -
│ │ │ class laspy.vlrs.vlrlist.VLRList(*args, **kwargs)[source]
│ │ │ -Bases: list
│ │ │ +Bases: list
│ │ │ Class responsible for managing the vlrs
│ │ │
│ │ │ -
│ │ │ -index(value, start: int = 0, stop: int = None) → int[source]
│ │ │ +index(value, start: int = 0, stop: int = None) → int[source]
│ │ │ Return first index of value.
│ │ │ Raises ValueError if the value is not present.
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ get_by_id(user_id='', record_ids=(None,))[source]
│ │ │ @@ -145,30 +145,30 @@
│ │ │ >>> las.vlrs.get_by_id(ExtraBytesVlr.official_user_id())[0]
│ │ │ <ExtraBytesVlr(extra bytes structs: 5)>
│ │ │
│ │ │
│ │ │
│ │ │ - Parameters:
│ │ │
│ │ │ -user_id (str, optional) – the user id
│ │ │ -record_ids (iterable of int, optional) – THe record ids of the vlr(s) you wish to get
│ │ │ +user_id (str, optional) – the user id
│ │ │ +record_ids (iterable of int, optional) – THe record ids of the vlr(s) you wish to get
│ │ │
│ │ │
│ │ │ - Returns:
│ │ │ a list of vlrs matching the user_id and records_ids
│ │ │
│ │ │ - Return type:
│ │ │ -list
│ │ │ +list
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ -get(vlr_type: str) → List[IKnownVLR][source]
│ │ │ +get(vlr_type: str) → List[IKnownVLR][source]
│ │ │ Returns the list of vlrs of the requested type
│ │ │ Always returns a list even if there is only one VLR of type vlr_type.
│ │ │ >>> import laspy
│ │ │ >>> las = laspy.read("tests/data/extrabytes.las")
│ │ │ >>> las.vlrs
│ │ │ [<ExtraBytesVlr(extra bytes structs: 5)>]
│ │ │ >>> las.vlrs.get("WktCoordinateSystemVlr")
│ │ │ @@ -180,67 +180,67 @@
│ │ │ [<ExtraBytesVlr(extra bytes structs: 5)>]
│ │ │ >>> las.vlrs.get('ExtraBytesVlr')[0]
│ │ │ <ExtraBytesVlr(extra bytes structs: 5)>
│ │ │
│ │ │
│ │ │
│ │ │ - Parameters:
│ │ │ -vlr_type (str) – the class name of the vlr
│ │ │ +vlr_type (str) – the class name of the vlr
│ │ │
│ │ │ - Returns:
│ │ │ a List of vlrs matching the user_id and records_ids
│ │ │
│ │ │ - Return type:
│ │ │ -list
│ │ │ +list
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ +extract(vlr_type: str) → List[IKnownVLR][source]
│ │ │ Returns the list of vlrs of the requested type
│ │ │ The difference with get is that the returned vlrs will be removed from the list
│ │ │
│ │ │ - Parameters:
│ │ │ -vlr_type (str) – the class name of the vlr
│ │ │ +vlr_type (str) – the class name of the vlr
│ │ │
│ │ │ - Returns:
│ │ │ a List of vlrs matching the user_id and records_ids
│ │ │
│ │ │ - Return type:
│ │ │ -list
│ │ │ +list
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ -classmethod read_from(data_stream: BinaryIO, num_to_read: int, extended: bool = False) → VLRList[source]
│ │ │ +classmethod read_from(data_stream: BinaryIO, num_to_read: int, extended: bool = False) → VLRList[source]
│ │ │ Reads vlrs and parse them if possible from the stream
│ │ │
│ │ │ - Parameters:
│ │ │
│ │ │ -data_stream (io.BytesIO) – stream to read from
│ │ │ -num_to_read (int) – number of vlrs to be read
│ │ │ -extended (bool) – whether the vlrs are regular vlr or extended vlr
│ │ │ +data_stream (io.BytesIO) – stream to read from
│ │ │ +num_to_read (int) – number of vlrs to be read
│ │ │ +extended (bool) – whether the vlrs are regular vlr or extended vlr
│ │ │
│ │ │
│ │ │ - Returns:
│ │ │ List of vlrs
│ │ │
│ │ │ - Return type:
│ │ │ laspy.vlrs.vlrlist.VLRList
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ -
│ │ │ -write_to(stream: BinaryIO, as_extended: bool = False, encoding_errors: str = 'strict') → int[source]
│ │ │ +write_to(stream: BinaryIO, as_extended: bool = False, encoding_errors: str = 'strict') → int[source]
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │
│ │ │ ├── html2text {}
│ │ │ │ @@ -33,17 +33,17 @@
│ │ │ │ _l_a_s_p_y
│ │ │ │ * _A_P_I_ _D_o_c_u_m_e_n_t_a_t_i_o_n
│ │ │ │ * laspy.vlrs.vlrlist module
│ │ │ │ * _V_i_e_w_ _p_a_g_e_ _s_o_u_r_c_e
│ │ │ │ ===============================================================================
│ │ │ │ ************ llaassppyy..vvllrrss..vvllrrlliisstt mmoodduullee_? ************
│ │ │ │ ccllaassss laspy.vlrs.vlrlist.VLRList(**aarrggss, ****kkwwaarrggss)_[_s_o_u_r_c_e_]_
│ │ │ │ - Bases: _l_i_s_t
│ │ │ │ + Bases: list
│ │ │ │ Class responsible for managing the vlrs
│ │ │ │ - index(vvaalluuee, ssttaarrtt:: _ii_nn_tt == 00, ssttoopp:: _ii_nn_tt == NNoonnee) → _i_n_t_[_s_o_u_r_c_e_]_
│ │ │ │ + index(vvaalluuee, ssttaarrtt:: iinntt == 00, ssttoopp:: iinntt == NNoonnee) → int_[_s_o_u_r_c_e_]_
│ │ │ │ Return first index of value.
│ │ │ │ Raises ValueError if the value is not present.
│ │ │ │ get_by_id(uusseerr__iidd=='''', rreeccoorrdd__iiddss==((NNoonnee,,)))_[_s_o_u_r_c_e_]_
│ │ │ │ Function to get vlrs by user_id and/or record_ids. Always returns a
│ │ │ │ list even if only one vlr matches the user_id and record_id
│ │ │ │ >>> import laspy
│ │ │ │ >>> from laspy.vlrs.known import ExtraBytesVlr,
│ │ │ │ @@ -57,22 +57,22 @@
│ │ │ │ Traceback (most recent call last):
│ │ │ │ IndexError: list index out of range
│ │ │ │ >>> las.vlrs.get_by_id(ExtraBytesVlr.official_user_id())
│ │ │ │ [
]
│ │ │ │ >>> las.vlrs.get_by_id(ExtraBytesVlr.official_user_id())[0]
│ │ │ │
│ │ │ │ Parameters:
│ │ │ │ - * uusseerr__iidd (_ss_tt_rr,, ooppttiioonnaall) – the user id
│ │ │ │ - * rreeccoorrdd__iiddss (iitteerraabbllee ooff _ii_nn_tt,, ooppttiioonnaall) – THe record ids
│ │ │ │ + * uusseerr__iidd (ssttrr,, ooppttiioonnaall) – the user id
│ │ │ │ + * rreeccoorrdd__iiddss (iitteerraabbllee ooff iinntt,, ooppttiioonnaall) – THe record ids
│ │ │ │ of the vlr(s) you wish to get
│ │ │ │ Returns:
│ │ │ │ a list of vlrs matching the user_id and records_ids
│ │ │ │ Return type:
│ │ │ │ - _l_i_s_t
│ │ │ │ - get(vvllrr__ttyyppee:: _ss_tt_rr) → _L_i_s_t[_I_K_n_o_w_n_V_L_R]_[_s_o_u_r_c_e_]_
│ │ │ │ + list
│ │ │ │ + get(vvllrr__ttyyppee:: ssttrr) → List[_I_K_n_o_w_n_V_L_R]_[_s_o_u_r_c_e_]_
│ │ │ │ Returns the list of vlrs of the requested type Always returns a
│ │ │ │ list even if there is only one VLR of type vlr_type.
│ │ │ │ >>> import laspy
│ │ │ │ >>> las = laspy.read("tests/data/extrabytes.las")
│ │ │ │ >>> las.vlrs
│ │ │ │ []
│ │ │ │ >>> las.vlrs.get("WktCoordinateSystemVlr")
│ │ │ │ @@ -81,39 +81,39 @@
│ │ │ │ Traceback (most recent call last):
│ │ │ │ IndexError: list index out of range
│ │ │ │ >>> las.vlrs.get('ExtraBytesVlr')
│ │ │ │ []
│ │ │ │ >>> las.vlrs.get('ExtraBytesVlr')[0]
│ │ │ │
│ │ │ │ Parameters:
│ │ │ │ - vvllrr__ttyyppee (_ss_tt_rr) – the class name of the vlr
│ │ │ │ + vvllrr__ttyyppee (ssttrr) – the class name of the vlr
│ │ │ │ Returns:
│ │ │ │ a List of vlrs matching the user_id and records_ids
│ │ │ │ Return type:
│ │ │ │ - _l_i_s_t
│ │ │ │ - extract(vvllrr__ttyyppee:: _ss_tt_rr) → _L_i_s_t[_I_K_n_o_w_n_V_L_R]_[_s_o_u_r_c_e_]_
│ │ │ │ + list
│ │ │ │ + extract(vvllrr__ttyyppee:: ssttrr) → List[_I_K_n_o_w_n_V_L_R]_[_s_o_u_r_c_e_]_
│ │ │ │ Returns the list of vlrs of the requested type The difference with
│ │ │ │ get is that the returned vlrs will be removed from the list
│ │ │ │ Parameters:
│ │ │ │ - vvllrr__ttyyppee (_ss_tt_rr) – the class name of the vlr
│ │ │ │ + vvllrr__ttyyppee (ssttrr) – the class name of the vlr
│ │ │ │ Returns:
│ │ │ │ a List of vlrs matching the user_id and records_ids
│ │ │ │ Return type:
│ │ │ │ - _l_i_s_t
│ │ │ │ - ccllaassssmmeetthhoodd read_from(ddaattaa__ssttrreeaamm:: _BB_ii_nn_aa_rr_yy_II_OO, nnuumm__ttoo__rreeaadd:: _ii_nn_tt,
│ │ │ │ - eexxtteennddeedd:: _bb_oo_oo_ll == FFaallssee) → _V_L_R_L_i_s_t_[_s_o_u_r_c_e_]_
│ │ │ │ + list
│ │ │ │ + ccllaassssmmeetthhoodd read_from(ddaattaa__ssttrreeaamm:: BBiinnaarryyIIOO, nnuumm__ttoo__rreeaadd:: iinntt,
│ │ │ │ + eexxtteennddeedd:: bbooooll == FFaallssee) → _V_L_R_L_i_s_t_[_s_o_u_r_c_e_]_
│ │ │ │ Reads vlrs and parse them if possible from the stream
│ │ │ │ Parameters:
│ │ │ │ - * ddaattaa__ssttrreeaamm (_ii_oo_.._BB_yy_tt_ee_ss_II_OO) – stream to read from
│ │ │ │ - * nnuumm__ttoo__rreeaadd (_ii_nn_tt) – number of vlrs to be read
│ │ │ │ - * eexxtteennddeedd (_bb_oo_oo_ll) – whether the vlrs are regular vlr or
│ │ │ │ + * ddaattaa__ssttrreeaamm (iioo..BByytteessIIOO) – stream to read from
│ │ │ │ + * nnuumm__ttoo__rreeaadd (iinntt) – number of vlrs to be read
│ │ │ │ + * eexxtteennddeedd (bbooooll) – whether the vlrs are regular vlr or
│ │ │ │ extended vlr
│ │ │ │ Returns:
│ │ │ │ List of vlrs
│ │ │ │ Return type:
│ │ │ │ _l_a_s_p_y_._v_l_r_s_._v_l_r_l_i_s_t_._V_L_R_L_i_s_t
│ │ │ │ - write_to(ssttrreeaamm:: _BB_ii_nn_aa_rr_yy_II_OO, aass__eexxtteennddeedd:: _bb_oo_oo_ll == FFaallssee, eennccooddiinngg__eerrrroorrss::
│ │ │ │ - _ss_tt_rr == ''ssttrriicctt'') → _i_n_t_[_s_o_u_r_c_e_]_
│ │ │ │ + write_to(ssttrreeaamm:: BBiinnaarryyIIOO, aass__eexxtteennddeedd:: bbooooll == FFaallssee, eennccooddiinngg__eerrrroorrss::
│ │ │ │ + ssttrr == ''ssttrriicctt'') → int_[_s_o_u_r_c_e_]_
│ │ │ │ _P_r_e_v_i_o_u_s _N_e_x_t
│ │ │ │ ===============================================================================
│ │ │ │ © Copyright 2018-2024, laspy.
│ │ │ │ Built with _S_p_h_i_n_x using a _t_h_e_m_e provided by _R_e_a_d_ _t_h_e_ _D_o_c_s.
│ │ ├── ./usr/share/doc/python-laspy-doc/html/searchindex.js
│ │ │ ├── js-beautify {}
│ │ │ │ @@ -1921,14 +1921,15 @@
│ │ │ │ "149": 17,
│ │ │ │ "15": [6, 11, 20, 21],
│ │ │ │ "150": 6,
│ │ │ │ "1503": 20,
│ │ │ │ "152": 17,
│ │ │ │ "158": 17,
│ │ │ │ "16": [1, 13, 16, 21, 23, 24],
│ │ │ │ + "160": 2,
│ │ │ │ "17": [12, 17, 20],
│ │ │ │ "18": 21,
│ │ │ │ "19": 21,
│ │ │ │ "1_000_000": 16,
│ │ │ │ "1_234_567": 16,
│ │ │ │ "2": [0, 1, 2, 4, 6, 8, 10, 11, 12, 13, 16, 18, 20, 21, 22, 24],
│ │ │ │ "20": [6, 20, 21],
│ │ │ │ @@ -1948,15 +1949,15 @@
│ │ │ │ "25": [20, 21],
│ │ │ │ "256": 1,
│ │ │ │ "27": 25,
│ │ │ │ "28": 21,
│ │ │ │ "29": 21,
│ │ │ │ "2d": [2, 6, 20],
│ │ │ │ "3": [0, 4, 6, 9, 10, 11, 12, 16, 18, 20, 21, 24, 25],
│ │ │ │ - "30": [2, 6, 21],
│ │ │ │ + "30": [6, 21],
│ │ │ │ "300": 6,
│ │ │ │ "31": [11, 17],
│ │ │ │ "32": [1, 14, 17, 23, 24],
│ │ │ │ "33": 25,
│ │ │ │ "34": 11,
│ │ │ │ "3d": 23,
│ │ │ │ "3f8": 24,