anatools.anaclient.anaclient module

The client module is used for connecting to Rendered.ai’s Platform API.

exception AuthFailedError

Bases: Exception

Custom exception for authentication failures.

class client(email=None, password=None, APIKey=None, bearer_token=None, environment=None, endpoint=None, local=False, interactive=True, verbose=None)

Bases: object

add_organization_member(email, role, organizationId=None)

Add a user to an existing organization.

Parameters
  • email (str) – Email of user to add.

  • role (str) – Role for user.

  • organizationId (str) – Organization ID to add members too. Uses current if not specified.

Returns

Response status if user got added to workspace succesfully.

Return type

str

build_channel(channelfile, ignore=['data/', 'output/'], verify=False)

Build the Docker image of a channel.

Parameters
  • channelfile (str) – The channel file for the channel to build.

  • ignore (list, optional) – List of files or directories to ignore during the build.

  • verify (bool, optional) – If True, verifies the image by running the anautils command.

Returns

A boolean that indicates if the channel Docker image was successfully built.

Return type

bool

cancel_dataset(datasetId, workspaceId=None)

Stop a running job.

Parameters
  • datasetId (str) – Dataset ID of the running job to stop.

  • workspaceId (str) – Workspace ID of the running job. If none is provided, the default workspace will get used.

Returns

Returns True if the job was cancelled successfully.

Return type

bool

check_logout()
create_analytics(datasetId, type, workspaceId=None, tags=None)

Generate analytics for a dataset.

Parameters
  • datasetId (str) – The datasetId of the dataset to generate analytics for.

  • type (str) – The type of analytics to generate for the dataset.

  • workspaceId (str) – Workspace ID of the dataset to generate the analytics for. If none is provided, the current workspace will get used.

  • tags (list[str]) – Tags for the analytics job.

Returns

The analyticsId for the analytics job.

Return type

str

create_annotation(datasetId, format, mapId=None, tags=None, workspaceId=None)

Generates annotations for an existing dataset.

Parameters
  • datasetId (str) – Dataset ID to generate annotation for.

  • format (str) – Annotation format to use.

  • mapId (str) – The ID of the map file used for annotations.

  • tags (list[str]) – Tags to apply to the annotation.

  • workspaceId (str) – Workspace ID of the dataset to generate annotation for. If none is provided, the current workspace will get used.

Returns

The annotationsId for the annotation job.

Return type

str

create_annotation_map(name, description, mapfile, organizationId=None)

Uploades an annotation map to the microservice. The map will be owned by the specified organization. If not organizationId is given the model will be owned by that of the analcient.

Parameters
  • name (str) – A name for map.

  • description (str) – Details about the map.

  • mapfile (str) – The map file - relative to the local directry.

  • organizationId (str) – Id of organization that owns the map, that of the anaclient if not given.

Returns

mapId – The unique identifier for this map.

Return type

str

create_api_key(name, scope='user', organizationId=None, workspaceId=None, expires=None)
Creates a new API Key for the User; the key will only be visible once, so make sure to save it.

To use the API Key on login, ensure it is set as an environment variable called RENDEREDAI_API_KEY or with the APIKey parameter when initializing the anatools client. This call can only be used when logged in with email/password.

Parameters
  • name (str) – Name of the API Key.

  • scope (str) – Scope of the API Key, this can be set to ‘user’, ‘organization’, or ‘workspace’ to limit the scope of access for the API Key.

  • organizationId (str) – Organization ID to set the API Key access to a particular organization’s data.

  • workspaceId (str) – Workspace ID to set the API Key access to a particular workspace’s data.

  • expires (str) – Expiration date to set for the API Key. If no expiration is provided, the key will not expire.

Returns

API Key

Return type

str

create_channel(name, description=None, organizationId=None, volumes=[], instance=None, timeout=120, interfaceVersion=1)

Create a channel for your organization.

Parameters
  • name (str) – Channel name.

  • description (str) – Description of the channel

  • organizationId (str) – Organization ID. Defaults to current if not specified.

  • volumes (list[str]) – List of the data volume names to associate with this channel.

  • instance (str) – AWS Instance type.

  • timeout (int) – Maximum runtime of a channel run.

  • interface (int) – The ana interface version number.

Returns

channel data

Return type

list[dict]

create_dataset(name, graphId, description='', runs=1, priority=1, seed=1, tags=[], workspaceId=None)

Create a new synthetic dataset using a graph in the workspace. This will start a new dataset job in the workspace.

Parameters
  • name (str) – Name for dataset.

  • graphId (str) – ID of the graph to create dataset from.

  • description (str) – Description for new dataset.

  • runs (int) – Number of times a channel will run within a single job. This is also how many different images will get created within the dataset.

  • priority (int) – Job priority.

  • seed (int) – Seed number.

  • tags (list[str]) – Tags for new dataset.

  • workspaceId (str) – Workspace ID of the staged graph’s workspace. If none is provided, the current workspace will get used.

Returns

Success or failure message about dataset creation.

Return type

str

create_gan_dataset(datasetId, modelId, name, description, tags, workspaceId=None)

Create a new GAN dataset based off an existing dataset. This will start a new job.

Parameters
  • modelId (str) – Model ID to use for the GAN.

  • datasetId (str) – Dataset ID to input into the GAN.

  • name (str) – Name for the GAN dataset.

  • description (str) – Description for the GAN dataset.

  • tags (list) – Tags for the GAN dataset.

  • workspaceId (str) – Workspace ID where the dataset exists.

Returns

The datsetId for the GAN Dataset job.

Return type

str

create_inpaint(volumeId, location, files=[], destination=None, dilation=5, inputType='MASK', outputType='PNG')

Creates an inpaint job.

Parameters
  • volumeId (str) – Volume ID

  • location (str) – Directory location of the input files

  • files (list) – List of files to inpaint, leave empty to inpaint all files in directory

  • destination (str) – Destination of the inpaint

  • dilation (int) – Dilation used for the inpaint service

  • inputType (str) – Type of input file, options are ‘MASK’, ‘GEOJSON’, ‘COCO’, ‘KITTI’, ‘PASCAL’, ‘YOLO’

  • outputType (str) – Type of output file, options are ‘SATRGB_BACKGROUND’, ‘PNG’, ‘JPG’

