download-data

Solid

Download NAIP aerial imagery for a bounding box. Specify coordinates as minx,miny,maxx,maxy in WGS84 and optionally a year.

Data & Documents 24 stars 3 forks Updated 6 days ago MIT

Install

View on GitHub

Quality Score: 85/100

Stars 20%
47
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
50
License 10%
100
Description 5%
100

Skill Content

You are helping the user download NAIP aerial imagery using geoai. Input: `$@` Follow these steps in order. ## Step 1 -- Parse arguments Extract the bounding box from the first argument (comma-separated `minx,miny,maxx,maxy`). Parse optional flags from remaining arguments: - `--year YYYY` -> download year (default: most recent available) - `--output DIR` -> output directory (default: `./naip_data/`) - `--max-items N` -> maximum number of items to download (default: 10) If the input is natural language (e.g. "download NAIP imagery for Knoxville, TN"), extract or infer the bounding box. If you cannot determine the bbox, ask the user for coordinates. ## Step 2 -- Validate the bounding box Confirm the bounding box has 4 numeric values and represents a valid geographic extent: - `minx < maxx` and `miny < maxy` - Longitude values within -180 to 180 - Latitude values within -90 to 90 - The area is not unreasonably large (warn if the bbox spans more than 1 degree in either direction) If validation fails, report the issue and ask for corrected coordinates. ## Step 3 -- Run the download ```bash python3 -c " import geoai, os bbox = (MINX, MINY, MAXX, MAXY) output_dir = 'OUTPUT_DIR' os.makedirs(output_dir, exist_ok=True) result = geoai.download_naip( bbox=bbox, output_dir=output_dir, year=YEAR, max_items=MAX_ITEMS, ) if isinstance(result, list): for f in result: size_mb = os.path.getsize(f) / (1024 * 1024) if os.path.exists(f) else 0 print...

Details

Author
opengeos
Repository
opengeos/geoai-skills
Created
4 months ago
Last Updated
6 days ago
Language
N/A
License
MIT

Bundled in these plugins

Similar Skills

Semantically similar based on skill content — not just same category