| Title: | Run Analysis Tools |
|---|---|
| Description: | A collection of tools to analyze model runs. |
| Authors: | Anastasis Giannousakis [aut, cre], Oliver Richters [aut] |
| Maintainer: | Anastasis Giannousakis <[email protected]> |
| License: | LGPL-3 |
| Version: | 0.30.0 |
| Built: | 2026-06-08 14:56:13 UTC |
| Source: | https://github.com/pik-piam/modelstats |
A collection of tools to analyze model runs.
Maintainer: Anastasis Giannousakis [email protected]
Authors:
Anastasis Giannousakis [email protected]
Oliver Richters
Useful links:
What is the type of this run?
colRunType(mydir = ".")colRunType(mydir = ".")
mydir |
Path to the folder where the run is performed |
Anastasis Giannousakis
This function is made to be called by the rs tool. It takes the command line arguments supplied by the user when calling rs, evaluates them, and according to them prepares the arguments finally passed to loopRuns or getSanityChecks.
commandLineInterface(argv)commandLineInterface(argv)
argv |
A character vector containing the command line arguments. |
A string containing the status or sanity table.
David Klein
Is the run found in SLURM?
foundInSlurm(mydir = ".", user = NULL)foundInSlurm(mydir = ".", user = NULL)
mydir |
Path to the folder(s) where the run(s) is(are) performed |
user |
the user whose runs will be sought for |
Anastasis Giannousakis, Oliver Richters
Returns the current status of a run or a vector of runs
getRunStatus(mydir = dir(), sort = "nf", user = NULL)getRunStatus(mydir = dir(), sort = "nf", user = NULL)
mydir |
Path to the folder(s) where the run(s) is(are) performed |
sort |
how to sort (nf=newest first) |
user |
the user whose runs will be shown |
Anastasis Giannousakis
## Not run: a <- getRunStatus(dir()) ## End(Not run)## Not run: a <- getRunStatus(dir()) ## End(Not run)
Get overview of sanity check results for a list of REMIND runs
getSanityChecks(dirs = NULL)getSanityChecks(dirs = NULL)
dirs |
a vector of paths to REMIND runs. When NULL, the latest AMTs are used (only works on PIK cluster) |
Currently the following columns are printed:
SumErr Summation Errors found when running remind2::convGDX2MIF
RangeErr Range Errors found when running remind2::convGDX2MIF
FixingErr Fixing Errors found when running piamInterfaces::fixOnRef
MissingVar Missing Variables found when running piamInterfaces::checkMissingVars for ScenarioMIP
ProjSumErr Summation Errors found when running piamInterfaces::checkSummations for ScenarioMIP
ProjSumErrReg Regional Summation Errors found when running piamInterfaces::checkSummationsRegional for ScenarioMIP
Falk Benke
Returns the output for getRunStatus nicely
loopRuns(mydir, user = NULL, colors = TRUE, sortbytime = TRUE)loopRuns(mydir, user = NULL, colors = TRUE, sortbytime = TRUE)
mydir |
a dir or vector of dirs |
user |
the user whose runs will be shown |
colors |
boolean whether the output is colored dependent on runstatus |
sortbytime |
boolean whether the output is sorted by timestamp |
Anastasis Giannousakis
## Not run: loopRuns(dir()) ## End(Not run)## Not run: loopRuns(dir()) ## End(Not run)
Runs a group of tests for a specific model. A "config/scenario_config.csv" file (relative) to the main folder has to exist in the model, describing the scenarios to be tested. Also, a gitlab repository is needed to push the generated README.md for documentation and automated reporting of test results.
modeltests( mydir = ".", gitdir = NULL, model = NULL, user = NULL, email = TRUE, compScen = TRUE, mattermostToken = NULL )modeltests( mydir = ".", gitdir = NULL, model = NULL, user = NULL, email = TRUE, compScen = TRUE, mattermostToken = NULL )
mydir |
Path to the folder where the model is found |
gitdir |
path to the git clone that sends the report via email |
model |
Model name |
user |
the user that starts the job and commits the changes |
email |
whether an email notification will be send or not |
compScen |
whether compScen has to run or not |
mattermostToken |
token used for mattermost notifications |
Anastasis Giannousakis, David Klein
Returns the output for getRunStatus nicely
printOutput( string, len1stcol = 67, lenCols = NULL, colSep = " ", cols = NULL )printOutput( string, len1stcol = 67, lenCols = NULL, colSep = " ", cols = NULL )
string |
list with information to print |
len1stcol |
length of first column |
lenCols |
vector with length information for all columns |
colSep |
string separating the columns |
cols |
optional vector of elements to retrieve from the passed list. Default NULL corresponds to a predefined set of elements. |
Anastasis Giannousakis, Falk Benke
prompts runs, will be called by rs2
promptAndRun(mydir = ".", user = NULL, daysback = 3)promptAndRun(mydir = ".", user = NULL, daysback = 3)
mydir |
a dir or vector of dirs |
user |
the user whose runs will be shown. For -t, the pattern used for matching |
daysback |
integer defining the number of days -c will look back in time to find runs |
Anastasis Giannousakis, Oliver Richters
## Not run: promptAndRun() ## End(Not run)## Not run: promptAndRun() ## End(Not run)