Process, visualize, and upload data from a CL61 ceilometer on a Waggle node. It searches for NetCDF data files from a given period (today or yesterday) generates plot visualizing attenuated backscatter, polarization components, depolarization ratio and uploads the image. Optionally uploads the generated plots and combined NetCDF files via the Waggle Plugin interface to Beehive.
A Waggle Edge App, typically runs in a Docker container managed by Kubernetes on a Waggle node.
- Scan: Look for Vaisala CL61 NetCDF data files (
.nc) in a specified directory (--dir-path). - Filter: Select files based on a time period relative to the current time (
--period:last_hour,today,yesterday). - Process: Read the selected files using
xarray, perform necessary calculations (e.g., log10 of backscatter), and combine them into a single dataset. - Plot: Generate a time-height plot using
matplotlibshowing Attenuated Volume Backscatter Coefficient and Linear Depolarization Ratio. Cloud base heights detected by the instrument are overlaid. - Save (Optional): Create a new NetCDF file containing the combined data for the selected period (
--upload_nc). - Upload: Utilize the
waggle.pluginlibrary to upload the generated plot image (.png) and optionally the combined NetCDF file (.nc) to the Waggle Beehive data platform.
As this is intended as a Waggle Edge App, installation involves building the Docker container defined by Dockerfile.
python app.py --file_prefix vaisalacl61_anl_ --dir-path ./data --period last_hour
python app.py --file_prefix vaisalacl61_anl_ --dir-path ./data --period today --upload_nc --skip_plotsudo pluginctl build . -t ${IMAGE_NAME}
sudo pluginctl run \
-n cl61-run-test \
--selector zone=core \
--resource request.memory=1Gi,limit.memory=3Gi \
-v /path/on/node/to/data:/cl61/ \
${IMAGE_NAME} \
-- \
--file_prefix vaisalacl61_anl_ \
--period last_hour \
--upload_ncThis code is developed for the CROCUS measurement strategy at Argonne National Laboratory. For more instruments, codes and data analysis check our Instrument Cookbooks