-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
101 additions
and
49 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
#!/bin/bash | ||
|
||
tensorflow_model_server \ | ||
--port=$PORT \ | ||
--rest_api_port=$REST_API_PORT \ | ||
--rest_api_timeout_in_ms=$REST_API_TIMEOUT \ | ||
--model_config_file=$MODEL_CONFIG_FILE \ | ||
--enable_batching=$ENABLE_BATCHING \ | ||
--grpc_channel_arguments=$GRPC_CHANNEL_ARGS \ | ||
--tensorflow_session_parallelism=$TF_SESSION_PARALLELISM \ | ||
--monitoring_config_file=$MONITORING_CONFIG_FILE \ | ||
--batching_parameters_file=$BATCHING_CONFIG_FILE \ | ||
&& \ | ||
/bin/bash # hack to keep from exiting |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#!/bin/bash | ||
|
||
# write the configuration files before running the server | ||
python write_config_file.py \ | ||
--cloud-provider=$CLOUD_PROVIDER \ | ||
--model-prefix=$MODEL_PREFIX \ | ||
--file-path=$MODEL_CONFIG_FILE \ | ||
--monitoring-enabled=$PROMETHEUS_MONITORING_ENABLED \ | ||
--monitoring-path=$PROMETHEUS_MONITORING_PATH \ | ||
--monitoring-file-path=$MONITORING_CONFIG_FILE \ | ||
--enable-batching=$MONITORING_CONFIG_FILE \ | ||
--max-batch-size=$MAX_BATCH_SIZE \ | ||
--batch-timeout=$BATCH_TIMEOUT_MICROS \ | ||
--max-enqueued-batches=$MAX_ENQUEUED_BATCHES \ | ||
--batch-file-path=$BATCHING_CONFIG_FILE |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
# Copyright 2016-2020 The Van Valen Lab at the California Institute of | ||
# Technology (Caltech), with support from the Paul Allen Family Foundation, | ||
# Google, & National Institutes of Health (NIH) under Grant U24CA224309-01. | ||
# All rights reserved. | ||
# | ||
# Licensed under a modified Apache License, Version 2.0 (the "License"); | ||
# you may not use this file except in compliance with the License. | ||
# You may obtain a copy of the License at | ||
# | ||
# http://www.github.com/vanvalenlab/kiosk-tf-serving/LICENSE | ||
# | ||
# The Work provided may be used for non-commercial academic purposes only. | ||
# For any other use of the Work, including commercial use, please contact: | ||
# vanvalenlab@gmail.com | ||
# | ||
# Neither the name of Caltech nor the names of its contributors may be used | ||
# to endorse or promote products derived from this software without specific | ||
# prior written permission. | ||
# | ||
# Unless required by applicable law or agreed to in writing, software | ||
# distributed under the License is distributed on an "AS IS" BASIS, | ||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. | ||
# See the License for the specific language governing permissions and | ||
# limitations under the License. | ||
# ============================================================================ | ||
|
||
FROM tensorflow/serving:1.15.0-gpu | ||
|
||
ENV PORT=8500 \ | ||
REST_API_PORT=8501 \ | ||
REST_API_TIMEOUT=30000 \ | ||
ENABLE_BATCHING=true \ | ||
TF_CPP_MIN_LOG_LEVEL=0 \ | ||
AWS_LOG_LEVEL=3 \ | ||
GRPC_CHANNEL_ARGS="" \ | ||
TF_SESSION_PARALLELISM=0 \ | ||
MODEL_CONFIG_FILE=/config/models.conf \ | ||
BATCHING_CONFIG_FILE=/config/batching_config.txt \ | ||
MONITORING_CONFIG_FILE=/config/monitoring_config.txt | ||
|
||
COPY ./bin/serve.sh /usr/local/bin/entrypoint.sh | ||
|
||
ENTRYPOINT "/usr/local/bin/entrypoint.sh" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
pytest<6 | ||
pytest-cov | ||
pytest-pep8 | ||
coveralls |