Register a model for operationalization.

register_model_from_run(
  run,
  model_name,
  model_path = NULL,
  tags = NULL,
  properties = NULL,
  description = NULL,
  datasets = NULL,
  sample_input_dataset = NULL,
  sample_output_dataset = NULL,
  resource_configuration = NULL
)

Arguments

run

The Run object.

model_name

The name of the model.

model_path

The relative cloud path to the model, for example, "outputs/modelname". When not specified, model_name is used as the path.

tags

A dictionary of key value tags to assign to the model.

properties

A dictionary of key value properties to assign to the model. These properties cannot be changed after model creation, however new key-value pairs can be added.

description

An optional description of the model.

datasets

A list of two-element lists where the first element is the dataset-model relationship and the second is the corresponding dataset, e.g. list(list("training", train_ds), list("inferencing", infer_ds)). Valid values for the data-model relationship are 'training', 'validation', and 'inferencing'.

sample_input_dataset

Sample input dataset for the registered model.

sample_output_dataset

Sample output dataset for the registered model.

resource_configuration

`ResourceConfiguration`` object to run the registered model.

Value

The registered Model.

Examples

registered_model <- register_model_from_run(run = run,
                                            model_name = "my model",
                                            model_path = 'outputs/model.rds',
                                            tags = list("version" = "0"),
                                            datasets = list(list("training", train_dataset),
                                                            list("validation", validation_dataset)),
                                            resource_configuration = resource_configuration(2, 2, 0))

See also

resource_configuration()