gradient.commands package¶
Submodules¶
gradient.commands.clusters module¶
- class gradient.commands.clusters.ClustersCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.clusters.ListClustersCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.ListCommandMixin
,gradient.commands.clusters.ClustersCommand
- WAITING_FOR_RESPONSE_MESSAGE = 'Waiting for data...'¶
- execute(**kwargs)¶
gradient.commands.common module¶
- class gradient.commands.common.BaseCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
object
- __init__(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- get_namespace()¶
- abstract execute(*args, **kwargs)¶
- class gradient.commands.common.ListCommandMixin¶
Bases:
object
- WAITING_FOR_RESPONSE_MESSAGE = 'Waiting for data...'¶
- TOTAL_ITEMS_KEY = 'total'¶
- execute(**kwargs)¶
- class gradient.commands.common.ListCommandPagerMixin¶
Bases:
gradient.commands.common.ListCommandMixin
- execute(**kwargs)¶
- class gradient.commands.common.DetailsCommandMixin¶
Bases:
object
- WAITING_FOR_RESPONSE_MESSAGE = 'Waiting for data...'¶
- execute(id_)¶
- class gradient.commands.common.StreamMetricsCommand(*args, **kwargs)¶
Bases:
gradient.commands.common.ListCommandMixin
- __init__(*args, **kwargs)¶
- execute(*args, **kwargs)¶
gradient.commands.datasets module¶
- class gradient.commands.datasets.WorkerPool(count=None, min_count=4, max_count=16, cpu_multiplier=1)¶
Bases:
object
- __init__(count=None, min_count=4, max_count=16, cpu_multiplier=1)¶
- put(func, *args, **kwargs)¶
- set_exception(exception)¶
- has_exception()¶
- completed_count()¶
- class gradient.commands.datasets.BaseDatasetsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.datasets.ListDatasetsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.ListCommandPagerMixin
,gradient.commands.datasets.BaseDatasetsCommand
- class gradient.commands.datasets.ShowDatasetDetailsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.DetailsCommandMixin
,gradient.commands.datasets.BaseDatasetsCommand
- class gradient.commands.datasets.CreateDatasetCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.datasets.BaseDatasetsCommand
- execute(name, storage_provider_id, description=None)¶
- class gradient.commands.datasets.UpdateDatasetCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.datasets.BaseDatasetsCommand
- execute(dataset_id, name=None, description=None)¶
- class gradient.commands.datasets.DeleteDatasetCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.datasets.BaseDatasetsCommand
- execute(dataset_id)¶
- class gradient.commands.datasets.BaseDatasetVersionsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.datasets.ListDatasetVersionsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.ListCommandPagerMixin
,gradient.commands.datasets.BaseDatasetVersionsCommand
- execute(**kwargs)¶
- class gradient.commands.datasets.ShowDatasetVersionDetailsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.DetailsCommandMixin
,gradient.commands.datasets.BaseDatasetVersionsCommand
- execute(dataset_version_id, **kwargs)¶
- class gradient.commands.datasets.CreateDatasetVersionCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.datasets.BaseDatasetVersionsCommand
- execute(dataset_id, message=None, source_paths=None)¶
- class gradient.commands.datasets.UpdateDatasetVersionCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.datasets.BaseDatasetVersionsCommand
- execute(dataset_version_id, message=None)¶
- class gradient.commands.datasets.CommitDatasetVersionCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.datasets.BaseDatasetVersionsCommand
- execute(dataset_version_id, message=None)¶
- class gradient.commands.datasets.DeleteDatasetVersionCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.datasets.BaseDatasetVersionsCommand
- execute(dataset_version_id)¶
- class gradient.commands.datasets.BaseDatasetTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.datasets.ListDatasetTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.ListCommandPagerMixin
,gradient.commands.datasets.BaseDatasetTagsCommand
- execute(**kwargs)¶
- class gradient.commands.datasets.SetDatasetTagCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.datasets.BaseDatasetTagsCommand
- execute(dataset_version_id, name)¶
- class gradient.commands.datasets.DeleteDatasetTagCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.datasets.BaseDatasetTagsCommand
- execute(dataset_tag_id)¶
- class gradient.commands.datasets.BaseDatasetFilesCommand(*args, **kwargs)¶
Bases:
gradient.commands.datasets.BaseDatasetVersionsCommand
- __init__(*args, **kwargs)¶
- assert_supported(dataset_id)¶
- resolve_dataset_version_id(dataset_ref)¶
- static validate_s3_response(response)¶
- static report_connection_error(exception)¶
- static normalize_path(path)¶
- get_object(dataset_version_id, path)¶
- list_objects(dataset_version_id, recursive=False, path='/', absolute=False, max_keys=20)¶
- class gradient.commands.datasets.ListDatasetFilesCommand(*args, **kwargs)¶
Bases:
gradient.commands.common.ListCommandPagerMixin
,gradient.commands.datasets.BaseDatasetFilesCommand
- class gradient.commands.datasets.GetDatasetFilesCommand(*args, **kwargs)¶
Bases:
gradient.commands.datasets.BaseDatasetFilesCommand
- execute(dataset_version_id, source_paths, target_path)¶
- class gradient.commands.datasets.PutDatasetFilesCommand(*args, **kwargs)¶
Bases:
gradient.commands.datasets.BaseDatasetFilesCommand
- execute(dataset_version_id, source_paths, target_path)¶
- class gradient.commands.datasets.DeleteDatasetFilesCommand(*args, **kwargs)¶
Bases:
gradient.commands.datasets.BaseDatasetFilesCommand
- execute(dataset_version_id, paths)¶
gradient.commands.deployments module¶
- class gradient.commands.deployments.BaseDeploymentCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.deployments.HandleAutoscalingOptions¶
Bases:
object
- class gradient.commands.deployments.HandleWorkspaceMixin¶
Bases:
object
- class gradient.commands.deployments.CreateDeploymentCommand(workspace_handler, *args, **kwargs)¶
Bases:
gradient.commands.deployments.HandleAutoscalingOptions
,gradient.commands.deployments.BaseDeploymentCommand
,gradient.commands.deployments.HandleWorkspaceMixin
- __init__(workspace_handler, *args, **kwargs)¶
- execute(**kwargs)¶
- get_instance_url(instance_id)¶
- class gradient.commands.deployments.ListDeploymentsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.deployments.BaseDeploymentCommand
- WAITING_FOR_RESPONSE_MESSAGE = 'Waiting for data...'¶
- execute(**kwargs)¶
- class gradient.commands.deployments.StartDeploymentCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.deployments.BaseDeploymentCommand
- execute(**kwargs)¶
- class gradient.commands.deployments.StopDeploymentCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.deployments.BaseDeploymentCommand
- execute(**kwargs)¶
- class gradient.commands.deployments.DeleteDeploymentCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.deployments.BaseDeploymentCommand
- execute(**kwargs)¶
- class gradient.commands.deployments.UpdateDeploymentCommand(workspace_handler, *args, **kwargs)¶
Bases:
gradient.commands.deployments.HandleAutoscalingOptions
,gradient.commands.deployments.BaseDeploymentCommand
,gradient.commands.deployments.HandleWorkspaceMixin
- __init__(workspace_handler, *args, **kwargs)¶
- execute(deployment_id, **kwargs)¶
- class gradient.commands.deployments.GetDeploymentDetails(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.DetailsCommandMixin
,gradient.commands.deployments.BaseDeploymentCommand
- get_autoscaling_metrics_string(instance)¶
- class gradient.commands.deployments.DeploymentAddTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.deployments.BaseDeploymentCommand
- execute(deployment_id, *args, **kwargs)¶
- class gradient.commands.deployments.DeploymentRemoveTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.deployments.BaseDeploymentCommand
- execute(deployment_id, *args, **kwargs)¶
- class gradient.commands.deployments.GetDeploymentMetricsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.deployments.BaseDeploymentCommand
- execute(deployment_id, start, end, interval, built_in_metrics, *args, **kwargs)¶
- class gradient.commands.deployments.ListDeploymentMetricsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.deployments.BaseDeploymentCommand
- execute(deployment_id, start, end, interval, *args, **kwargs)¶
- class gradient.commands.deployments.StreamDeploymentMetricsCommand(*args, **kwargs)¶
Bases:
gradient.commands.common.StreamMetricsCommand
,gradient.commands.deployments.BaseDeploymentCommand
- class gradient.commands.deployments.DeploymentLogsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.LogsCommandMixin
,gradient.commands.deployments.BaseDeploymentCommand
gradient.commands.experiments module¶
- class gradient.commands.experiments.BaseExperimentCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.experiments.TensorboardHandler(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
object
- __init__(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- maybe_add_to_tensorboard(tensorboard_id, experiment_id)¶
Add experiment to existing or new tensorboard
- Parameters
tensorboard_id (str|bool) –
experiment_id (str) –
- class gradient.commands.experiments.BaseCreateExperimentCommandMixin(workspace_handler, *args, **kwargs)¶
Bases:
gradient.commands.common.BaseCommand
- SPINNER_MESSAGE = 'Creating new experiment'¶
- CREATE_SUCCESS_MESSAGE_TEMPLATE = 'New experiment created with ID: {}'¶
- __init__(workspace_handler, *args, **kwargs)¶
- execute(json_, add_to_tensorboard=False)¶
- get_instance_url(instance_id, project_id)¶
- class gradient.commands.experiments.CreateSingleNodeExperimentCommand(workspace_handler, *args, **kwargs)¶
Bases:
gradient.commands.experiments.BaseCreateExperimentCommandMixin
,gradient.commands.experiments.BaseExperimentCommand
- class gradient.commands.experiments.CreateMultiNodeExperimentCommand(workspace_handler, *args, **kwargs)¶
Bases:
gradient.commands.experiments.BaseCreateExperimentCommandMixin
,gradient.commands.experiments.BaseExperimentCommand
- class gradient.commands.experiments.CreateMpiMultiNodeExperimentCommand(workspace_handler, *args, **kwargs)¶
Bases:
gradient.commands.experiments.BaseCreateExperimentCommandMixin
,gradient.commands.experiments.BaseExperimentCommand
- class gradient.commands.experiments.CreateAndStartMultiNodeExperimentCommand(workspace_handler, *args, **kwargs)¶
Bases:
gradient.commands.experiments.BaseCreateExperimentCommandMixin
,gradient.commands.experiments.BaseExperimentCommand
- SPINNER_MESSAGE = 'Creating and starting new experiment'¶
- CREATE_SUCCESS_MESSAGE_TEMPLATE = 'New experiment created and started with ID: {}'¶
- class gradient.commands.experiments.CreateAndStartMpiMultiNodeExperimentCommand(workspace_handler, *args, **kwargs)¶
Bases:
gradient.commands.experiments.BaseCreateExperimentCommandMixin
,gradient.commands.experiments.BaseExperimentCommand
- SPINNER_MESSAGE = 'Creating and starting new experiment'¶
- CREATE_SUCCESS_MESSAGE_TEMPLATE = 'New experiment created and started with ID: {}'¶
- class gradient.commands.experiments.CreateAndStartSingleNodeExperimentCommand(workspace_handler, *args, **kwargs)¶
Bases:
gradient.commands.experiments.BaseCreateExperimentCommandMixin
,gradient.commands.experiments.BaseExperimentCommand
- SPINNER_MESSAGE = 'Creating and starting new experiment'¶
- CREATE_SUCCESS_MESSAGE_TEMPLATE = 'New experiment created and started with ID: {}'¶
- class gradient.commands.experiments.StartExperimentCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.experiments.BaseExperimentCommand
- execute(experiment_id)¶
- Parameters
experiment_id (str) –
- class gradient.commands.experiments.StopExperimentCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.experiments.BaseExperimentCommand
- execute(experiment_id)¶
- Parameters
experiment_id (str) –
- class gradient.commands.experiments.ListExperimentsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.ListCommandMixin
,gradient.commands.experiments.BaseExperimentCommand
- TOTAL_ITEMS_KEY = 'totalItems'¶
- execute(**kwargs)¶
- class gradient.commands.experiments.GetExperimentCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.DetailsCommandMixin
,gradient.commands.experiments.BaseExperimentCommand
- class gradient.commands.experiments.ExperimentLogsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.LogsCommandMixin
,gradient.commands.experiments.BaseExperimentCommand
- class gradient.commands.experiments.DeleteExperimentCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.experiments.BaseExperimentCommand
- execute(experiment_id, *args, **kwargs)¶
- class gradient.commands.experiments.ExperimentAddTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.experiments.BaseExperimentCommand
- execute(experiment_id, *args, **kwargs)¶
- class gradient.commands.experiments.ExperimentRemoveTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.experiments.BaseExperimentCommand
- execute(experiment_id, *args, **kwargs)¶
- class gradient.commands.experiments.GetExperimentMetricsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.experiments.BaseExperimentCommand
- execute(experiment_id, start, end, interval, built_in_metrics, *args, **kwargs)¶
- class gradient.commands.experiments.ListExperimentMetricsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.experiments.BaseExperimentCommand
- execute(experiment_id, start, end, interval, *args, **kwargs)¶
- class gradient.commands.experiments.StreamExperimentMetricsCommand(*args, **kwargs)¶
Bases:
gradient.commands.common.StreamMetricsCommand
,gradient.commands.experiments.BaseExperimentCommand
gradient.commands.helpers module¶
- gradient.commands.helpers.print_table(data)¶
- gradient.commands.helpers.formatted_graphql(data)¶
gradient.commands.hyperparameters module¶
- class gradient.commands.hyperparameters.BaseHyperparameterCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.hyperparameters.CreateHyperparameterCommand(workspace_handler, *args, **kwargs)¶
Bases:
gradient.commands.experiments.BaseCreateExperimentCommandMixin
,gradient.commands.hyperparameters.BaseHyperparameterCommand
- SPINNER_MESSAGE = 'Creating hyperparameter tuning job'¶
- CREATE_SUCCESS_MESSAGE_TEMPLATE = 'Hyperparameter tuning job created with ID: {}'¶
- class gradient.commands.hyperparameters.CreateAndStartHyperparameterCommand(workspace_handler, *args, **kwargs)¶
Bases:
gradient.commands.experiments.BaseCreateExperimentCommandMixin
,gradient.commands.hyperparameters.BaseHyperparameterCommand
- SPINNER_MESSAGE = 'Creating and starting hyperparameter tuning job'¶
- CREATE_SUCCESS_MESSAGE_TEMPLATE = 'Hyperparameter tuning job created and started with ID: {}'¶
- class gradient.commands.hyperparameters.ListHyperparametersCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.ListCommandMixin
,gradient.commands.hyperparameters.BaseHyperparameterCommand
- class gradient.commands.hyperparameters.HyperparameterDetailsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.DetailsCommandMixin
,gradient.commands.hyperparameters.BaseHyperparameterCommand
- WAITING_FOR_RESPONSE_MESSAGE = 'Waiting for data...'¶
- class gradient.commands.hyperparameters.HyperparameterStartCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.hyperparameters.BaseHyperparameterCommand
- execute(id_)¶
- class gradient.commands.hyperparameters.HyperparameterAddTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.hyperparameters.BaseHyperparameterCommand
- execute(hyperparameter_id, *args, **kwargs)¶
- class gradient.commands.hyperparameters.HyperparameterRemoveTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.hyperparameters.BaseHyperparameterCommand
- execute(hyperparameter_id, *args, **kwargs)¶
gradient.commands.jobs module¶
- class gradient.commands.jobs.BaseJobCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.jobs.BaseCreateJobCommandMixin(workspace_handler, *args, **kwargs)¶
Bases:
gradient.commands.jobs.BaseJobCommand
- SPINNER_MESSAGE = 'Creating new job'¶
- CREATE_SUCCESS_MESSAGE_TEMPLATE = 'New job created with ID: {}'¶
- __init__(workspace_handler, *args, **kwargs)¶
- execute(json_)¶
- get_instance_url(instance_id)¶
- class gradient.commands.jobs.DeleteJobCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.jobs.BaseJobCommand
- execute(job_id)¶
- class gradient.commands.jobs.StopJobCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.jobs.BaseJobCommand
- execute(job_id)¶
- class gradient.commands.jobs.ListJobsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.jobs.BaseJobCommand
- WAITING_FOR_RESPONSE_MESSAGE = 'Waiting for data...'¶
- execute(**kwargs)¶
- class gradient.commands.jobs.JobLogsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.LogsCommandMixin
,gradient.commands.jobs.BaseJobCommand
- ENTITY = 'Job'¶
- class gradient.commands.jobs.CreateJobCommand(workspace_handler, *args, **kwargs)¶
- class gradient.commands.jobs.ArtifactsDestroyCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.jobs.BaseJobCommand
- execute(job_id, files=None)¶
- class gradient.commands.jobs.ArtifactsGetCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.jobs.BaseJobCommand
- execute(job_id)¶
- class gradient.commands.jobs.ArtifactsListCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.jobs.BaseJobCommand
- WAITING_FOR_RESPONSE_MESSAGE = 'Waiting for data...'¶
- execute(**kwargs)¶
- class gradient.commands.jobs.DownloadArtifactsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.jobs.BaseJobCommand
- WAITING_FOR_RESPONSE_MESSAGE = 'Waiting for data...'¶
- execute(job_id, destination_directory)¶
- class gradient.commands.jobs.JobAddTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.jobs.BaseJobCommand
- execute(job_id, *args, **kwargs)¶
- class gradient.commands.jobs.JobRemoveTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.jobs.BaseJobCommand
- execute(job_id, *args, **kwargs)¶
- class gradient.commands.jobs.GetJobMetricsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.jobs.BaseJobCommand
- execute(deployment_id, start, end, interval, built_in_metrics, *args, **kwargs)¶
- class gradient.commands.jobs.ListJobMetricsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.jobs.BaseJobCommand
- execute(deployment_id, start, end, interval, *args, **kwargs)¶
- class gradient.commands.jobs.StreamJobMetricsCommand(*args, **kwargs)¶
Bases:
gradient.commands.common.StreamMetricsCommand
,gradient.commands.jobs.BaseJobCommand
gradient.commands.login module¶
- class gradient.commands.login.CommandBase(api=None, logger_=<gradient.clilogger.CliLogger object>)¶
Bases:
object
- __init__(api=None, logger_=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.login.LogInCommand(api=None, logger_=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.login.CommandBase
- execute(email, password, api_token_name=None)¶
- class gradient.commands.login.LogOutCommand(api=None, logger_=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.login.CommandBase
- execute()¶
- class gradient.commands.login.ShowVersionCommand(api=None, logger_=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.login.CommandBase
- execute()¶
- class gradient.commands.login.SetApiKeyCommand(api=None, logger_=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.login.CommandBase
- execute(api_key)¶
gradient.commands.machine_types module¶
- class gradient.commands.machine_types.BaseMachineTypesCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.machine_types.ListMachineTypesCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.ListCommandMixin
,gradient.commands.machine_types.BaseMachineTypesCommand
gradient.commands.machines module¶
- class gradient.commands.machines.GetMachinesClientMixin¶
Bases:
object
- class gradient.commands.machines.CheckAvailabilityCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.machines.GetMachinesClientMixin
,gradient.commands.common.BaseCommand
- execute(machine_type, region)¶
- class gradient.commands.machines.CreateMachineCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.machines.GetMachinesClientMixin
,gradient.commands.common.BaseCommand
- execute(kwargs)¶
- get_instance_url(machine_id)¶
- class gradient.commands.machines.UpdateMachineCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.machines.GetMachinesClientMixin
,gradient.commands.common.BaseCommand
- execute(machine_id, kwargs)¶
- class gradient.commands.machines.StartMachineCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.machines.GetMachinesClientMixin
,gradient.commands.common.BaseCommand
- execute(id)¶
- class gradient.commands.machines.StopMachineCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.machines.GetMachinesClientMixin
,gradient.commands.common.BaseCommand
- execute(id)¶
- class gradient.commands.machines.RestartMachineCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.machines.GetMachinesClientMixin
,gradient.commands.common.BaseCommand
- execute(id)¶
- class gradient.commands.machines.ShowMachineCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.DetailsCommandMixin
,gradient.commands.machines.GetMachinesClientMixin
,gradient.commands.common.BaseCommand
- class gradient.commands.machines.ListMachinesCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.machines.GetMachinesClientMixin
,gradient.commands.common.ListCommandMixin
,gradient.commands.common.BaseCommand
- class gradient.commands.machines.DestroyMachineCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.machines.GetMachinesClientMixin
,gradient.commands.common.BaseCommand
- execute(machine_type, region)¶
- class gradient.commands.machines.ShowMachineUtilizationCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.machines.GetMachinesClientMixin
,gradient.commands.common.BaseCommand
- execute(machine_id, billing_month)¶
- static make_details_table(usage)¶
- class gradient.commands.machines.WaitForMachineStateCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.machines.GetMachinesClientMixin
,gradient.commands.common.BaseCommand
- execute(machine_id, state, interval=5)¶
- class gradient.commands.machines.MachineAddTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.machines.GetMachinesClientMixin
,gradient.commands.common.BaseCommand
- execute(machine_id, *args, **kwargs)¶
- class gradient.commands.machines.MachineRemoveTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.machines.GetMachinesClientMixin
,gradient.commands.common.BaseCommand
- execute(machine_id, *args, **kwargs)¶
gradient.commands.models module¶
- class gradient.commands.models.GetModelsClientMixin¶
Bases:
object
- class gradient.commands.models.ListModelsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.models.GetModelsClientMixin
,gradient.commands.common.ListCommandMixin
,gradient.commands.common.BaseCommand
- class gradient.commands.models.DeleteModelCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.models.GetModelsClientMixin
,gradient.commands.common.BaseCommand
- execute(model_id, *args, **kwargs)¶
- class gradient.commands.models.CreateModel(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.models.GetModelsClientMixin
,gradient.commands.common.BaseCommand
- SPINNER_MESSAGE = 'Creating model'¶
- execute(**kwargs)¶
- class gradient.commands.models.UploadModel(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.models.GetModelsClientMixin
,gradient.commands.common.BaseCommand
- SPINNER_MESSAGE = 'Uploading model'¶
- execute(**kwargs)¶
- class gradient.commands.models.GetModelCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.DetailsCommandMixin
,gradient.commands.models.GetModelsClientMixin
,gradient.commands.common.BaseCommand
- class gradient.commands.models.DownloadModelFiles(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.models.GetModelsClientMixin
,gradient.commands.common.BaseCommand
- WAITING_FOR_RESPONSE_MESSAGE = 'Downloading files...'¶
- execute(model_id, destination_directory)¶
- class gradient.commands.models.MLModelAddTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.models.GetModelsClientMixin
,gradient.commands.common.BaseCommand
- execute(ml_model_id, *args, **kwargs)¶
- class gradient.commands.models.MLModelRemoveTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.models.GetModelsClientMixin
,gradient.commands.common.BaseCommand
- execute(ml_model_id, *args, **kwargs)¶
gradient.commands.notebooks module¶
- class gradient.commands.notebooks.BaseNotebookCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.notebooks.CreateNotebookCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.notebooks.BaseNotebookCommand
- SPINNER_MESSAGE = 'Creating new notebook'¶
- execute(**kwargs)¶
- get_instance_url(notebook_id)¶
- class gradient.commands.notebooks.StopNotebookCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.notebooks.BaseNotebookCommand
- SPINNER_MESSAGE = 'Stopping notebook'¶
- execute(id)¶
- class gradient.commands.notebooks.StartNotebookCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.notebooks.BaseNotebookCommand
- SPINNER_MESSAGE = 'Starting notebook'¶
- execute(**kwargs)¶
- get_instance_url(notebook_id)¶
- class gradient.commands.notebooks.ForkNotebookCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.notebooks.BaseNotebookCommand
- WAITING_FOR_RESPONSE_MESSAGE = 'Forking notebook'¶
- execute(id_, project_id)¶
- class gradient.commands.notebooks.DeleteNotebookCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.notebooks.BaseNotebookCommand
- WAITING_FOR_RESPONSE_MESSAGE = 'Deleting notebook'¶
- execute(id_)¶
- class gradient.commands.notebooks.ListNotebooksCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.ListCommandMixin
,gradient.commands.notebooks.BaseNotebookCommand
- SPINNER_MESSAGE = 'Waiting for data'¶
- execute(**kwargs)¶
- class gradient.commands.notebooks.ShowNotebookDetailsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.DetailsCommandMixin
,gradient.commands.notebooks.BaseNotebookCommand
- class gradient.commands.notebooks.NotebookAddTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.notebooks.BaseNotebookCommand
- execute(notebook_id, *args, **kwargs)¶
- class gradient.commands.notebooks.NotebookRemoveTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.notebooks.BaseNotebookCommand
- execute(notebook_id, *args, **kwargs)¶
- class gradient.commands.notebooks.GetNotebookMetricsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.notebooks.BaseNotebookCommand
- execute(notebook_id, start, end, interval, built_in_metrics, *args, **kwargs)¶
- class gradient.commands.notebooks.ListNotebookMetricsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.notebooks.BaseNotebookCommand
- execute(notebook_id, start, end, interval, *args, **kwargs)¶
- class gradient.commands.notebooks.StreamNotebookMetricsCommand(*args, **kwargs)¶
Bases:
gradient.commands.common.StreamMetricsCommand
,gradient.commands.notebooks.BaseNotebookCommand
- class gradient.commands.notebooks.ArtifactsListCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.notebooks.BaseNotebookCommand
- WAITING_FOR_RESPONSE_MESSAGE = 'Waiting for data...'¶
- execute(**kwargs)¶
- class gradient.commands.notebooks.NotebookLogsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.LogsCommandMixin
,gradient.commands.notebooks.BaseNotebookCommand
- ENTITY = 'Notebook'¶
gradient.commands.projects module¶
- class gradient.commands.projects.BaseProjectCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.projects.CreateProjectCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.projects.BaseProjectCommand
- SPINNER_MESSAGE = 'Creating new project'¶
- CREATE_SUCCESS_MESSAGE_TEMPLATE = 'Project created with ID: {}'¶
- execute(project_dict)¶
- get_instance_url(project_id)¶
- class gradient.commands.projects.ListProjectsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.ListCommandMixin
,gradient.commands.projects.BaseProjectCommand
- class gradient.commands.projects.DeleteProjectCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.projects.BaseProjectCommand
- execute(project_id)¶
- class gradient.commands.projects.ProjectAddTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.projects.BaseProjectCommand
- execute(project_id, *args, **kwargs)¶
- class gradient.commands.projects.ProjectRemoveTagsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.projects.BaseProjectCommand
- execute(project_id, *args, **kwargs)¶
- class gradient.commands.projects.ShowProjectDetailsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.DetailsCommandMixin
,gradient.commands.projects.BaseProjectCommand
gradient.commands.secrets module¶
- class gradient.commands.secrets.BaseSecretsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.secrets.ListSecretsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.ListCommandMixin
,gradient.commands.secrets.BaseSecretsCommand
- class gradient.commands.secrets.SetSecretCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.secrets.BaseSecretsCommand
- execute(entity, entity_id, name, value)¶
- class gradient.commands.secrets.DeleteSecretCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.secrets.BaseSecretsCommand
- execute(entity, entity_id, name)¶
gradient.commands.storage_providers module¶
- gradient.commands.storage_providers.format_config(config, limit=None)¶
- class gradient.commands.storage_providers.BaseStorageProvidersCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.storage_providers.ListStorageProvidersCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.ListCommandPagerMixin
,gradient.commands.storage_providers.BaseStorageProvidersCommand
- class gradient.commands.storage_providers.ShowStorageProviderDetailsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.DetailsCommandMixin
,gradient.commands.storage_providers.BaseStorageProvidersCommand
- class gradient.commands.storage_providers.CreateS3StorageProviderCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.storage_providers.BaseStorageProvidersCommand
- execute(name, bucket, access_key, secret_access_key, endpoint=None, region=None, signature_version=None)¶
- class gradient.commands.storage_providers.UpdateS3StorageProviderCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.storage_providers.BaseStorageProvidersCommand
- execute(storage_provider_id, name=None, bucket=None, access_key=None, secret_access_key=None, endpoint=None, region=None, signature_version=None)¶
- class gradient.commands.storage_providers.DeleteStorageProviderCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.storage_providers.BaseStorageProvidersCommand
- execute(storage_provider_id)¶
gradient.commands.tensorboards module¶
- class gradient.commands.tensorboards.GetTensorboardClientCommandMixin(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.tensorboards.CreateTensorboardCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.tensorboards.GetTensorboardClientCommandMixin
,gradient.commands.common.BaseCommand
- SPINNER_MESSAGE = 'Creating new tensorboard'¶
- execute(**kwargs)¶
- class gradient.commands.tensorboards.GetTensorboardCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.tensorboards.GetTensorboardClientCommandMixin
,gradient.commands.common.BaseCommand
- WAITING_FOR_RESPONSE_MESSAGE = 'Waiting for data...'¶
- execute(id_)¶
- class gradient.commands.tensorboards.ListTensorboardsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.tensorboards.GetTensorboardClientCommandMixin
,gradient.commands.common.ListCommandMixin
,gradient.commands.common.BaseCommand
- WAITING_FOR_RESPONSE_MESSAGE = 'Waiting for data...'¶
- class gradient.commands.tensorboards.AddExperimentToTensorboard(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.tensorboards.GetTensorboardClientCommandMixin
,gradient.commands.common.BaseCommand
- SPINNER_MESSAGE = 'Adding experiments to tensorboard'¶
- execute(id, experiments)¶
- Parameters
id (str) –
experiments (list[str]) –
- class gradient.commands.tensorboards.RemoveExperimentToTensorboard(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.tensorboards.GetTensorboardClientCommandMixin
,gradient.commands.common.BaseCommand
- SPINNER_MESSAGE = 'Removing experiments from tensorboard'¶
- execute(id, **kwargs)¶
- class gradient.commands.tensorboards.DeleteTensorboard(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.tensorboards.GetTensorboardClientCommandMixin
,gradient.commands.common.BaseCommand
- SPINNER_MESSAGE = 'Deleting tensorboard'¶
- execute(*args, **kwargs)¶
gradient.commands.workflows module¶
- class gradient.commands.workflows.DetailJSONCommandMixin¶
- class gradient.commands.workflows.BaseWorkflowCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
- class gradient.commands.workflows.CreateWorkflowCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.workflows.BaseWorkflowCommand
,gradient.commands.common.DetailsCommandMixin
- execute(name, project_id)¶
- class gradient.commands.workflows.CreateWorkflowRunCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.workflows.BaseWorkflowCommand
- execute(spec_path=None, input_path=None, workflow_id=None, cluster_id=None)¶
- class gradient.commands.workflows.ListWorkflowsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.ListCommandMixin
,gradient.commands.workflows.BaseWorkflowCommand
- class gradient.commands.workflows.ListWorkflowRunsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.ListCommandMixin
,gradient.commands.workflows.BaseWorkflowCommand
- class gradient.commands.workflows.GetWorkflowCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.workflows.DetailJSONCommandMixin
,gradient.commands.workflows.BaseWorkflowCommand
- execute(workflow_id)¶
- get_instance(workflow_id)¶
- class gradient.commands.workflows.GetWorkflowRunCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.workflows.DetailJSONCommandMixin
,gradient.commands.workflows.BaseWorkflowCommand
- execute(workflow_id, run)¶
- get_instance(workflow_id, run)¶
- class gradient.commands.workflows.WorkflowLogsCommand(api_key, logger=<gradient.clilogger.CliLogger object>)¶
Bases:
gradient.commands.common.LogsCommandMixin
,gradient.commands.workflows.BaseWorkflowCommand
- ENTITY = 'Workflows'¶