Skip to content

rockfish.models

rockfish.Model

This type represents an Model stored in the API.

Use Connection.get_model to create a Model object from a Model ID:

model = await conn.get_model("abc")

Functions

from_id(conn: AbstractConnection, model_id) -> Self async classmethod

Get a Model object for the model_id.

Warning

This method is deprecated; use conn.get_model(str) to create a model instead.

add_labels(*args, **labels: str) -> Self async

add_labels(conn, **labels: str) -> Self
add_labels(**labels: str) -> Self

Add additional labels to the model and return updated model object.

model = await model.add_labels(foo="bar")

Warning

The .add_labels(conn, key=value) overload is deprecated, use .add_labels(key=value) instead.

set_labels(*args, **labels: str) -> Self async

set_labels(conn, **labels: str) -> Self
set_labels(**labels: str) -> Self

Set the labels on the model to only the labels specified and return updated model object.

model = await model.set_labels(foo="bar")

Warning

The .set_labels(conn, key=value) overload is deprecated, use .set_labels(key=value) instead.

download_model_image() -> ModelImage async

Get the ModelImage.