Returns

Inpaint ID

Return type

str

create_llm_prompt(prompt, baseChannel, nodeType, nodeName)

Creates an LLM prompt.

Parameters
  • prompt (str) – The prompt to create

  • baseChannel (str) – The base channel to use for examples

  • nodeType (str) – The type of node to create

  • nodeName (str) – The name of the node to create

Returns

Prompt ID

Return type

str

create_mixed_dataset(name, parameters, description='', seed=None, tags=None, workspaceId=None)
Creates a new datasts using the samples provided in the parameters dict. The dict must be defined by:
{

“datasetId1”: {“samples”: <int>, “classes”: [<class1>, class2>, …]}, “datasetId2”: {“samples”: <int>}, …

}

Parameters
  • name (str) – The name of the new mixed dataset

  • parameters (dict) – A dictionary of datasetId keys with values of {“samples”: <int>, “classes”: [<class1>, class2], …}

  • description (str) – Description for new dataset.

  • seed (int) – The seed for the mixed dataset, used to set the random seed.

  • tags (list[str]) – A list of tags to apply to the new dataset.

  • workspaceId (str) – The workspace the dataset is in.

Returns

The dataset ID of the new mixed dataset.

Return type

str

create_ml_inference(datasetId, modelId, mapId=None, tags=None, workspaceId=None)

Create a new machine learning inference job.

Parameters
  • datasetId (str) – Dataset ID

  • modelId (str) – Model ID

  • mapId (str) – Map ID

  • workspaceId (str) – Workspace ID

Returns

Inference ID

Return type

str

create_ml_model(datasetId, architectureId, name, parameters, description=None, tags=None, workspaceId=None)

Creates a new machine learning model.

Parameters
  • architectureId (str) – Architecture ID

  • datasetId (str) – Dataset ID

  • name (str) – Model name

  • description (str) – Model description

  • paramters (str) – JSON string of model parameters

  • workspaceId (str) – Workspace ID

Returns

Machine learning model ID

Return type

str

create_preview(graphId, workspaceId=None)

Creates a preview job.

Parameters
  • graphId (str) – The unique identifier for the graph.

  • workspaceId (str) – Workspace ID create the preview in. If none is provided, the default workspace will get used.

Returns

The unique identifier for the preview job.

Return type

str

create_remote_development(channelId, organizationId=None, channelVersion=None, instanceType=None)

Creates a remote development environment.

This method initiates a remote development session on the specified channel, optionally within a given organization. If no organizationId is provided, it defaults to the organization associated with the current user.

Parameters
  • channelId (str) – The ID of the channel to use for creating the remote development session.

  • channelVersion (str, optional) – The version of the channel to use. If not provided, defaults to the latest version.

  • organizationId (str, optional) – The ID of the organization where the session will be created. If not provided, defaults to the user’s organization.

  • instanceType (str, optional) – The type of instance to use for the remote development session. If not provided, defaults to the instance type specified in the channel.

Returns

A message indicating that the session is being created, along with a link to access the session.

Return type

str

Notes

  • This function checks if the user is logged out before proceeding.

  • Calls ana_api.createRemoteDevelopment to initiate the session.

  • Displays a warning message indicating that the feature is experimental.

Example Output

⚠️ Warning: This feature is very experimental. Use with caution! ⚠️ 🚀 Your environment will be available here shortly: 🔗 <editorUrl> 🌐

create_umap(name, datasetIds, samples, description=None, seed=None, tags=None, workspaceId=None)

Creates a UMAP dataset comparison job on the platform.

Parameters
  • datasetIds ([str]) – Dataset ID to retrieve information for.

  • samples ([int]) – Samples to take from each dataset.

  • workspaceId (str) – Workspace ID where the datasets exists.

Returns

The UMAP Job ID.

Return type

str

create_volume(name, description=None, organizationId=None, permission=None, tags=None)

Creates a new volume with the specified name in the organization. By default the permission on the volume is set to write.

Parameters
  • name (str) – The name of the new volume. Note: this name needs to be unique per organization.

  • description (str) – Description of the volume

  • organizationId (str) – The ID of the organization that the volume will belong to.

  • permission (str) – Permission to set for the volume. Choose from: read, write, or view.

  • tags (list) – Tags to set for the volume.

Returns

volumeId

Return type

str

create_workspace(name, description='', channelIds=[], volumeIds=[], code=None, tags=None, organizationId=None)

Create a new workspace with specific channels.

Parameters
  • name (str) – Workspace name.

  • description (str) – Workspace description.

  • channelIds (list[str]) – List of channel ids to add to workspace.

  • volumeIds (list[str]) – List of volume ids that the workspace will have access to.

  • code (str) – Content code that used for creating a workspace

  • tags (list[str]) – List of tags to add to workspace.

  • organizationId (str) – Organization ID. Defaults to current if not specified.

Returns

Workspace ID if creation was successful. Otherwise returns message.

Return type

str

delete_analytics(analyticsId, workspaceId=None)

Deletes analytics for a dataset.

Parameters
  • analyticsId (str) – Analytics ID for the analytics to delete.

  • workspaceId (str) – Workspace ID where the analytics exist. If none is provided, the current workspace will get used.

Returns

If true, successfully deleted the analytics.

Return type

bool

delete_annotation(annotationId, workspaceId=None)

Delete a dataset annotation.

Parameters
  • annotationId (str) – AnnoationId of the annotation job.

  • workspaceId (str) – Workspace ID of the dataset to generate annotation for. If none is provided, the current workspace will get used.

Returns

If true, successfully deleted the annotation.

Return type

bool

delete_annotation_map(mapId)

Deletes the annotation map.

Parameters

mapId (str) – The ID of a specific Map to delete.

Returns

Returns True if the map was deleted.

Return type

bool

delete_api_key(name)

Deletes the API key from user account. This call can only be used when logged in with email/password.

Parameters

name (str) – Name of the API Key to delete.

Returns

Success or failure message about API key deletion

Return type

bool

delete_channel(channelId)

Delete a channel of your organization.

Parameters

channelId (str) – Id of channel to delete.

Returns

Status

Return type

str

delete_dataset(datasetId, workspaceId=None)

Delete an existing dataset.

