不同的库版本在顶点管道运行与在 Docker 容器中的版本不一致。

huangapple go评论49阅读模式
英文:

Different library version during the run of vertex pipeline vs in the docker container

问题

我在Vertex AI管道中使用了一个自定义组件,它是一个自定义组件。

```python
@component(
    base_image=f"gcr.io..."
)
def temp_step():

在组件运行期间,我希望它与Base Image中的库版本相同。但是当我尝试时,我发现在我的Docker容器中有以下版本:

google-api-core==2.11.1
google-auth==2.21.0
google-auth-oauthlib==1.0.0
google-cloud-aiplatform==1.9.0
google-cloud-appengine-logging==0.2.0
google-cloud-audit-log==0.2.5
google-cloud-bigquery==2.26.0
google-cloud-core==2.3.3
google-cloud-logging==2.6.0
google-cloud-storage==1.42.2

但在管道中组件运行期间,版本如下:

google-api-core==2.10.2
google-api-python-client==1.12.11
google-auth==1.35.0
google-auth-httplib2==0.1.0
google-auth-oauthlib==1.0.0
google-cloud-aiplatform==1.9.0
google-cloud-appengine-logging==0.2.0
google-cloud-audit-log==0.2.5
google-cloud-bigquery==2.26.0
google-cloud-core==2.3.3
google-cloud-logging==2.6.0
google-cloud-storage==1.42.2

有人知道为什么会有这种差异吗?

我尝试进行比较,但它们不同。我期望能够解释为什么组件与基础镜像不同?


<details>
<summary>英文:</summary>

I am using a Component in a vertex ai pipeline with a custom component. 

@component(
base_image=f"gcr.io..."
)
def temp_step():


It&#39;s supposed to have the same library versions during the run of the component in the Vertex AI Pipeline than in the Base Image. But when I try I see that in my docker container I have :

google-api-core==2.11.1
google-auth==2.21.0
google-auth-oauthlib==1.0.0
google-cloud-aiplatform==1.9.0
google-cloud-appengine-logging==0.2.0
google-cloud-audit-log==0.2.5
google-cloud-bigquery==2.26.0
google-cloud-core==2.3.3
google-cloud-logging==2.6.0
google-cloud-storage==1.42.2


VS in the pipeline during the run of the component
 

google-api-core==2.10.2
google-api-python-client==1.12.11
google-auth==1.35.0
google-auth-httplib2==0.1.0
google-auth-oauthlib==1.0.0
google-cloud-aiplatform==1.9.0
google-cloud-appengine-logging==0.2.0
google-cloud-audit-log==0.2.5
google-cloud-bigquery==2.26.0
google-cloud-core==2.3.3
google-cloud-logging==2.6.0
google-cloud-storage==1.42.2


Someone knows why I have this difference ? 


I tried to compare both and it was different. I am expecting an explanation why the component is different from the base image ?

</details>


# 答案1
**得分**: 1

将此内容发布为社区维基:

正如楼主所发现的,将kfp库添加到requirements.txt中解决了谷歌包版本被更改的问题。

<details>
<summary>英文:</summary>

Posting this as a community wiki:

As what OP figured out, adding the kfp library in the requirements.txt solved the issue of the versions of the google packages being changed.


</details>



huangapple
  • 本文由 发表于 2023年7月11日 04:15:45
  • 转载请务必保留本文链接:https://go.coder-hub.com/76657050.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定