@@ -93,7 +93,7 @@ This will create a manylinux package in the ~/struct2tensor/dist directory.
9393
9494
9595
96- ## Creating a static library.
96+ ## Creating a static library
9797
9898In order to construct a static library for tensorflow-serving, we run:
9999
@@ -103,10 +103,31 @@ bazel build -c opt struct2tensor:prensor_kernels_and_ops
103103
104104This can also be linked into another library.
105105
106+ ## [ TensorFlow Serving] ( https://github.com/tensorflow/serving ) docker image
107+
108+ struct2tensor needs a couple of custom TensorFlow ops to function. If you train
109+ a model with struct2tensor and wants to serve it with TensorFlow Serving, the
110+ TensorFlow Serving binary needs to link with those custom ops. We have a
111+ pre-built docker image that contains such a binary. The ` Dockerfile ` is
112+ available at ` tools/tf_serving_docker/Dockerfile ` . The image is available at
113+ ` gcr.io/tfx-oss-public/s2t_tf_serving ` .
114+
115+ Please see the ` Dockerfile ` for details. But in brief, the image exposes port
116+ 8500 as the gRPC endpoint and port 8501 as the REST endpoint. You can set
117+ two environment variables ` MODEL_BASE_PATH ` and ` MODEL_NAME ` to point it to
118+ your model (either mount it to the container, or put your model on GCS).
119+ It will look for a saved model at
120+ ` ${MODEL_BASE_PATH}/${MODEL_NAME}/${VERSION_NUMBER} ` , where ` VERSION_NUMBER `
121+ is an integer.
122+
123+
106124## Compatibility
107125
108126struct2tensor | tensorflow
109127---------------------------------------------------------------------- | ----------
128+ [ 0.25.0] ( https://github.com/google/struct2tensor/releases/tag/v0.25.0 ) | 2.3.0
129+ [ 0.24.0] ( https://github.com/google/struct2tensor/releases/tag/v0.24.0 ) | 2.3.0
130+ [ 0.23.0] ( https://github.com/google/struct2tensor/releases/tag/v0.23.0 ) | 2.3.0
110131[ 0.22.0] ( https://github.com/google/struct2tensor/releases/tag/v0.22.0 ) | 2.2.0
111132[ 0.21.1] ( https://github.com/google/struct2tensor/releases/tag/v0.21.1 ) | 2.1.0
112133[ 0.21.0] ( https://github.com/google/struct2tensor/releases/tag/v0.21.0 ) | 2.1.0
0 commit comments