Parameters
  • datasetId (str) – Dataset ID of dataset to delete.

  • workspaceId (str) – Workspace ID that the dataset is in. If none is provided, the current workspace will get used.

Returns

Returns True if the dataset was deleted successfully.

Return type

bool

delete_gan_dataset(datasetId, workspaceId=None)

Deletes a GAN dataset job.

Parameters
  • datasetId (str) – Dataset ID for the GAN dataset.

  • workspaceId (str) – Workspace ID where the dataset exists.

Returns

Returns True if the GAN dataset was successfully deleted.

Return type

bool

delete_gan_model(modelId)

Delete the GAN model and remove access to it from all shared organizations. This can only be done by a user in the organization that owns the model.

Parameters

modelId (str) – The ID of a specific GAN model.

Returns

If True, the model was successfully deleted.

Return type

bool

delete_graph(graphId, workspaceId=None)

Delete a graph in a workspace.

Parameters
  • graphId (str) – Graph id to delete.

  • workspaceId (str) – Workspace ID of the graph’s workspace. If none is provided, the current workspace will get used.

Returns

A success or error message based on graph’s delete.

Return type

str

delete_inpaint(volumeId, inpaintId)

Deletes or cancels an inpaint job.

Parameters
  • volumeId (str) – Volume ID

  • inpaintId (str) – Inpaint ID

Returns

Success / Failure

Return type

bool

delete_llm_prompt(promptId)

Deletes an LLM prompt.

Parameters

promptId (str) – The ID of a prompt.

Returns

Success code

Return type

bool

delete_ml_inference(inferenceId, workspaceId=None)

Deletes or cancels a machine learning inference job.

Parameters
  • inferenceId (str) – Inference ID

  • workspaceId (str) – Workspace ID

Returns

Returns True if successful

Return type

bool

delete_ml_model(modelId, workspaceId=None)

Deletes or cancels a machine learning training job.

Parameters
  • modelId (str) – Model ID

  • workspaceId (str) – Workspace ID

Returns

Returns True if successful

Return type

bool

delete_remote_development(editorSessionId=None)

Deletes a remote development session.

This method removes a specific editor session, optionally within a given organization. If no editorSessionId is provided, it will show a list of active sessions and prompt for selection.

Parameters

editorSessionId (str, optional) – The ID of the editor session to be deleted. If not provided, will prompt for selection.

Returns

A dictionary representing the result of the session deletion.

Return type

dict

Notes

  • This function checks if the user is logged out before proceeding.

  • Calls ana_api.deleteRemoteDevelopment to perform the deletion.

  • Use arrow keys (↑/↓) to select a session, Enter to confirm, q to quit

delete_umap(umapId, workspaceId=None)

Deletes/cancels a UMAP dataset comparison on the platform.

Parameters
  • umapId (str) – UMAP Job ID.

  • workspaceId (str) – Workspace ID where the datasets exists.

Returns

Status.

Return type

bool

delete_volume(volumeId)

Removes the volume from the organization. Note that this will delete any remote data in the volume and channels that rely on this volume will need to be updated.

Parameters

volumeId (str) – The ID of a specific Volume to delete.

Returns

Status

Return type

str

delete_volume_data(volumeId, files=None)

Delete data from a volume.

Parameters
  • volumeId (str) – VolumeId to delete files from.

  • files (str) – The specific files to delete from the volume. If left empty, no files are deleted.

Returns

Status

Return type

str

delete_workspace(workspaceId=None)

Delete an existing workspace.

Parameters

workspaceId (str) – Workspace ID for workspace to get deleted. Deletes current workspace if not specified.

Returns

Success or failure message if workspace was sucessfully removed.

Return type

str

deploy_channel(channelId=None, channelfile=None, image=None)

Deploy the Docker image of a channel.

Parameters
  • channelId (str) – ChannelId that you are pushing the image to. If the channelId isn’t specified, it will use the image name to lookup the channelId.

  • channelfile (str) – Name of the channel file to look for.

  • image (str) – The Docker image name. This should match the channel name when running ana. If image is not specified, it will use the channel name for the channelId.

Returns

deploymentId for current round of deployment or an error message if something went wrong

Return type

str

deregister_ssh_key(name=None)

Removes a public SSH key for use with remote development sessions.

Parameters

name (str) – The name of the SSH key to deregister.

Returns

A boolean status of whether the operation was successful.

Return type

bool

download_analytics(analyticsId, workspaceId=None)

Retrieve information about a specific analytics job. If an analytics job is of type Object Metrics or Mean Brightness, then images will get downloaded to current working directory.

Parameters
  • analyticsId (str) – Analytics Job ID.

  • workspaceId (str) – Workspace ID where the analytics exist. If none is provided, the current workspace will get used.

Returns

Analytics job information.

Return type

list[dict]

download_annotation(annotationId, workspaceId=None)

Downloads annotations archive.

Parameters
  • datasetId (str) – Dataset ID to download image annotation for.

  • annotationId (str) – Id of previously generated image annotation.

  • workspaceId (str) – Workspace ID of the dataset to generate annotation for. If none is provided, the current workspace will get used.

Returns

The name of the archive file that got downloaded.

Return type

str

download_annotation_map(mapId, localDir=None)

Download the annotation map file from your organization.

Parameters
  • mapId (str) – MapId to download.

  • localDir (str) – Path for where to download the annotation map. If none is provided, current working directory will be used.

Returns

The name of the map file that got downloaded.

Return type

str

download_dataset(datasetId, workspaceId=None, localDir=None)

Download a dataset.

Parameters
  • datasetId (str) – Dataset ID of dataset to download.

  • workspaceId (str) – Workspace ID that the dataset is in. If none is provided, the default workspace will get used.

  • localDir (str) – Path for where to download the dataset. If none is provided, current working directory will be used.

Returns

Returns the path the dataset was downloaded to.

Return type

str

download_gan_model(modelId, localDir=None)

Download the gan model file from your organization.

Parameters
  • modelId (str) – ModelId to download.

  • localDir (str) – Path for where to download the gan model. If none is provided, current working directory will be used.

Returns

The filepath of the downloaded GAN model.

Return type

str

download_graph(graphId, filepath=None, workspaceId=None)

Downloads a graph and save it to a file. If filepath is provided, the graph will get saved to that location.

