| write_config | R Documentation |
Write a config object to a schema.rtemis.org JSON file that can be read back
with read_config and consumed by rtemislive and the rtemis CLI. The
emitted JSON carries a $schema field identifying the config family, so the
reader can dispatch to the right object:
write_config(x, file, overwrite = FALSE, verbosity = 1L)
x |
A |
file |
Character: Path to output JSON file. |
overwrite |
Logical: If TRUE, overwrite an existing file. |
verbosity |
Integer: Verbosity level. |
SuperConfig (from setup_SuperConfig) -> supervised schema.
DecomposeConfig (from setup_DecomposeConfig) -> decompose schema.
ClusterConfig (from setup_ClusterConfig) -> cluster schema.
DecompositionConfig (from setup_PCA(), setup_ICA(), ...) ->
decomposition schema.
ClusteringConfig (from setup_KMeans(), setup_DBSCAN(), ...) ->
clustering schema.
PreprocessorConfig (from setup_Preprocessor) -> preprocessor schema.
A config is an input: what a run is being asked to do. Fields it omits
fall back to their setup_* defaults when read, so a config stays valid as
those defaults improve. That is the opposite of a record, which states
what one run actually did, with every value resolved – see write_record.
The two are separate functions, so a caller names the artifact they want.
x, invisibly.
EDG
x <- setup_SuperConfig(
dat_training_path = "~/Data/iris.csv",
hyperparameters = setup_LightRF(),
outer_resampling_config = setup_KFold(),
question = "Can we tell iris species apart given their measurements?",
outdir = "models/"
)
tmpfile <- file.path(tempdir(), "rtemis.json")
write_config(x, tmpfile, overwrite = TRUE)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.