Python용 Vertex AI SDK 또는 Google Cloud 콘솔을 사용하여 실험을 만들거나 삭제할 수 있습니다. SDK는 프로그래매틱 방식으로 실험을 만들고 관리할 수 있게 해주는 Python 코드의 라이브러리입니다. 콘솔은 실험을 시각적으로 만들고 관리할 수 있게 해주는 웹 기반 사용자 인터페이스입니다.
텐서보드 인스턴스로 실험 만들기
Python용 Vertex AI SDK
Python용 Vertex AI SDK를 사용하여 실험을 만들고 선택적으로 Vertex AI 텐서보드 인스턴스를 연결합니다. 실험에 대한 설명을 추가하여 목적을 기술합니다. Vertex AI SDK 참조 문서의 init를 참조하세요.
[[["이해하기 쉬움","easyToUnderstand","thumb-up"],["문제가 해결됨","solvedMyProblem","thumb-up"],["기타","otherUp","thumb-up"]],[["이해하기 어려움","hardToUnderstand","thumb-down"],["잘못된 정보 또는 샘플 코드","incorrectInformationOrSampleCode","thumb-down"],["필요한 정보/샘플이 없음","missingTheInformationSamplesINeed","thumb-down"],["번역 문제","translationIssue","thumb-down"],["기타","otherDown","thumb-down"]],["최종 업데이트: 2024-11-22(UTC)"],[],[],null,["# Create or delete an experiment\n\nYou can use either the Vertex AI SDK for Python or the Google Cloud console to\ncreate or delete an experiment. The SDK is a library of Python code that you\ncan use to programmatically create and manage experiments. The console is a\nweb-based user interface that you can use to create and manage experiments\nvisually.\n| When creating an experiment using the Google Cloud console for the first time, be sure that there's a `default` Metadata Store. To check, go to your project's **Metadata** page in the Google Cloud console. See [Configure your project's metadata store](/vertex-ai/docs/ml-metadata/configure)\n\nCreate experiment with a TensorBoard instance\n---------------------------------------------\n\n### Vertex AI SDK for Python\n\n\nCreate an experiment and, optionally, associate a Vertex AI TensorBoard instance using\nthe Vertex AI SDK for Python. Add a description for the\nexperiment to document its purpose. See [`init`](/python/docs/reference/aiplatform/latest/google.cloud.aiplatform#google_cloud_aiplatform_init)\nin the Vertex AI SDK reference documentation. \n\n### Python\n\n from typing import Optional, Union\n\n from google.cloud import aiplatform\n\n\n def create_experiment_sample(\n experiment_name: str,\n experiment_description: str,\n experiment_tensorboard: Optional[Union[str, aiplatform.Tensorboard]],\n project: str,\n location: str,\n ):\n aiplatform.init(\n experiment=experiment_name,\n experiment_description=experiment_description,\n experiment_tensorboard=experiment_tensorboard,\n project=project,\n location=location,\n )\n\n- `experiment_name`: Provide a name for your experiment.\n- `experiment_description`: Provide a description for your experiment.\n- `experiment_tensorboard`: Optional. The Vertex TensorBoard instance to use as a backing TensorBoard for the provided experiment. If no `experiment_tensorboard` is provided, a default TB instance is created and used by this experiment. Note: If CMEK (encryption keys) need to be associated with the TensorBoard instance, then `experiment_tensorboard` is no longer optional.\n- `project`: . You can find these IDs in the Google Cloud console [welcome](https://console.cloud.google.com/welcome) page. \n- `location`: See [List of available locations](/vertex-ai/docs/general/locations) Be sure to use a region that supports TensorBoard if creating a TensorBoard instance.\n\n### Google Cloud console\n\n\nUse these instructions to create an experiment.\n\n1. In the Google Cloud console, go to the **Experiments** page. \n [Go to Experiments](https://console.cloud.google.com/vertex-ai/experiments)\n2. Be sure you're in the project you want to create the experiment in. \n3. Click **add_box\n Create** to open the **Experiment** pane. The **Create experiment** pane appears.\n4. In the **Experiment name** field, provide a name to uniquely identify your experiment.\n5. Optional. In the **TensorBoard instance** field, select an instance from the drop-down or provide a name for your new TensorBoard instance.\n6. Click **Create** to create your experiment.\n\nCreate an experiment without a default TensorBoard instance\n-----------------------------------------------------------\n\n### Vertex AI SDK for Python\n\n\nCreate an experiment. Add a description for the\nexperiment to document its purpose. See [`init`](/python/docs/reference/aiplatform/latest/google.cloud.aiplatform#google_cloud_aiplatform_init)\nin the Vertex AI SDK reference documentation. \n\n### Python\n\n from google.cloud import aiplatform\n\n\n def create_experiment_without_default_tensorboard_sample(\n experiment_name: str,\n experiment_description: str,\n project: str,\n location: str,\n ):\n aiplatform.init(\n experiment=experiment_name,\n experiment_description=experiment_description,\n experiment_tensorboard=False,\n project=project,\n location=location,\n )\n\n- `experiment_name`: Provide a name for your experiment.\n- `experiment_description`: Provide a description for your experiment.\n- `project`: . You can find these IDs in the Google Cloud console [welcome](https://console.cloud.google.com/welcome) page. \n- `location`: See [List of available locations](/vertex-ai/docs/general/locations) Be sure to use a region that supports TensorBoard if creating a TensorBoard instance.\n\nDelete experiment\n-----------------\n\nDeleting an experiment deletes that experiment and all experiment runs\nassociated with the experiment. The Vertex AI TensorBoard experiment\nassociated with the experiment is not deleted. To delete a TensorBoard\nexperiment, see\n[Delete outdated Vertex AI TensorBoard experiment](/vertex-ai/docs/experiments/user-journey/uj-delete-outdated-tb-experiments).\n\nAlso, any pipeline runs, artifacts, and executions associated with the deleted\nexperiment are not removed. These can be found in the Google Cloud console.\nFor artifacts and executions, a $10/GB monthly charge is handled by the\nVertex ML Metadata service. \n\n### Vertex AI SDK for Python\n\nThe following sample uses the\n[`delete`](/python/docs/reference/aiplatform/latest/google.cloud.aiplatform.ExperimentRun#google_cloud_aiplatform_ExperimentRun_delete)\nmethod from the\n[`ExperimentClass`](/python/docs/reference/aiplatform/latest/google.cloud.aiplatform.ExperimentRun).\n\n### Python\n\n from google.cloud import aiplatform\n\n\n def delete_experiment_sample(\n experiment_name: str,\n project: str,\n location: str,\n delete_backing_tensorboard_runs: bool = False,\n ):\n experiment = aiplatform.Experiment(\n experiment_name=experiment_name, project=project, location=location\n )\n\n experiment.delete(delete_backing_tensorboard_runs=delete_backing_tensorboard_runs)\n\n- `experiment_name`: Provide a name for your experiment.\n- `project`: . You can find these IDs in the Google Cloud console [welcome](https://console.cloud.google.com/welcome) page.\n- `location`: See [List of available locations](/vertex-ai/docs/general/locations)\n- `delete_backing_tensorboard_runs`: If True will also delete the Vertex AI TensorBoard runs associated with the experiment runs under this experiment that we used to store time series metrics.\n\n### Console\n\n\nUse the following instructions to delete an experiment.\n\n1. In the Google Cloud console, go to the **Experiments** page. \n [Go to Experiments](https://console.cloud.google.com/vertex-ai/experiments)\n2. Select the checkbox associated with the experiment you want to delete. The **Delete** option appears.\n3. Click **Delete** .\n - Alternatively, you can go to the more_vert options menu that is in the same row as the experiment and select **delete**.\n\nView list of experiments in Google Cloud console\n------------------------------------------------\n\n1. In the Google Cloud console, in the Vertex AI section, go to the\n **Experiments** page.\n\n [Go to the Experiments page](https://console.cloud.google.com/vertex-ai/experiments)\n2. Check to be sure you are in the correct project.\n\n3. A list of experiments for your project appears in\n the **Experiment tracking** view. \n\n If you associated a Vertex AI TensorBoard instance with your\n experiment it shows up in the list as \"*your-experiment* Backing\n TensorBoard Experiment\".\n\nWhat's next\n-----------\n\n- [Create and manage experiment runs](/vertex-ai/docs/experiments/create-manage-exp-run)\n- [Delete outdated Vertex AI TensorBoard experiment](/vertex-ai/docs/experiments/user-journey/uj-delete-outdated-tb-experiments)\n\n### Relevant notebook sample\n\n- [Model training with prebuilt data pre-processing code](/vertex-ai/docs/experiments/user-journey/uj-model-training)"]]