Parameters
  • graphId (str) – Graph ID of the graph to download.

  • filepath (str) – Filepath to save the graph to. Optional.

  • workspaceId (str) – Workspace ID of the graph’s workspace. If none is provided, the default workspace will get used.

Returns

The filepath of the downloaded graph.

Return type

str

download_ml_inference(inferenceId, localDir=None, workspaceId=None)

Download the inference detections.

Parameters
  • inferencId (str) – Inference ID

  • localDir (str) – Local directory to save the model

  • workspaceId (str) – Workspace ID

Returns

Returns the filename of the downloaded model

Return type

str

download_ml_model(modelId, checkpoint=None, localDir=None, workspaceId=None)

Download the machine learning model.

Parameters
  • modelId (str) – Model ID

  • checkpoint (str) – Checkpoint to download. If not specified, the final model will be downloaded

  • localDir (str) – Local directory to save the model

  • workspaceId (str) – Workspace ID

Returns

Returns the filename of the downloaded model

Return type

str

download_volume_data(volumeId, files=[], localDir=None, recursive=True, sync=False)

Download data from a volume.

Parameters
  • volumeId (str) – VolumeId to download data of.

  • files (str) – The specific files or directories to retrieve from the volume, if you wish to retrieve all then leave the list empty.

  • localDir (str) – The location of the local directory to download the files to. If not specified, this will download the files to the current directory.

  • recursive (bool) – Recursively download files from the volume.

  • sync (bool) – Syncs data between the local directory and the remote location. Only creates folders in the destination if they contain one or more files.

Returns

Status

Return type

str

edit_annotation_map(mapId, name=None, description=None, tags=None)

Edits the name, description or tags of a map file.

Parameters
  • mapId (str) – The mapId that will be updated.

  • name (str) – The new name of the annotation map. Note: this name needs to be unique per organization.

  • description (str) – Description of the annotation map.

  • tags (list[str]) – Tags to apply to the map.

Returns

Returns True if the map was edited.

Return type

bool

edit_channel(channelId, name=None, description=None, volumes=None, instance=None, timeout=None, status=None, interfaceVersion=None, preview=None)

Edit a channel for your organization.

Parameters
  • channelId (str) – ChannelId ID of the channel to edit.

  • name (name) – The new name to give the channel.

  • description (str) – Description of the channel

  • volumes (list[str]) – Data volumes for the channel.

  • instance (str) – Instance type to run the channel on.

  • timeout (int) – Maximum runtime for the channel run.

  • status (str) – The status of the channel.

  • interface (int) – The ana interface version number.

  • preview (bool) – Enable or disable the preview for the channel.

Returns

If true, the channel was successfully edited.

Return type

bool

edit_dataset(datasetId, description=None, name=None, pause=None, priority=None, tags=None, workspaceId=None)

Update dataset properties.

Parameters
  • datasetId (str) – Dataset ID to edit the name, description or tags for.

  • name (str) – New name for dataset.

  • description (str) – New description.

  • tags (list) – New tags for dataset.

  • pause (bool) – Pauses the dataset job if it is running.

  • priority (int) – New priority for dataset job (1-3).

  • workspaceId (str) – Workspace ID of the dataset to get updated. If none is provided, the current workspace will get used.

Returns

Returns True if the dataset was updated successfully.

Return type

bool

edit_gan_model(modelId, name=None, description=None, flags=None, tags=None)

Edits the name, description, and flags of a gan model.

Parameters
  • modelId (str) – The modelId that will be updated.

  • name (str) – The new name of the gan model. Note: this name needs to be unique per organization.

  • description (str) – Description of the gan model

  • flags (str) – Flags for the model

  • tags (list[str]) – Tags for the model

Returns

If True, the model was successfully edited.

Return type

bool

edit_graph(graphId, name=None, description=None, graph=None, tags=None, workspaceId=None)

Update graph description and name.

Parameters
  • graphId (str) – Graph id to update.

  • name (str) – New name to update.

  • description (str) – New description to update.

  • graph (str) – New graph to update.

  • tags (list[str]) – New tags to update.

  • workspaceId (str) – Workspace ID of the graph’s workspace. If none is provided, the current workspace will get used.

Returns

If True, the graph was successfully edited.

Return type

bool

edit_ml_model(modelId, name=None, description=None, tags=None, workspaceId=None)

Edit the name or description of a machine learning model.

Parameters
  • modelId (str) – Model ID

  • name (str) – Model name

  • description (str) – Model description

  • tags (list[str]) – Model tags

  • workspaceId (str) – Workspace ID

Returns

Returns True if successful

Return type

bool

edit_organization(name, organizationId=None)

Update the organization name. Uses current organization if no organizationId provided.

Parameters
  • name (str) – Name to update organization to.

  • organizationId (str) – Organization Id to update.

Returns

True if organization was edited successfully, False otherwise.

Return type

bool

edit_organization_member(email, role, organizationId=None)

Edit a member’s role.

Parameters
  • email (str) – Member email to edit.

  • role (str) – Role to assign.

  • organizationId (str) – Organization ID to remove member from. Edits member in current organization if not specified.

Returns

Response if member got edited succesfully.

Return type

str

edit_volume(volumeId, name=None, description=None, permission=None)

Edits the volume in your current organization.

Parameters
  • volumeId (str) – The volumeId that will be updated.

  • name (str) – The new name of the new volume. Note: this name needs to be unique per organization.

  • description (str) – Description of the volume

  • permission (str) – Permission to set for the volume. Choose from: read, write, or view.

Returns

Status True or False

Return type

str

edit_workspace(name=None, description=None, channelIds=None, volumeIds=None, ganIds=None, mapIds=None, tags=None, workspaceId=None)

Edit workspace information.

Parameters
  • name (str) – New name to replace old one.

  • description (str) – New description to replace old one.

  • channelIds (list[str]) – Names of channels that the workspace will have access to.

  • volumeIds (list[str]) – List of volume ids that the workspace will have access to.

  • ganIds (list[str]) – List of GAN ids that the workspace will have access to.

  • mapIds (list[str]) – List of map ids that the workspace will have access to.

  • tags (list[str]) – List of tags to add or remove.

  • workspaceId (str) – Workspace ID for workspace to update.

Returns

Success or failure message if workspace was sucessfully updated.

