A command-line tool for downloading and analyzing PhenoCam data from NEON (National Ecological Observatory Network) sites. PhenoFetch is a Python-based tool designed to facilitate the retrieval and analysis of PhenoCam data from the National Ecological Observatory Network (NEON). PhenoCam data consists of time-lapse images used to monitor vegetation phenology (seasonal changes) at various ecological sites across the United States. This tool simplifies the process of downloading images and metadata from the PhenoCam web service, providing both batch download capabilities and summary statistics for data availability.
This tool is not officially affiliated with the National Ecological Observatory Network (NEON) or the PhenoCam Network.
Samapriya Roy. (2025). samapriya/phenofetch: PhenoCam Command Line Tool (0.2.1).
Zenodo. https://doi.org/10.5281/zenodo.15207693
- PhenoFetch
- Site Discovery: List all available NEON PhenoCam sites with their details
- Data Download: Efficiently download PhenoCam images and metadata for specified sites and date ranges
- Site Statistics: View comprehensive statistics about data availability for each site
- Size Estimation: Estimate the total download size before starting a large download
- Asynchronous Processing: Fast, concurrent downloading using asynchronous I/O
- Smart Concurrency: Automatically adjusts download parallelism based on system resources
- Progress Tracking: Clear progress bars and status updates during operations
- Python 3.7+
- Required Python packages (see
requirements.txt
)
-
Clone this repository:
git clone https://github.com/your-username/phenofetch.git cd phenofetch
-
Install dependencies:
pip install -r requirements.txt
PhenoFetch provides four main commands:
sites
: List all available PhenoCam sitesstats
: Display statistics for a siteestimate
: Estimate download size for a date rangedownload
: Download data for a specific site and date range
To see all available NEON PhenoCam sites:
python phenofetch.py sites
To view statistics for a specific site:
python phenofetch.py stats --site SITE_CODE --product PRODUCT_ID
To estimate the download size for a specific site and date range:
python phenofetch.py estimate --site SITE_CODE --product PRODUCT_ID --start-date YYYY-MM-DD --end-date YYYY-MM-DD
Optional arguments:
--batch-size
: Number of files to process in each batch (default: 50)--concurrency
: Maximum number of concurrent connections (default: auto-determined)--timeout
: Connection timeout in seconds (default: 30)
To download data for a specific site and date range:
python phenofetch.py download --site SITE_CODE --product PRODUCT_ID --start-date YYYY-MM-DD --end-date YYYY-MM-DD [--download] [--output-dir DIR]
Required arguments:
--site
: NEON site code (e.g., ABBY, BART)--product
: NEON product ID (e.g., DP1.00033)--start-date
: Start date in YYYY-MM-DD format--end-date
: End date in YYYY-MM-DD format
Optional arguments:
--download
: Flag to actually download files (if omitted, just shows a summary)--output-dir
: Directory to save downloaded files (default: ./phenocam_data)--batch-size
: Number of files to download in each batch (default: 50)--concurrency
: Maximum number of concurrent downloads (default: auto-determined)--timeout
: Connection timeout in seconds (default: 30)
python phenofetch.py sites
This will display a table of all available NEON PhenoCam sites, including their site codes, descriptions, domains, states, and types.
python phenofetch.py stats --site HARV --product DP1.00033
This will display:
- A summary table showing data availability by year and month for the Harvard Forest site
- Total image counts
- Year-by-year statistics
- Average images per month
python phenofetch.py estimate --site ABBY --product DP1.00033 --start-date 2022-01-01 --end-date 2022-01-31
This will:
- Fetch all available PhenoCam data links from the ABBY site for January 2022
- Check the size of each file without downloading it
- Display a summary of the estimated total download size, broken down by file type
- Help you make an informed decision before starting a large download
python phenofetch.py download --site ABBY --product DP1.00033 --start-date 2022-01-01 --end-date 2022-01-31 --download --output-dir ./my_phenocam_data
This will:
- Fetch all available PhenoCam data from the ABBY site for January 2022
- Download all images, thumbnails, and metadata files to the specified directory
- Show progress as the downloads proceed
Apache License 2.0
For questions or feedback, please contact:
- Samapriya Roy
- Added: New
estimate
command to check download size before committing to large downloads - Added: Size estimation for full-resolution images and thumbnails
- Added: Detailed breakdown of file sizes by type (full-res, thumbnail, metadata)
- Added: Better error handling and reporting in size estimation
- Updated: Documentation to include size estimation workflow
- Fixed: Progress bar display for better visibility during batch operations
- Improved: Terminal output formatting with Rich library