{"id":31531505,"url":"https://github.com/hyriver/seamless-3dep","last_synced_at":"2025-10-04T02:12:55.830Z","repository":{"id":271471142,"uuid":"907111629","full_name":"hyriver/seamless-3dep","owner":"hyriver","description":"Topographic map retrieval from 3DEP","archived":false,"fork":false,"pushed_at":"2025-09-01T14:43:26.000Z","size":25181,"stargazers_count":13,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-09-25T10:58:42.250Z","etag":null,"topics":["elevation","hydrology","python","topographic-maps"],"latest_commit_sha":null,"homepage":"https://seamless-3dep.readthedocs.io","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hyriver.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":"AUTHORS.md","dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2024-12-22T20:55:08.000Z","updated_at":"2025-09-05T15:46:45.000Z","dependencies_parsed_at":"2025-02-24T01:27:05.178Z","dependency_job_id":"3dfaeaae-02dc-482f-9a86-f501d1ef59ac","html_url":"https://github.com/hyriver/seamless-3dep","commit_stats":null,"previous_names":["hyriver/seamless-3dep"],"tags_count":7,"template":false,"template_full_name":null,"purl":"pkg:github/hyriver/seamless-3dep","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hyriver%2Fseamless-3dep","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hyriver%2Fseamless-3dep/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hyriver%2Fseamless-3dep/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hyriver%2Fseamless-3dep/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hyriver","download_url":"https://codeload.github.com/hyriver/seamless-3dep/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hyriver%2Fseamless-3dep/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":278254466,"owners_count":25956604,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-10-04T02:00:05.491Z","response_time":63,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["elevation","hydrology","python","topographic-maps"],"created_at":"2025-10-04T02:12:54.567Z","updated_at":"2025-10-04T02:12:55.807Z","avatar_url":"https://github.com/hyriver.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Seamless3DEP: Streamlined Access to USGS 3DEP Topographic Data\n\n[![PyPi](https://img.shields.io/pypi/v/seamless-3dep.svg)](https://pypi.python.org/pypi/seamless-3dep)\n[![Conda Version](https://img.shields.io/conda/vn/conda-forge/seamless-3dep.svg)](https://anaconda.org/conda-forge/seamless-3dep)\n[![CodeCov](https://codecov.io/gh/hyriver/seamless-3dep/branch/main/graph/badge.svg)](https://codecov.io/gh/hyriver/seamless-3dep)\n[![Python Versions](https://img.shields.io/pypi/pyversions/seamless-3dep.svg)](https://pypi.python.org/pypi/seamless-3dep)\n[![Downloads](https://static.pepy.tech/badge/seamless-3dep)](https://pepy.tech/project/seamless-3dep)\n\n[![CodeFactor](https://www.codefactor.io/repository/github/hyriver/seamless-3dep/badge)](https://www.codefactor.io/repository/github/hyriver/seamless-3dep)\n[![Ruff](https://img.shields.io/endpoint?url=https://raw.githubusercontent.com/astral-sh/ruff/main/assets/badge/v2.json)](https://github.com/astral-sh/ruff)\n[![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit\u0026logoColor=white)](https://github.com/pre-commit/pre-commit)\n[![Binder](https://mybinder.org/badge_logo.svg)](https://mybinder.org/v2/gh/hyriver/seamless-3dep/HEAD?labpath=docs%2Fexamples)\n\nSeamless3DEP is a lightweight Python package that simplifies access to topographic data\nfrom the USGS\n[3D Elevation Program (3DEP)](https://www.usgs.gov/core-science-systems/ngp/3dep).\nWhether you need elevation data or its derivatives, Seamless3DEP provides an efficient\ninterface to both static and dynamic 3DEP products.\n\nSeamless3DEP utilizes connection pooling across threads (safely) to optimize service\ncalls and minimize redundant connections. This reduces both the service load and the\ntime required to retrieve data, making it an ideal tool for handling large-scale\ntopographic data requests.\n\n📚 Full documentation is available [here](https://seamless-3dep.readthedocs.io).\n\n## Available Products\n\n### Static DEMs\n\n- 1/3 arc-second (10 meters)\n- 1 arc-second (30 meters)\n- 2 arc-second (60 meters)\n\n### Dynamic Products\n\n- Digital Elevation Model (DEM)\n- Hillshade Derivatives:\n    - Gray Hillshade\n    - Multidirectional Hillshade\n    - GreyHillshade with Elevation Fill\n    - Hillshade with Elevation Tint\n- Terrain Analysis:\n    - Aspect (Degrees and Map)\n    - Slope (Degrees and Map)\n    - Height (Ellipsoidal)\n- Contours:\n    - Contour 25 (Dynamically generates 25 contours for the area of interest)\n    - Contour Smoothed 25 (Smoothed version of the 25 contours)\n\n## Core Functions\n\nSeamless3DEP offers four main functions designed for efficient data retrieval and\nprocessing:\n\n- `get_dem`: Retrieves static DEMs within a specified bounding box. The function\n    automatically splits large areas into manageable tiles, downloads data as GeoTIFF\n    files in EPSG:4326, and supports resolutions of 10m, 30m, or 60m.\n- `get_map`: Fetches any 3DEP product (including DEMs) with customizable parameters.\n    Works with all available product types, allows custom resolution settings, and\n    downloads in EPSG:3857. Due to service limitations, the output projection is not\n    configurable.\n- `decompose_bbox`: Handles large area requests by breaking down extensive bounding\n    boxes into optimal sizes based on resolution and maximum pixel count, ensuring\n    efficient data retrieval.\n- `build_vrt`: Creates virtual raster datasets by combining multiple GeoTIFF files.\n    Requires `libgdal-core` installation and supports efficient data handling for large\n    areas. Note that `libgdal-core` is an optional dependency and is not installed when\n    `seamless-3dep` is installed from PyPI. However, it is installed as a dependency\n    when `seamless-3dep` is installed from `conda-forge`.\n- `tiffs_to_da`: Converts a list of GeoTIFF files to an `xarray.DataArray` object. This\n    function is useful for combining multiple GeoTIFF files that `get_map` and `get_dem`\n    produce into a single `xarray.DataArray` object for further analysis. Note that for\n    using this function, `shapely` and `rioxarray` need to be installed.\n\n## Important Notes\n\n- Bounding box coordinates should be in decimal degrees (WGS84) format: (west, south,\n    east, north)\n- Default projection for requesting maps is EPSG:3857\n- EPSG:4326 output projection is not supported in `get_map` due to service limitations\n\n## Installation\n\nChoose your preferred installation method:\n\n### Using `pip`\n\n```console\npip install seamless-3dep\n```\n\n### Using `micromamba` (recommended)\n\n```console\nmicromamba install -c conda-forge seamless-3dep\n```\n\nAlternatively, you can use `conda` or `mamba`.\n\n## Quick Start Guide\n\nWe can retrieve topographic data using Seamless3DEP in just a few lines of code. Then,\nwe can visualize or even reproject the data using `rioxarray`.\n\n### Retrieving a DEM\n\n```python\nfrom pathlib import Path\nimport seamless_3dep as s3dep\nimport rioxarray as rxr\n\n# Define area of interest (west, south, east, north)\nbbox = (-105.7006276, 39.8472777, -104.869054, 40.298293)\ndata_dir = Path(\"data\")\n\n# Download DEM\ntiff_files = s3dep.get_dem(bbox, data_dir)\n\n# Convert to xarray.DataArray\ndem = s3dep.tiffs_to_da(tiff_files, bbox, crs=4326)\n```\n\n![DEM Example](https://raw.githubusercontent.com/hyriver/seamless-3dep/main/docs/examples/images/dem.png)\n\n### Retrieving a Slope Map\n\n```python\nslope_files = s3dep.get_map(\"Slope Degrees\", bbox, data_dir)\ndem = s3dep.tiffs_to_da(slope_files, bbox)\n```\n\n![Slope Example](https://raw.githubusercontent.com/hyriver/seamless-3dep/main/docs/examples/images/slope_dynamic.png)\n\n## Contributing\n\nWe welcome contributions! Please see the\n[contributing](https://seamless-3dep.readthedocs.io/en/latest/CONTRIBUTING/) section for\nguidelines and instructions.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhyriver%2Fseamless-3dep","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhyriver%2Fseamless-3dep","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhyriver%2Fseamless-3dep/lists"}