googleapis / googleapis/python-aiplatform

Building and deploying custom predictors fails on arm64 archs

未关闭
#2,056 0 条评论 4 个 reaction 已指派 0 人 在 GitHub 查看
api: vertex-ai
主要语言
Python
星标
905
派生
465
平均合并
1 天 13 小时
30 天内合并 PR
44

描述

Hello,

I came across this issue so I put it here, in case someone has the same problem with the aiplatform.

**Is your feature request related to a problem? Please describe.**
building and deploying a custom predictor docker image on a arm64 architecture (M1/M2 macs) succeeds on a local endpoint, but fails in a remote endpoint.
**Describe the solution you'd like**
adding an option to build the docker image with (--platform linux/amd64) in the fonction
```python
LocalModel.build_cpr_model()
```
**Describe alternatives you've considered**
A quick fix: modify the build_image() in ../google/cloud/aiplatform/docker_utils/build.py:
```python
plateform = ["--platform", "linux/amd64"]
tag_options = ["-t", output_image_name]
cache_args = ["--no-cache"] if no_cache else []

command = (
["docker", "build"] + cache_args + plateform + tag_options + ["--rm", "-f-", host_workdir]
)

```

贡献指南

打开贡献指南

调研方向

首先跟踪 LocalModel.build_cpr_model() 到 google/cloud/aiplatform/docker_utils/build.py,并检查 Docker 构建命令是如何组装的。在 arm64 上比较本地和远程的 custom-predictor 路径,然后验证生成的 image 是否能针对 linux/amd64 构建,并部署到远程 endpoint。

由索引模型根据 Issue 内容生成。

评估

技术栈
docker, python
领域
cloud, machine-learning
Issue 类型
功能
难度
3/5
预计耗时
1-2 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
48/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。