Documentation Index
Fetch the complete documentation index at: https://www.truefoundry.com/llms.txt
Use this file to discover all available pages before exploring further.
MlFoundryRun.
Properties
Get run_id for the current runReturns
Get run_name for the current runReturns
Get fqn for the current runReturns
Get status for the current runReturns
Get ml_repo name of which the current run is part ofReturns
Tells whether automatic end for run is True or FalseReturns
Get Mlfoundry dashboard link for a runReturns
Methods
End a run.Parameters
status
RunStatus
default:"RunStatus.FINISHED"
Returns
Usage
from truefoundry.ml import get_client
client = get_client()
client.end(
status="value",
)
This function permanently delete the runReturns
Usage
from truefoundry.ml import get_client
client = get_client()
client.delete(
)
Get all the version of an artifact from a particular run to download contents or load them in memoryParameters
artifact_type
Optional[ArtifactType]
default:"ArtifactType.ARTIFACT"
Returns
return
Iterator[ArtifactVersion]
Usage
from truefoundry.ml import get_client
client = get_client()
client.list_artifact_versions(
artifact_type="value",
)
Get all the version of a models from a particular run to download contents or load them in memoryReturns
Usage
from truefoundry.ml import get_client
client = get_client()
client.list_model_versions(
)
Logs an artifact for the current ML Repo.Parameters
artifact_paths
List[Union[Tuple[str], Tuple[str, Optional[str]], ArtifactPath]]
required
description
Optional[str]
default:"None"
metadata
Optional[Dict[str, Any]]
default:"None"
progress
Optional[bool]
default:"None"
Returns
Usage
from truefoundry.ml import get_client
client = get_client()
client.log_artifact(
name="my-run",
artifact_paths=[ArtifactPath("file.txt")],
description="value",
metadata="value",
step="value",
progress="value",
)
Log metrics for the current run.Parameters
metric_dict
Dict[str, Union[int, float]]
required
Returns
Usage
from truefoundry.ml import get_client
client = get_client()
client.log_metrics(
metric_dict="value",
step="value",
)
Logs parameters for the run.Parameters
Returns
Usage
from truefoundry.ml import get_client
client = get_client()
client.log_params(
param_dict="value",
flatten_params="value",
)
Get metrics logged for the current run grouped by metric name.Parameters
metric_names
Optional[Iterable[str]]
default:"None"
Returns
Usage
from truefoundry.ml import get_client
client = get_client()
client.get_metrics(
metric_names="value",
)
Get all the params logged for the current run.Parameters
Returns
Usage
from truefoundry.ml import get_client
client = get_client()
client.get_params(
no_cache="value",
)
Serialize and log a versioned model under the current ML Repo. Each logged model generates a new versionParameters
model_file_or_folder
Union[str, BlobStorageDirectory]
required
description
Optional[str]
default:"None"
metadata
Optional[Dict[str, Any]]
default:"None"
progress
Optional[bool]
default:"None"
framework
Optional[Union[str, ModelFramework, Any]]
default:"None"
environment
Optional[ModelVersionEnvironment]
default:"None"
Returns
Usage
from truefoundry.ml import get_client
client = get_client()
client.log_model(
name="my-run",
model_file_or_folder="model.pkl",
description="value",
metadata="value",
step="value",
progress="value",
framework="value",
environment="value",
)
Log images under the current run at the given step.Parameters
Returns
Usage
from truefoundry.ml import get_client
client = get_client()
client.log_images(
images="value",
step="value",
)
Log custom plots under the current run at the given step.Parameters
plots
Dict[str, Union[Any, Any, Any, Plot]]
required
Returns
Usage
from truefoundry.ml import get_client
client = get_client()
client.log_plots(
plots="value",
step="value",
)