-
Notifications
You must be signed in to change notification settings - Fork 13
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Water Vapor Radiometer Agent #429
Conversation
Create PWV Web API
for more information, see https://pre-commit.ci
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks good! Just a couple of minor suggestions and a request related to the fix for speeding up the tests.
One other thing, can you merge the latest |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A few changes still needed here.
I expect the installation process to change, just rely on the linked repo for instructions to reduce maintenance burden.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, thanks for all the updates!
* commit PWV agent * commit pwv_agent.py * commit changes to pwv agent * found and fixed errors to functions outside of class * keeping variable names consistent * Setup demo Flask server for fetching latest pwv value * Automatically fetch latest pwv file in api * Add docstring, mark private methods as such, and data dir outside of helper function * Setup to run with gunicorn and write README * rename pwv agent script to match latest socs version * move pwv_agent dir to correct up-to-date socs path * update pwv agent for socs pluginification and flask server changes * clean off unnecessary functions and add docstrings * implement flake8 comments * change directory/class name of agent to vendor/hardware name * change acq name process * clean up acq, _stop_acq, and __init__, and add test_mode * add radiometer agent docs * update radiometer agent description * fix typo to actually compare timestamps in acq() * add pacemaker * commit flake8 rules * commit tests for radioimeter agent * fix pwv agent in plugin.py to updated dir and agent class name * update ocs_plugin_so.py to match PWV agent's updated name/class * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * Fix flake8 warning * remove year arg for agent * change flask server working to radiometer web server * add session.data for pwv vals * remove argparse args * add session.data output to docstring * remove year in example * remove supporting APIs section in docs * add blank line for docs consistency * change phrasing to be specific about PWV agent mechanics * change the port back to 5000 * skip pacemaker step if in test mode * remove api from socs repo * change port on http mock test for consistency * update test to work pytest-docker plugin instead of pytest-docker-compose * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * change port for radiometer in config file * fix data key to avoid nested structure * move pacemaker outside of loop * add test_mode to startup params * bye bye 'hi' * remove acq.stop() in test now that test_params exist * fix test_mode arg * fix test mode arg string and replace type with action * add dependencies to the docs * fix test_params dict for agent startup * clean up test_mode conditional and clarify test-mode argument * add test-mode to tests config file for agents * Flatten args list for radiometer agent * Remove install instructions from readme I expect the installation process to change, just rely on the linked repo for instructions to reduce maintenance burden. --------- Co-authored-by: Brian Koopman <[email protected]> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
OCS agent to monitor pwv values for water vapor radiometer on-site
Description
The UCSC radiometer measures precipitable water vapor (pwv) of the atmosphere,
and outputs the values to a textfile per day on a computer at the site where OCS
is not setup. As a result, a Flask app is built to server textfiles from the
radiometer server, where this Agent uses HTTP queries to publish pwv data to OCS.
Motivation and Context
Allows us to monitor pwv values in real-time. Fixes #147
How Has This Been Tested?
Has been tested on local setup with Flask server running based off of simulated pwv textfiles
Types of changes
Checklist: