文件 AWS SDK AWS 範例 SDK 儲存庫中有更多可用的
本文為英文版的機器翻譯版本,如內容有任何歧義或不一致之處,概以英文版為準。
DeleteProject
搭配 a AWS SDK 使用
下列程式碼範例示範如何使用 DeleteProject
。
如需詳細資訊,請參閱刪除專案。
- Python
-
- SDK for Python (Boto3)
-
注意
還有更多 on GitHub。尋找完整範例,並了解如何在 AWS 程式碼範例儲存庫
中設定和執行。 class Projects: @staticmethod def delete_project(lookoutvision_client, project_name): """ Deletes a Lookout for Vision Model :param lookoutvision_client: A Boto3 Lookout for Vision client. :param project_name: The name of the project that you want to delete. """ try: logger.info("Deleting project: %s", project_name) response = lookoutvision_client.delete_project(ProjectName=project_name) logger.info("Deleted project ARN: %s ", response["ProjectArn"]) except ClientError as err: logger.exception("Couldn't delete project %s.", project_name) raise
-
如需 API 詳細資訊,請參閱 DeleteProject AWS SDK for Python (Boto3) Word 參考中的 API。
-
DeleteModel
DescribeDataset