Pulls extraction files from ADCP files for the USGS. Can be run on a given folder with subdirectories. For all the subdirectories - the script will scan through all files looking for two conditions:
- File extension is xml
QRev
(case sensitive) is present in the file name.
An error log will be generated to the folder. There may be some bad field data / assumptions taken, and the script will do its best to inform you of those decisions.
pip install usgs_mbe
usgs_mbe --test-folder=/path/to/folder
or - more simply -
usgs_mbe
If you're calling from Python (I.e., through Anaconda / PyCharm / etc.), you can do
import usgs_mbe
usgs_mbe.parse_folder(r"path/to/folder")
A csv file in each subfolder with the following columns:
MovingBedSpeed
MovingBedSpeedUnit
TestTimestamp
MovingBedTestResults
StationName
siteid
MovingBedTestQuality
Duplicates -- If multiple values were found - this indicates that the first was taken.
gage_height_va -- USGS value for the closest height to the TestTimestamp.