Imported Model API

Note

Imported Models are used in Stand Alone Scoring Engines. If you are not an administrator of such an engine, they are not relevant to you.

class datarobot.models.ImportedModel(id, imported_at=None, model_id=None, target=None, featurelist_name=None, dataset_name=None, model_name=None, project_id=None, version=None, note=None, origin_url=None, imported_by_username=None, project_name=None, created_by_username=None, created_by_id=None, imported_by_id=None, display_name=None)

Represents an imported model available for making predictions. These are only relevant for administrators of on-premise Stand Alone Scoring Engines.

ImportedModels are trained in one DataRobot application, exported as a .drmodel file, and then imported for use in a Stand Alone Scoring Engine.

Attributes

id (str) id of the import
model_name (str) model type describing the model generated by DataRobot
display_name (str) manually specified human-readable name of the imported model
note (str) manually added node about this imported model
imported_at (datetime) the time the model was imported
imported_by_username (str) username of the user who imported the model
imported_by_id (str) id of the user who imported the model
origin_url (str) URL of the application the model was exported from
model_id (str) original id of the model prior to export
featurelist_name (str) name of the featurelist used to train the model
project_id (str) id of the project the model belonged to prior to export
project_name (str) name of the project the model belonged to prior to export
target (str) the target of the project the model belonged to prior to export
version (float) project version of the project the model belonged to
dataset_name (str) filename of the dataset used to create the project the model belonged to
created_by_username (str) username of the user who created the model prior to export
created_by_id (str) id of the user who created the model prior to export
classmethod create(path)

Import a previously exported model for predictions.

Parameters:

path : str

The path to the exported model file

classmethod get(import_id)

Retrieve imported model info

Parameters:

import_id : str

The ID of the imported model.

Returns:

imported_model : ImportedModel

The ImportedModel instance

classmethod list(limit=None, offset=None)

List the imported models.

Parameters:

limit : int

The number of records to return. The server will use a (possibly finite) default if not specified.

offset : int

The number of records to skip.

Returns:

imported_models : list[ImportedModel]

update(display_name=None, note=None)

Update the display name or note for an imported model. The ImportedModel object is updated in place.

Parameters:

display_name : str

The new display name.

note : str

The new note.

delete()

Delete this imported model.