streamstats_access: Python access to the USGS Streamstats API
Overview
This library provides users access to functionality of the USGS StreamStats application from within Python. The StreamStats app includes a suite of GIS-based hydrologic tools that are useful for water resources planning/management, engineering, and design purposes.
NOTE: This is a community package and has no affiliation the U.S. Geological Survey, Web Informatics and Mapping team, or StreamStats team. While efforts have been made to mimic Batch Processor functionality and formats, results received from this package may differ from results returned by the StreamStats Batch Processor. The Batch Processor contains additional features and technicalities that may not be represented in this package.
Key Features
- Watershed Delineation: Use streamStats GIS services to delineate watershed polygons from an outlet point.
- Basin Characteristics: Retrieve basin characteristics such as drainage area, percent wetlands, slope, mean annual precipitation, etc from a delineated watershed.
- Flow Statistics: Use basin characteristics to derive USGS flow frequency estimates.
- A Better Batch Point Tool: Submit large batches of points at once. This library mimics the functionality of the StreamStats batch tool.
- Avoid the 250 point limit of the USGS Streamstats Batch Tool.
- The library implements asynchronous requests offering 2x speed compared to the batch tool.
- Avoid the queue. The library directly queries USGS API endpoints, meaning you don't need to wait in the batch point queue.
Installation
To install this package, use pip:
- Pip Installation:
pip install streamstats-access
- Anaconda Installation (coming soon!):
# conda install conda_forge:streamstats_access
Example Usage
See samples folder for data and scripts.
import streamstats_access as ssa
import os
IN_PATH = os.path.join(os.path.dirname(__file__), 'vt_test.gpkg')
OUT_PATH = os.path.join(os.path.dirname(__file__), 'out_pts.gpkg')
ssa.process_batch(IN_PATH, OUT_PATH, rcode='VT', unique_field='UID')
License
This project is licensed under the MIT License - see the LICENSE file for details.
Contact
For any questions or issues, please direct inquiries to Scott Lawson(Scott.Lawson@uvm.edu).
Release files for streamstats-access 0.1.9
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| streamstats_access-0.1.9.tar.gz | 11.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| streamstats_access-0.1.9-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 24.4 kB
Release files / streamstats_access-0.1.9.tar.gz
| Download URL | streamstats_access-0.1.9.tar.gz |
|---|---|
| Size | 11.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
2b81b7108501f9adce353eddffc57a5b97d5d7feac1dd79cd05783389130e9c2
|
|
BLAKE2b-256 checksum How to use checksums |
1187bdffb0c0b3221bd20f5345a3b28ba9bc42f9a02fc2fcf2b95d65cb29a030
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.0 CPython/3.10.9
|
Release files / streamstats_access-0.1.9-py3-none-any.whl
| Download URL | streamstats_access-0.1.9-py3-none-any.whl |
|---|---|
| Size | 12.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
987b8b8d981392e165a799d6b4f4d42b436be7521357104d7f0e9428ca5fb87d
|
|
BLAKE2b-256 checksum How to use checksums |
fc60439a8eae7392c2765dfa3396f4f3c9f49d85df91e01c99fe72f4368a4808
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.0 CPython/3.10.9
|