提交 ce2fc053 编写于 作者: M MRXLT

fix ci

上级 d71783e0
#!/usr/bin/env bash #!/usr/bin/env bash
set -x
function unsetproxy() { function unsetproxy() {
HTTP_PROXY_TEMP=$http_proxy HTTP_PROXY_TEMP=$http_proxy
HTTPS_PROXY_TEMP=$https_proxy HTTPS_PROXY_TEMP=$https_proxy
...@@ -454,15 +454,16 @@ function python_test_lac() { ...@@ -454,15 +454,16 @@ function python_test_lac() {
cd lac # pwd: /Serving/python/examples/lac cd lac # pwd: /Serving/python/examples/lac
case $TYPE in case $TYPE in
CPU) CPU)
sh get_data.sh python -m paddle_serving_app.package --get_model lac
check_cmd "python -m paddle_serving_server.serve --model jieba_server_model/ --port 9292 &" tar -xzvf lac.tar.gz
check_cmd "python -m paddle_serving_server.serve --model lac_model/ --port 9292 &"
sleep 5 sleep 5
check_cmd "echo \"我爱北京天安门\" | python lac_client.py jieba_client_conf/serving_client_conf.prototxt lac_dict/" check_cmd "echo \"我爱北京天安门\" | python lac_client.py lac_client/serving_client_conf.prototxt "
echo "lac CPU RPC inference pass" echo "lac CPU RPC inference pass"
kill_server_process kill_server_process
unsetproxy # maybe the proxy is used on iPipe, which makes web-test failed. unsetproxy # maybe the proxy is used on iPipe, which makes web-test failed.
check_cmd "python lac_web_service.py jieba_server_model/ lac_workdir 9292 &" check_cmd "python lac_web_service.py lac_model/ lac_workdir 9292 &"
sleep 5 sleep 5
check_cmd "curl -H \"Content-Type:application/json\" -X POST -d '{\"feed\":[{\"words\": \"我爱北京天安门\"}], \"fetch\":[\"word_seg\"]}' http://127.0.0.1:9292/lac/prediction" check_cmd "curl -H \"Content-Type:application/json\" -X POST -d '{\"feed\":[{\"words\": \"我爱北京天安门\"}], \"fetch\":[\"word_seg\"]}' http://127.0.0.1:9292/lac/prediction"
# check http code # check http code
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册