Metadata-Version: 2.4
Name: prism-lidarcloud
Version: 1.0.3
Summary: Official Python client + CLI for PRISM LiDAR Cloud — one call turns raw LiDAR into a survey-grade deliverable set: DEM/DSM/CHM, classified cloud, per-cell uncertainty, automatic co-registration, change detection, true-colour drape, CAD bundle, and an AI-assisted accuracy report.
Author: PRISM LiDAR Cloud
License: MIT
Project-URL: Homepage, https://lidarcloud.app
Project-URL: Documentation, https://app.lidarcloud.app/docs/api
Keywords: lidar,dem,dsm,chm,point-cloud,gis,remote-sensing,geospatial
Classifier: Programming Language :: Python :: 3
Classifier: License :: OSI Approved :: MIT License
Classifier: Topic :: Scientific/Engineering :: GIS
Requires-Python: >=3.8
Description-Content-Type: text/markdown

# prism-lidarcloud

Official Python client + CLI for the [PRISM LiDAR Cloud](https://lidarcloud.app) REST API — one
call turns raw airborne/UAV LiDAR (`.las`/`.laz`) into a complete, survey-grade deliverable set.
A single upload runs the full automated cloud pipeline:

- **Automatic co-registration** — double-round (H→V→H→V) alignment to USGS 3DEP or your own reference
- **Bare-earth DEM, DSM, and canopy height model** (GeoTIFF, to 25 cm) + a **per-cell uncertainty** raster
- **8-class ASPRS classified point cloud** — ground · vegetation · building · water · road · power line
- **NAVD88 (GEOID18)** rigorous orthometric heights by default — or WGS84 ellipsoidal
- **Two-epoch change detection** — erosion / deposition / canopy gain-loss vs a prior survey or 3DEP
- **True-colour drape** for camera-less clouds, from near-flight-time public imagery (NAIP / Sentinel-2)
- **CAD / survey bundle** — DXF + LandXML in the correct State Plane ftUS zone
- **AI-assisted accuracy report** (ASPRS 2014 & 2023) with an independent USGS 3DEP cross-check
- Reproducible **to the byte**

Zero dependencies (Python standard library only).

## Install

```bash
pip install prism-lidarcloud
```

Zero dependencies — pure standard library. You get the `prism` CLI on your `PATH` and the
`prism_lidarcloud` Python package.

## Get an API key

Sign in at <https://app.lidarcloud.app>, click your email → **API access** → **Create API key**.
The key (`prism_live_…`) is shown once — copy it. Keep it secret; it carries your account's quota
and billing.

```bash
export PRISM_API_KEY=prism_live_xxxxxxxxxxxx
```

## CLI

```bash
# one shot: upload, wait, download the product zip
prism run scan.las --align 3dep --out products.zip

# a path with spaces (quote it; Windows or POSIX)
prism run "C:\surveys\site_42.las" --align 3dep --out site_42_products.zip

# step by step
prism submit scan.las --align 3dep            # prints {job_id, status_url, ...}
prism status <job_id>
prism download <job_id> -o products.zip
prism jobs                                     # list your jobs
```

Common flags: `--align none|3dep|upload|existing`, `--reference other.las` (paired change
detection), `--no-change`, `--no-classify`, `--no-report`, `--no-cad`, `--dem-res 25cm`,
`--colorize auto|on|off`, `--colorize-source auto|sentinel|naip|fusion` (true-colour drape for
no-RGB clouds), `--vdatum ellipsoidal` (output is **NAVD88** via GEOID18 by default; pass this to
keep WGS84 ellipsoidal heights instead).

## Python

```python
from prism_lidarcloud import Client

c = Client()                                   # reads PRISM_API_KEY
out = c.run("scan.las", out="products.zip", align="3dep", change=True)
print("saved", out)

# or control each step
job = c.submit("scan.las", align="3dep")
final = c.wait(job["job_id"], on_progress=lambda d: print(d["status"], d["pct"]))
c.download(job["job_id"], "products.zip")
```

## What you get back

A `.zip` containing the bare-earth **DEM**, **DSM**, **CHM**, **DEM uncertainty** rasters
(GeoTIFF), the classified point cloud, the AOI boundary, and — unless disabled — the **accuracy
report** (Word) and **CAD bundle** (DXF + LandXML). Paired/3DEP runs add alignment + change-detection
products.

## Notes

- Jobs run on ephemeral cloud workers; `wait()` polls until `done`/`error`.
- API jobs consume the same account quota as the web app and appear in your usage console tagged
  **API** (vs **web**).
- Full reference: <https://app.lidarcloud.app/docs/api>
