laspy


Namelaspy JSON
Version 2.5.4 PyPI version JSON
download
home_pagehttps://github.com/laspy/laspy
SummaryNative Python ASPRS LAS read/write library
upload_time2024-06-19 17:31:12
maintainerNone
docs_urlhttps://pythonhosted.org/laspy/
authorGrant Brown, Thomas Montaigu
requires_python>=3.8
licenseBSD
keywords gis lidar las
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage
            # Laspy

Laspy is a python library for reading, modifying and creating LAS LiDAR
files.

Laspy is compatible with Python  3.8+.

## Features

- LAS support.
- LAZ support via `lazrs` or `laszip` backend.
- LAS/LAZ streamed/chunked reading/writting.
- [COPC] support over files.
- [COPC] support over https with `requests` package.
- CRS support via `pyproj` package.


[COPC]: https://github.com/copcio/copcio.github.io


## Examples

Directly read and write las
```Python
import laspy

las = laspy.read('filename.las')
las.points = las.points[las.classification == 2]
las.write('ground.laz')
```


Open data to inspect header (opening only reads the header and vlrs)

```Python
import laspy

with laspy.open('filename.las') as f:
    print(f"Point format:       {f.header.point_format}")
    print(f"Number of points:   {f.header.point_count}")
    print(f"Number of vlrs:     {len(f.header.vlrs)}")
```
Use the 'chunked' reading & writing features

```Python
import laspy

with laspy.open('big.laz') as input_las:
    with laspy.open('ground.laz', mode="w", header=input_las.header) as ground_las:
        for points in input_las.chunk_iterator(2_000_000):
            ground_las.write_points(points[points.classification == 2])

```

Appending points to existing file

```Python
import laspy

with laspy.open('big.laz') as input_las:
    with laspy.open('ground.laz', mode="a") as ground_las:
        for points in input_las.chunk_iterator(2_000_000):
            ground_las.append_points(points[points.classification == 2])
```

API Documentation and tutorials are available at
[ReadTheDocs](https://laspy.readthedocs.io/en/latest/).

## Installation

Laspy can be installed either with `pip`:

```
pip install laspy # without LAZ support
# Or
pip install laspy[laszip] # with LAZ support via LASzip
# Or
pip install laspy[lazrs] # with LAZ support via lazrs
```

## Changelog

See [CHANGELOG.md](CHANGELOG.md)

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/laspy/laspy",
    "name": "laspy",
    "maintainer": null,
    "docs_url": "https://pythonhosted.org/laspy/",
    "requires_python": ">=3.8",
    "maintainer_email": null,
    "keywords": "gis lidar las",
    "author": "Grant Brown, Thomas Montaigu",
    "author_email": "grant.brown73@gmail.com, thomas.montaigu@laposte.net",
    "download_url": "https://files.pythonhosted.org/packages/07/62/d0ff891cba131f2643ee0152205b1d2eb9634fc690bb456ca87c06f645d4/laspy-2.5.4.tar.gz",
    "platform": null,
    "description": "# Laspy\n\nLaspy is a python library for reading, modifying and creating LAS LiDAR\nfiles.\n\nLaspy is compatible with Python  3.8+.\n\n## Features\n\n- LAS support.\n- LAZ support via `lazrs` or `laszip` backend.\n- LAS/LAZ streamed/chunked reading/writting.\n- [COPC] support over files.\n- [COPC] support over https with `requests` package.\n- CRS support via `pyproj` package.\n\n\n[COPC]: https://github.com/copcio/copcio.github.io\n\n\n## Examples\n\nDirectly read and write las\n```Python\nimport laspy\n\nlas = laspy.read('filename.las')\nlas.points = las.points[las.classification == 2]\nlas.write('ground.laz')\n```\n\n\nOpen data to inspect header (opening only reads the header and vlrs)\n\n```Python\nimport laspy\n\nwith laspy.open('filename.las') as f:\n    print(f\"Point format:       {f.header.point_format}\")\n    print(f\"Number of points:   {f.header.point_count}\")\n    print(f\"Number of vlrs:     {len(f.header.vlrs)}\")\n```\nUse the 'chunked' reading & writing features\n\n```Python\nimport laspy\n\nwith laspy.open('big.laz') as input_las:\n    with laspy.open('ground.laz', mode=\"w\", header=input_las.header) as ground_las:\n        for points in input_las.chunk_iterator(2_000_000):\n            ground_las.write_points(points[points.classification == 2])\n\n```\n\nAppending points to existing file\n\n```Python\nimport laspy\n\nwith laspy.open('big.laz') as input_las:\n    with laspy.open('ground.laz', mode=\"a\") as ground_las:\n        for points in input_las.chunk_iterator(2_000_000):\n            ground_las.append_points(points[points.classification == 2])\n```\n\nAPI Documentation and tutorials are available at\n[ReadTheDocs](https://laspy.readthedocs.io/en/latest/).\n\n## Installation\n\nLaspy can be installed either with `pip`:\n\n```\npip install laspy # without LAZ support\n# Or\npip install laspy[laszip] # with LAZ support via LASzip\n# Or\npip install laspy[lazrs] # with LAZ support via lazrs\n```\n\n## Changelog\n\nSee [CHANGELOG.md](CHANGELOG.md)\n",
    "bugtrack_url": null,
    "license": "BSD",
    "summary": "Native Python ASPRS LAS read/write library",
    "version": "2.5.4",
    "project_urls": {
        "Homepage": "https://github.com/laspy/laspy"
    },
    "split_keywords": [
        "gis",
        "lidar",
        "las"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "bc648be19bc661fe6281b1c9343f9caa18e187ddc9506abb20b0110e0d7eaed5",
                "md5": "c7ba0b4c74e2f50b8a3f8c2cd521b340",
                "sha256": "5fc37a8a1a5e22c98bad4123281b55e5e41784943ca251828d72c932b167583e"
            },
            "downloads": -1,
            "filename": "laspy-2.5.4-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "c7ba0b4c74e2f50b8a3f8c2cd521b340",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8",
            "size": 84254,
            "upload_time": "2024-06-19T17:32:22",
            "upload_time_iso_8601": "2024-06-19T17:32:22.276030Z",
            "url": "https://files.pythonhosted.org/packages/bc/64/8be19bc661fe6281b1c9343f9caa18e187ddc9506abb20b0110e0d7eaed5/laspy-2.5.4-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "0762d0ff891cba131f2643ee0152205b1d2eb9634fc690bb456ca87c06f645d4",
                "md5": "8e02bf4a57e2cb1fcf144156f94bc64f",
                "sha256": "eebdbf3379afbc0b24e7e4812fac567bff880d1e851f70175d22375aaecdf7e1"
            },
            "downloads": -1,
            "filename": "laspy-2.5.4.tar.gz",
            "has_sig": false,
            "md5_digest": "8e02bf4a57e2cb1fcf144156f94bc64f",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8",
            "size": 1563243,
            "upload_time": "2024-06-19T17:31:12",
            "upload_time_iso_8601": "2024-06-19T17:31:12.491798Z",
            "url": "https://files.pythonhosted.org/packages/07/62/d0ff891cba131f2643ee0152205b1d2eb9634fc690bb456ca87c06f645d4/laspy-2.5.4.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-06-19 17:31:12",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "laspy",
    "github_project": "laspy",
    "travis_ci": false,
    "coveralls": true,
    "github_actions": true,
    "lcname": "laspy"
}
        
Elapsed time: 0.65560s