Return type

bool

get_analytics(analyticsId=None, datasetId=None, workspaceId=None, cursor=None, limit=None, filters=None, fields=None)

Retrieve information about analytics jobs.

Parameters
  • analyticsId (str) – Analytics Job ID.

  • datasetId (str) – Dataset ID of the analytics job.

  • workspaceId (str) – Workspace ID where the analytics exist. If none is provided, the current workspace will get used.

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum number of analytics to return.

  • filters (dict) – Filters that limit output to entries that match the filter

  • fields (list[str]) – List of fields to return, leave empty to get all fields.

Returns

Analytics job information.

Return type

list[dict]

get_analytics_types()

Retrieve the analytics types available on the Rendered.ai Platform.

Returns

The analytics types available on the Platform.

Return type

list[str]

get_annotation_formats()

Retrieves the annotation formats supported by the Rendered.ai Platform.

Returns

The annotation formats supported.

Return type

list[str]

get_annotation_maps(organizationId=None, workspaceId=None, mapId=None, cursor=None, limit=None, filters=None, fields=None)

Retrieves annotation map information. If neither organizationId or workspaceId are specified, it will use the current workspace.

Parameters
  • organizationId (str) – Organization ID to retrieve maps for.

  • workspaceId (str) – Workspace ID to retrieve maps for.

  • mapId (str) – Annotation map ID to retrieve.

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum number of maps to return.

  • filters (dict) – Filters that limit output to entries that match the filter

  • fields (list[str]) – List of fields to return, leave empty to get all fields.

Returns

The requested annotation maps.

Return type

list[dict]

get_annotations(datasetId=None, annotationId=None, workspaceId=None, cursor=None, limit=None, filters=None, fields=None)

Retrieve information about existing annotations generated for a dataset.

Parameters
  • datasetId (str) – Dataset ID to generate annotations for.

  • annotationId (str) – Annotation ID for a specific annotations job.

  • workspaceId (str) – Workspace ID where the annotations exist. If none is provided, the current workspace will get used.

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum number of annotations to return.

  • filters (dict) – Filters that limit output to entries that match the filter.

  • fields (list[str]) – List of fields to return, leave empty to get all fields.

Returns

Annotation information.

Return type

list[dict]

get_api_keys()

Queries the api keys associated with user’s account. This call will return data only when logged in with email/password.

Returns

Names of API keys associated with user’s account.

Return type

[dict]

get_channel_documentation(channelId)

Returns channel documentation as markdown text.

Parameters

channelID (str) – The channelId of the channel

Returns

The markdown file for channel documentation.

Return type

str

get_channel_nodes(channelId, fields=None)

Get the nodes for a channel.

Parameters
  • channelId (str) – Channel Id to filter.

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

channel node schema data

Return type

list[dict]

get_channels(organizationId=None, workspaceId=None, channelId=None, cursor=None, limit=None, filters=None, fields=None)

Fetches all

Parameters
  • organizationId (str) – Filter channel list on what’s available to the organization.

  • workspaceId (str) – Filter channel list on what’s available to the workspace.

  • channelId (str) – Filter channel list on the specific channelId.

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum of channels to return.

  • filters (dict) – Filters that limit output to entries that match the filter

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

List of channels associated with user, workspace, organization or channelId.

Return type

list[dict]

get_data_fields(type)

Retrieve information about the fields that can be returned for a specific data type.

Parameters

type (str) – The data type to retrieve fields for.

Returns

Information about the fields available for the specified data type.

Return type

list[str]

get_data_types()

Retrieve a list of data types available on the Platform.

Returns

The data types available on the Platform.

Return type

list[str]

get_dataset_files(datasetId, path=None, workspaceId=None, cursor=None, limit=100)

Gets a list of files that are contained in the specified dataset

Parameters
  • datasetId (str) – Dataset ID to filter.

  • path (str) – Directory path in the dataset, e.g. “images”

  • workspaceId (str) – Workspace ID of the dataset’s workspace. If none is provided, the current workspace will get used.

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum number of files to retrieve.

Returns

List of file names.

Return type

[str]

get_dataset_jobs(organizationId=None, workspaceId=None, datasetId=None, cursor=None, limit=None, filters=None, fields=None)

Queries the organization or workspace for active dataset jobs based off provided parameters. If neither organizationId or workspaceId is provided, the current workspace will get used.

Parameters
  • organizationId (str) – Queries an organization for active dataset jobs.

  • workspaceId (str) – Queries a workspace for active dataset jobs.

  • datasetId (str) – Dataset ID to filter.

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum number of dataset jobs to return.

  • filters (dict) – Filters items that match the filter

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

Information about the active dataset jobs.

Return type

str

get_dataset_log(datasetId, runId, saveLogFile=False, workspaceId=None, fields=None)

Shows dataset log information to the user.

Parameters
  • datasetId (str) – The dataset the run belongs to.

  • runId (str) – The run to retrieve the log for.

  • saveLogFile (bool) – If True, saves log file to current working directory.

  • workspaceId (str) – The workspace the run belongs to.

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

Get log information by runId

Return type

list[dict]

get_dataset_runs(datasetId, state=None, workspaceId=None, fields=None)

Shows all dataset run information to the user. Can filter by state.

Parameters
  • datasetId (str) – The dataset to retrieve logs for.

  • state (str) – Filter run list by status.

  • workspaceId (str) – The workspace the dataset is in.

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

List of run associated with datasetId.

Return type

list[dict]

get_datasets(datasetId=None, workspaceId=None, filters=None, cursor=None, limit=None, fields=None)

Queries the workspace datasets based off provided parameters.

Parameters
  • datasetId (str) – Dataset ID to filter.

  • workspaceId (str) – Workspace ID of the dataset’s workspace. If none is provided, the current workspace will get used.

  • filters (dict) – Filters items that match the filter

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum of datasets to return.

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

Information about the dataset based off the query parameters.

Return type

list[dict]

get_default_graph(channelId, filepath=None)

Downlaosd the default graph for a channel.

Parameters
  • channelId – Id of channel to get the default graph for.

  • filepath (str) – Filepath to save the graph to. Optional.

Returns

The filepath of the downloaded graph.

Return type

str

get_deployment_status(deploymentId, stream=False)

