From c7b75656f7e9c5aae92678f7e51a4250898a12f2 Mon Sep 17 00:00:00 2001 From: Alexis Renchon Date: Fri, 14 Jun 2024 11:07:32 -0700 Subject: [PATCH] WIP --- docs/src/diagnostics/users_diagnostics.md | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/docs/src/diagnostics/users_diagnostics.md b/docs/src/diagnostics/users_diagnostics.md index 596874a217..da203739f8 100644 --- a/docs/src/diagnostics/users_diagnostics.md +++ b/docs/src/diagnostics/users_diagnostics.md @@ -1,4 +1,18 @@ -# default diagnostics +# Using ClimaLand Diagnostics when running a simulation + +When running a ClimaLand simulations, you have multiple options on how to write the outputs of that simulation. +You may want all variables, or just a selected few. +You may want instantaneous values, at the highest temporal and spatial resolution, or you may want to get averages at hourly or monthly time scale, and integrate in space +(for example soil moisture from 0 to 1 meter depth). +You may want to get more specific reductions, such as 10 days maximums, or compute a new variables that is a function of others. +You may want to get your outputs in memory in a Julia Dict, or write them in a NetCDF file. + +This is where ClimaLand Diagnostics comes in for users. + +In this documentation page, we first explain how to use default diagnostics and what are the defaults, and then explain how to define your own diagnostics for more advanced +users. + +# Default Diagnostics Once you have defined your model and are ready to run a simulation, and after adding ClimaDiagnostics (using ClimaDiagnostics), you can add default diagnostics to it by doing the following steps: @@ -55,4 +69,7 @@ diag_cb = ClimaDiagnostics.DiagnosticsCallback(diagnostic_handler) sol = SciMLBase.solve(prob, ode_algo; dt = Δt, callback = diag_cb) ``` -Your diagnostics have now been written in netcdf files in your output folder. \ No newline at end of file +Your diagnostics have now been written in netcdf files in your output folder. + +# Custom Diagnostics +