experiments
Operations on a experiments
resource.
Overview
Name | experiments |
Type | Resource |
Id | databricks_workspace.machinelearning.experiments |
Fields
Name | Datatype |
---|---|
name | string |
artifact_location | string |
creation_time | integer |
experiment_id | string |
last_update_time | integer |
lifecycle_stage | string |
tags | array |
Methods
Name | Accessible by | Required Params | Description |
---|---|---|---|
getbyname | SELECT | experiment_name, deployment_name | Gets metadata for an experiment. |
getexperiment | SELECT | experiment_id, deployment_name | Gets metadata for an experiment. This method works on deleted experiments. |
listexperiments | SELECT | deployment_name | Gets a list of all experiments. |
searchexperiments | SELECT | deployment_name | Searches for experiments that satisfy specified search criteria. |
createexperiment | INSERT | deployment_name | Creates an experiment with a name. Returns the ID of the newly created experiment. Validates that another experiment with the same name does not already exist and fails if another experiment with the same name already exists. |
deleteexperiment | DELETE | deployment_name | Marks an experiment and associated metadata, runs, metrics, params, and tags for deletion. If the experiment uses FileStore, artifacts associated with experiment are also deleted. |
updateexperiment | UPDATE | deployment_name | Updates experiment metadata. |
restoreexperiment | EXEC | deployment_name | Restore an experiment marked for deletion. This also restores associated metadata, runs, metrics, params, and tags. If experiment uses FileStore, underlying artifacts associated with experiment are also restored. |
SELECT
examples
- experiments (searchexperiments)
- experiments (listexperiments)
- experiments (getexperiment)
- experiments (getbyname)
SELECT
name,
artifact_location,
creation_time,
experiment_id,
last_update_time,
lifecycle_stage,
tags
FROM databricks_workspace.machinelearning.experiments
WHERE deployment_name = '{{ deployment_name }}';
SELECT
name,
artifact_location,
creation_time,
experiment_id,
last_update_time,
lifecycle_stage,
tags
FROM databricks_workspace.machinelearning.experiments
WHERE deployment_name = '{{ deployment_name }}';
SELECT
name,
artifact_location,
creation_time,
experiment_id,
last_update_time,
lifecycle_stage,
tags
FROM databricks_workspace.machinelearning.experiments
WHERE experiment_id = '{{ experiment_id }}' AND
deployment_name = '{{ deployment_name }}';
SELECT
name,
artifact_location,
creation_time,
experiment_id,
last_update_time,
lifecycle_stage,
tags
FROM databricks_workspace.machinelearning.experiments
WHERE experiment_name = '{{ experiment_name }}' AND
deployment_name = '{{ deployment_name }}';
INSERT
example
Use the following StackQL query and manifest file to create a new experiments
resource.
- experiments
- Manifest
/*+ create */
INSERT INTO databricks_workspace.machinelearning.experiments (
deployment_name,
data__name,
data__artifact_location,
data__tags
)
SELECT
'{{ deployment_name }}',
'{{ name }}',
'{{ artifact_location }}',
'{{ tags }}'
;
- name: your_resource_model_name
props:
- name: name
value: string
- name: artifact_location
value: string
- name: tags
value:
- key: string
value: string
UPDATE
example
Updates a experiments
resource.
/*+ update */
-- replace field1, field2, etc. with the fields you want to update
UPDATE databricks_workspace.machinelearning.experiments
SET field1 = '{{ value1 }}',
field2 = '{{ value2 }}', ...
WHERE deployment_name = '{{ deployment_name }}';
DELETE
example
Deletes a experiments
resource.
/*+ delete */
DELETE FROM databricks_workspace.machinelearning.experiments
WHERE deployment_name = '{{ deployment_name }}';