Retrieves status for a channel’s deployment.

Parameters
  • deploymentId (str) – The deploymentId to retrieve status for

  • stream (bool) – Flag to print information to the terminal so the user can avoid constant polling to retrieve status.

Returns

Deployment status.

Return type

list[dict]

get_gan_datasets(datasetId=None, gandatasetId=None, workspaceId=None, cursor=None, limit=None, fields=None)

Retrieve information about GAN-generated dataset jobs.

Parameters
  • datasetId (str) – Dataset ID to retrieve information for.

  • gandatasetId (str) – Gan dataset ID to retrieve.

  • workspaceId (str) – Workspace ID where the dataset exists.

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum number of datasets to return.

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

Information about the GAN Datasets in the workspace.

Return type

list[dict]

get_gan_models(organizationId=None, workspaceId=None, modelId=None, cursor=None, limit=None, filters=None, fields=None)

Retrieve information about GAN models

Parameters
  • organizationId (str) – Organization ID that owns the models

  • workspaceId (str) – Workspace ID that contains the models

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum number of models to return.

  • modelId (str) – Model ID to retrieve information for.

  • filters (dict) – Filters that limit output to entries that match the filter

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

GAN Model information.

Return type

list[dict]

get_graphs(graphId=None, workspaceId=None, staged=False, cursor=None, limit=None, filters=None, fields=None)

Queries the workspace graphs based off provided parameters. If the workspaceId isn’t specified, the current workspace will get used.

Parameters
  • graphid (str) – GraphID to filter on. Optional.

  • workspaceId (str) – Workspace ID to filter on. If none is provided, the default workspace will get used.

  • staged (bool) – If true, returns only graphs that are staged.

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum number of graphs to return.

  • filters (dict) – Filters that limit output to entries that match the filter

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

A list of graphs based off provided query parameters if any parameters match.

Return type

list[dict]

get_image_annotation(datasetId, filename, workspaceId=None, fields=None)

Retrieves the annotation for an image.

Parameters
  • workspaceId (str) – Workspace ID containing the image. If not specified then the current workspace is used.

  • datasetId (str) – Dataset ID containing the image

  • filename – Name of the image file the annotation is for

Returns

Annotation information for the specified image.

Return type

dict

get_image_mask(datasetId, filename, workspaceId=None, fields=None)

Retrieves the mask for an image.

Parameters
  • workspaceId (str) – Workspace ID containing the image. If not specified then the default workspace is used.

  • datasetId (str) – Dataset ID containing the image

  • filename – Name of the image file the mask is for

Returns

Mask information for the specified image.

Return type

dict

get_image_metadata(datasetId, filename, workspaceId=None, fields=None)

Retrieves the metadata for an image.

Parameters
  • workspaceId (str) – Workspace ID containing the image. If not specified then the default workspace is used.

  • datasetId (str) – Dataset ID containing the image

  • filename – Name of the image file the metadata is for

Returns

Metadata information for the specified image.

Return type

dict

get_inpaint_log(volumeId, inpaintId, fields=None)

Fetches the logs for the inpaint job.

Parameters
  • volumeId (str) – Volume ID

  • inpaintId (str) – Inpaint ID

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

logs

Return type

str

get_inpaints(volumeId, inpaintId=None, limit=None, cursor=None, fields=None)

Fetches the inpaint jobs in the volume.

Parameters
  • volumeId (str) – The volumeId to query for inpaint jobs.

  • inpaintId (str) – The inpaintId of an inpaint job.

  • limit (int) – Maximum number of inpaint jobs to return.

  • cursor (str) – Cursor for pagination.

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

Inpaint jobs info

Return type

dict

get_llm_base_channels()

Gets a list of the base channels

Returns

A list of the base channels

Return type

list[str]

get_llm_channel_node_types()

Gets a dictionary of base channels. For each channel there is a list of valid node types.

Returns

A dictionary of base channels and their valid node types

Return type

dict

get_llm_response(promptId, fields=None)

Retrieves the response to an LLM prompt.

Parameters
  • promptId (str) – The ID of a prompt.

  • fields (list[str], optional) – The fields to retrieve from the response.

Returns

Prompt response info

Return type

dict

get_ml_architectures(fields=None)

Retrieves the machine learning model architectures available on the platform.

Parameters

fields (list[str], optional) – The fields to retrieve from the response.

Returns

Machine learning model architectures

Return type

dict

get_ml_inference_metrics(inferenceId, workspaceId=None)

Get the metrics from an inference job.

Parameters
  • inferenceId (str) – Inference ID

  • workspaceId (str) – Workspace ID

Returns

Metric data

Return type

dict

get_ml_inferences(workspaceId=None, inferenceId=None, datasetId=None, modelId=None, cursor=None, limit=None, filters=None, fields=None)

Get the inferences of a machine learning model.

Parameters
  • inferenceId (str) – Inference ID

  • datasetId (str) – Dataset ID

  • modelId (str) – Model ID

  • workspaceId (str) – Workspace ID

  • cursor (str) – Cursor for pagination

  • limit (int) – Maximum number of inferences to return

  • filters (dict) – Filters that limit output to entries that match the filter

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

Inference data

Return type

dict

get_ml_models(workspaceId=None, datasetId=None, modelId=None, cursor=None, limit=100, filters=None, fields=None)

Retrieves the machine learning model architectures available on the platform.

Parameters
  • workspaceId (str) – Workspace ID

  • datasetId (str) – Dataset ID

  • modelId (str) – Model ID

  • cursor (str, optional) – Cursor for pagination

  • limit (int, optional) – Maximum number of ml models to return

  • filters (dict) – Filters that limit output to entries that match the filter

  • fields (list[str], optional) – The fields to retrieve from the response.

Returns

Machine learning model architectures

Return type

dict

get_node_documentation(channelId, node, fields=None)

Retrieves the markdown documentation for a node.

Parameters
  • channelId (str) – The channelId of the channel

  • node (str) – The node to retrieve documentation for.

  • fields (list[str]) – List of fields to retrieve for the node documentation.

Returns

The markdown documentation for the node.

Return type

str

get_organization_invites(organizationId=None, cursor=None, limit=None, fields=None)

Get invitations of an organization.

