【问题标题】:Cannot connect Google AutoML to kaggle kernel无法将 Google AutoML 连接到 kaggle 内核
【发布时间】:2020-03-31 22:11:13
【问题描述】:

我正在尝试通过 kaggle notebook 连接到谷歌云服务。但是我在 Kaggle 笔记本上遇到属性错误。

请在下面找到代码;

PROJECT_ID = 'abc'
from google.cloud import automl_v1beta1 as automl
automl_client = automl.AutoMlClient()

错误;

AttributeError: module 'google.cloud.automl_v1beta1' has no attribute 'AutoMlClient'

谁能帮我解决这个问题

感谢和最好的问候

迈克尔

【问题讨论】:

    标签: google-cloud-platform kaggle


    【解决方案1】:

    我尝试了您的代码,但没有收到错误。我使用了和你一样的代码:

    from google.cloud import automl_v1beta1 as automl
    
    
    # Create an AutoML client
    client = automl.AutoMlClient()
    

    你安装了这个库吗?

    pip install google-cloud-automl
    

    【讨论】:

    • 您好,感谢您的回复。当我做!pip install google-cloud-automl .Output 时,它已经安装在 kaggle 笔记本中; Requirement already satisfied: google-cloud-automl in /opt/conda/lib/python3.6/site-packages (0.10.0) 谢谢和最好的问候。迈克尔
    • 您是否正确设置了 Google Cloud 项目?按照这些步骤kaggle.com/devvret/automl-tables-tutorial-notebook 应该可以工作。
    猜你喜欢
    • 2021-11-20
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2019-07-24
    • 1970-01-01
    • 1970-01-01
    • 2020-12-21
    • 2021-04-08
    相关资源
    最近更新 更多