看到这个 github问题和这个 stackoverflow帖子后,我希望这会简单地起作用。
似乎传递环境变量MODEL_CONFIG_FILE
没有任何影响。我一直在运行,docker-compose
但是使用却遇到了同样的问题docker-run
。
错误:
I tensorflow_serving/model_servers/server.cc:82] Building single TensorFlow model file config: model_name: model model_base_path: /models/model
I tensorflow_serving/model_servers/server_core.cc:461] Adding/updating models.
I tensorflow_serving/model_servers/server_core.cc:558] (Re-)adding model: model
E tensorflow_serving/sources/storage_path/file_system_storage_path_source.cc:369] FileSystemStoragePathSource encountered a file-system access error: Could not find base path /models/model for servable model
Run Code Online (Sandbox Code Playgroud)
Dockerfile
FROM tensorflow/serving:nightly
COPY ./models/first/ /models/first
COPY ./models/second/ /models/second
COPY ./config.conf /config/config.conf
ENV MODEL_CONFIG_FILE=/config/config.conf
Run Code Online (Sandbox Code Playgroud)
撰写文件
version: '3'
services:
serving:
build: .
image: testing-models
container_name: tf
Run Code Online (Sandbox Code Playgroud)
配置文件
model_config_list: {
config: …
Run Code Online (Sandbox Code Playgroud)