Parameters
  • organizationId (str) – Organization ID. Defaults to current if not specified.

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum number of invitations to return.

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

Information about invitations of an organization.

Return type

list[dict]

get_organization_members(organizationId=None, cursor=None, limit=None, fields=None)

Get users of an organization.

Parameters
  • organizationId (str) – Organization ID. Defaults to current if not specified.

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum number of members to return.

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

Information about users of an organization.

Return type

list[dict]

get_organizations(organizationId=None, cursor=None, limit=None, fields=None)

Shows the organizations the user belongs to and the user’s role in that organization.

Parameters
  • organizationId (str) – Organization ID to filter.

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum number of organizations to return.

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

Information about the organizations you belong to.

Return type

list[dict]

get_preview(previewId, workspaceId=None, fields=None)

Queries the preview job run in the workspace.

Parameters
  • previewId (str) – The unique identifier for the preview job.

  • workspaceId (str) – Workspace the preview job was run in. If none is provided, the default workspace will get used.

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

Job run information.

Return type

dict

get_ssh_keys()

Returns a list of SSH keys a user has registered with the platform.

Returns

A list of registered SSH keys.

Return type

list

get_system_status(serviceId=None, display=True)

Fetches the system status, if no serviceId is provided it will fetch all services.

Parameters
  • serviceId (str) – The identifier of the service to fetch the status of.

  • display (bool) – Boolean for either displaying the status or returning as a dict.

get_umaps(umapId=None, datasetId=None, workspaceId=None, cursor=None, limit=None, filters=None, fields=None)

Retrieves information about UMAP dataset comparison from the platform.

Parameters
  • umapId (str) – UMAP Job ID.

  • datasetId (str) – Dataset Id to filter on.

  • workspaceId (str) – Workspace ID where the datasets exists.

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum number of umaps to return.

  • filters (dict) – Filters that limit output to entries that match the filter

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

UMAP information.

Return type

dict

get_volume_data(volumeId, files=None, dir=None, recursive=False, cursor=None, limit=None)

Retrieves information about data from a volume.

Parameters
  • volumeId (str) – VolumeId to get data for.

  • files (str) – The specific files or directories to retrieve information about from the volume, if you wish to retrieve all then leave the list empty.

  • dir (str) – Specific volume directory to retrieve information about. Optional.

  • recursive (bool) – Whether to recursively retrieve information about the volume. Optional.

  • cursor (str) – Cursor for pagination. Optional.

  • limit (int) – Maximum number of volumes to return. Optional.

Returns

Status

Return type

str

get_volumes(volumeId=None, organizationId=None, workspaceId=None, cursor=None, limit=None, filters=None, fields=None)

Retrieves all volumes the user has access to.

Parameters
  • volumeId (str) – The ID of a specific Volume.

  • organizationId (str) – The ID of the organization that the volume belongs to.

  • workspaceId (str) – The ID of the workspace that the volume belongs to.

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum number of volumes to return.

  • filters (dict) – Filters that limit output to entries that match the filter

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

Volume Info

Return type

list[dict]

get_workspaces(organizationId=None, workspaceId=None, cursor=None, limit=None, filters=None, fields=None)

Shows list of workspaces with id, name, and owner data.

Parameters
  • organizationId (str) – Organization ID to filter on. Optional

  • workspaceId (str) – Workspace ID to filter on. Optional

  • cursor (str) – Cursor for pagination.

  • limit (int) – Maximum number of workspaces to return.

  • filters (dict) – Filters that limit output to entries that match the filter

  • fields (list) – List of fields to return, leave empty to get all fields.

Returns

Workspace data for all workspaces for a user.

Return type

list[dict]

invite_remote_development(editorSessionId, email)

Invites a user to join a remote development session.

Parameters
  • editorSessionId (str) – The ID of the editor session to invite the user to.

  • email (str) – The email address of the user to invite.

Returns

A boolean status of whether the operation was successful.

Return type

bool

list_remote_development(organizationId=None)

Shows all the active development sessions in the organization.

Parameters

organizationId (str) – The ID of the organization to list the active development sessions.

Returns

If organizationId is not provided, returns all active sessions in organizations that user has access to. If organizationId is provided, returns active sessions in that specific organization.

Return type

list[dict]

login(email=None, password=None, environment=None, endpoint=None, local=False, interactive=True, verbose=None)

Log in to the SDK.

Parameters
  • email (str) – Email for the login. Will prompt if not provided.

  • password (str) – Password to login. Will prompt if not provided.

  • environment (str) – Environment to log into. Defaults to production.

  • endpoint (str) – Custom endpoint to log into.

  • local (bool) – Used for development to indicate pointing to local API.

  • interactive (bool) – Set to False for muting the login messages.

  • verbose (str) – Flag to turn on verbose logging. Use ‘debug’ to view log output.

logout()

Logs out of the ana sdk and removes credentials from ana.

mount_volumes(volumes)

Retrieves credentials for mounting volumes.

Parameters

volumes ([str]) – Volumes to retrieve mount credentials for.

Returns

Credential information.

Return type

dict

mount_workspaces(workspaces)

Retrieves credentials for mounting workspaces.

Parameters

workspaces ([str]) – Workspaces to retrieve mount credentials for.

Returns

Credential information.

Return type

dict

prepare_ssh_remote_development(editorSessionId=None, forceUpdate=False)

Prepares a remote development session for SSH access.

This method prepares a specific editor session for SSH access, optionally within a given organization. If no editorSessionId is provided, it will show a list of active sessions and prompt for selection.

Parameters
  • editorSessionId (str, optional) – The ID of the editor session to prepare SSH for. If not provided, will prompt user to select.

  • forceUpdate (bool, optional) – If True, will remove existing SSH configuration before adding new one.

Returns

A dictionary representing the result of the session preparation.

Return type

dict

Notes

  • This function checks if the user is logged out before proceeding.

  • Use arrow keys (↑/↓) to select a session, Enter to confirm, q to quit

  • Only shows sessions that are currently running or resuming

refresh_token()
register_ssh_key(filename=None)

Registers a public SSH key for use with remote development sessions.

Parameters

filename (str) – The filename of the .pub SSH key to register.

Returns

A boolean status of whether the operation was successful.

Return type

bool

remove_organization_invitation(email, organizationId=None)

Remove a invitation from an existing organization.

