iwfm.meas_bounds

iwfm.meas_bounds(gwhyd_obs)[source]

Determine the earliest and latest measurement dates in a SMP-format groundwater head observation file.

Parameters:

gwhyd_obs (str) – SMP observation file name. Each data line has the form <well_name>  <MM/DD/YYYY>  <HH:MM:SS>  <head_obs>, e.g. 11N19W05Q001S  01/28/1987  00:00:00  108.530. Blank lines and lines whose date column does not parse as MM/DD/YYYY are silently skipped.

Returns:

  • earliest (datetime.datetime or None) – Earliest measurement date in the file. None if the file contains no parseable data lines.

  • latest (datetime.datetime or None) – Latest measurement date in the file. None if the file contains no parseable data lines.

Raises:

FileNotFoundError – If gwhyd_obs does not exist (raised via iwfm.file_test()iwfm.file_missing()).