Parameters
  • email (str) – Invitation email to remove.

  • organizationId (str) – Organization ID to remove member from. Removes from current organization if not specified.

Returns

Response status if member got removed from organization succesfully.

Return type

str

remove_organization_member(email, organizationId=None)

Remove a member from an existing organization.

Parameters
  • email (str) – Member email to remove.

  • organizationId (str) – Organization ID to remove member from. Removes from current organization if not specified.

Returns

Response status if member got removed from organization succesfully.

Return type

str

remove_ssh_remote_development(editorSessionId=None)

Removes a remote development session from SSH access.

This method removes a specific editor session from SSH access, optionally within a given organization. If no editorSessionId is provided, it will show a list of active sessions and prompt for selection.

Parameters

editorSessionId (str, optional) – The ID of the editor session to be removed. If not provided, will prompt user to select.

Returns

A dictionary representing the result of the session removal.

Return type

dict

Notes

  • This function checks if the user is logged out before proceeding.

  • Use arrow keys (↑/↓) to select a session, Enter to confirm, q to quit

  • Only shows sessions that are currently running or resuming

set_default_graph(graphId, workspaceId=None)

Sets the default graph for a channel. User must be in the organization that owns the channel.

Parameters
  • graphId (str) – The ID of the graph that you want to be the default for the channel

  • workspaceId (str) – The ID of the Workspace that the graph is in.

Returns

If True, the graph was successfully set as the default graph for the channel.

Return type

bool

set_organization(organizationId, workspaceId=None)

Set the organization (and optionally a workspace) to the one you wish to work in.

Parameters
  • organizationId (str) – Organization ID for the organization you wish to work in.

  • workspaceId (str, optional) – Workspace ID for the workspace you wish to work in. Uses default workspace if this is not set.

set_workspace(workspaceId)

Set the workspace to the one you wish to work in.

Parameters

workspaceId (str) – Workspace ID for the workspace you wish to work in.

sign_in_apikey()
start_remote_development(editorSessionId=None)

Starts a remote development session.

This method starts a specific editor session, optionally within a given organization. If no editorSessionId is provided, it will show a list of stopped sessions and prompt for selection.

Parameters

editorSessionId (str, optional) – The ID of the editor session to be started. If not provided, will prompt for selection.

Returns

A dictionary representing the result of the session start operation.

Return type

dict

Notes

  • This function checks if the user is logged out before proceeding.

  • Calls ana_api.startRemoteDevelopment to start the session.

  • Use arrow keys (↑/↓) to select a session, Enter to confirm, q to quit

  • Only shows sessions that are currently stopped

stop_remote_development(editorSessionId=None)

Stops a remote development session.

This method stops a specific editor session, optionally within a given organization. If no editorSessionId is provided, it will show a list of active sessions and prompt for selection.

Parameters

editorSessionId (str, optional) – The ID of the editor session to be stopped. If not provided, will prompt for selection.

Returns

A dictionary representing the result of the session stop operation.

Return type

dict

Notes

  • This function checks if the user is logged out before proceeding.

  • Calls ana_api.stopRemoteDevelopment to stop the session.

  • Use arrow keys (↑/↓) to select a session, Enter to confirm, q to quit

  • Only shows sessions that are currently running or resuming

upload_channel_documentation(channelId, mdfile)

Uploads a markdown file for channel documentation.

Parameters
  • channelID (str) – The channelId of the channel

  • mdfile (str) – The filepath of the markdown file used for channel documentation.

Returns

Success/Failure of channel documenation upload.

Return type

bool

upload_dataset(filename, description=None, tags=None, workspaceId=None)

Uploads a compressed file to the datasets library in the workspace.

Parameters
  • filename (str) – Path to the dataset folder or file for uploading. Must be zip or tar file types.

  • workspaceId (str) – WorkspaceId to upload dataset to. Defaults to current.

  • description (str) – Description for new dataset.

Returns

The unique identifier for this dataset.

Return type

str

upload_gan_model(name, description, modelfile, flags=None, tags=None, organizationId=None)

Uploades a GAN model to the microservice. The model will be owned by the specified organization. If organizationId is not given the model will be owned by that of the analcient.

Parameters
  • name (str) – A name for model.

  • description (str) – Details about the model.

  • modelfile (str) – The file of the model - relative to the local directry.

  • flags (str) – Parameters for use when running the model.

  • tags (list[str]) – Tags for the model.

  • organizationId (str) – Id of organization that owns the model, that of the anaclient if not given.

Returns

The modelId for the uploaded model.

Return type

str

upload_graph(graph, channelId, name, description=None, staged=True, workspaceId=None)

Uploads a new graph based off provided parameters.

Parameters
  • graph (str) – The graph as filepath, or python dictionary.

  • channelId (str) – Id of channel to generate the graph with.

  • name (str) – Name for the graph that will get generated.

  • description (str) – Description of graph. Optional.

  • staged (bool) – If true, the graph will get staged (read-only).

  • workspaceId (str) – Workspace ID create the graph in. If none is provided, the default workspace will get used.

Returns

The graphId if it was uploaded sucessfully.

Return type

str

upload_ml_model(name, modelfile, architectureId, description=None, tags=None, workspaceId=None)

Upload a machine learning model.

Parameters
  • name (str) – Model name

  • modelfile (str) – The filepath of the compressed file containing the model, classes and spec.

  • architectureId (str) – Architecture ID

  • description (str) – Model description

  • tags (list[str]) – Model tags

  • workspaceId (str) – Workspace ID

Returns

Success / failure

Return type

bool

upload_volume_data(volumeId, files=None, localDir=None, destinationDir=None, sync=False)

Upload data to a volume.

Parameters
  • volumeId (str) – VolumeId to upload data to.

  • files (list[str]) – The specific files or directories to push to the volume from the localDir. If you wish to push all data in the root directory, then leave the list empty.

  • localDir (str) – The location of the local directory to upload the files from. If not specified, this will try to upload the files from the current directory.

  • destinationDir (str) – The target directory in the volume where files will be uploaded. If not specified, files will be uploaded to the root of the volume.

  • sync (bool) – Recursively uploads new and updated files from the source to the destination. Only creates folders in the destination if they contain one or more files.

Returns

Status

Return type

str