PaddleOCR/deploy/pdserving/config.yml

72 lines
2.7 KiB
YAML
Raw Normal View History

2021-03-22 16:15:02 +08:00
#rpc端口, rpc_port和http_port不允许同时为空。当rpc_port为空且http_port不为空时会自动将rpc_port设置为http_port+1
2021-05-12 14:42:15 +08:00
rpc_port: 18091
2021-03-22 16:15:02 +08:00
#http端口, rpc_port和http_port不允许同时为空。当rpc_port可用且http_port为空时不自动生成http_port
2021-05-12 14:42:15 +08:00
http_port: 9998
2021-03-22 16:15:02 +08:00
#worker_num, 最大并发数。当build_dag_each_worker=True时, 框架会创建worker_num个进程每个进程内构建grpcSever和DAG
##当build_dag_each_worker=False时框架会设置主线程grpc线程池的max_workers=worker_num
2021-05-12 20:21:13 +08:00
worker_num: 10
2021-03-22 16:15:02 +08:00
#build_dag_each_worker, False框架在进程内创建一条DAGTrue框架会每个进程内创建多个独立的DAG
2021-05-12 14:42:15 +08:00
build_dag_each_worker: False
2021-03-22 16:15:02 +08:00
dag:
#op资源类型, True, 为线程模型False为进程模型
is_thread_op: False
#重试次数
2021-05-12 14:42:15 +08:00
retry: 10
2021-03-22 16:15:02 +08:00
#使用性能分析, True生成Timeline性能数据对性能有一定影响False为不使用
2021-05-12 14:42:15 +08:00
use_profile: True
2021-03-22 16:15:02 +08:00
tracer:
interval_s: 10
op:
det:
#并发数is_thread_op=True时为线程并发否则为进程并发
2021-05-12 20:19:40 +08:00
concurrency: 8
2021-03-22 16:15:02 +08:00
#当op配置没有server_endpoints时从local_service_conf读取本地服务配置
local_service_conf:
#client类型包括brpc, grpc和local_predictor.local_predictor不启动Serving服务进程内预测
client_type: local_predictor
#det模型路径
2021-05-12 20:19:40 +08:00
model_config: ./ppocr_det_mobile_2.0_serving
2021-03-22 16:15:02 +08:00
#Fetch结果列表以client_config中fetch_var的alias_name为准
fetch_list: ["save_infer_model/scale_0.tmp_1"]
#计算硬件ID当devices为""或不写时为CPU预测当devices为"0", "0,1,2"时为GPU预测表示使用的GPU卡
2021-05-12 14:42:15 +08:00
devices: "0"
2021-03-22 16:15:02 +08:00
2021-05-12 20:21:13 +08:00
ir_optim: True
2021-03-22 16:15:02 +08:00
rec:
#并发数is_thread_op=True时为线程并发否则为进程并发
2021-05-12 20:19:40 +08:00
concurrency: 4
2021-03-22 16:15:02 +08:00
#超时时间, 单位ms
timeout: -1
#Serving交互重试次数默认不重试
retry: 1
#当op配置没有server_endpoints时从local_service_conf读取本地服务配置
local_service_conf:
#client类型包括brpc, grpc和local_predictor。local_predictor不启动Serving服务进程内预测
client_type: local_predictor
#rec模型路径
2021-05-12 20:19:40 +08:00
model_config: ./ppocr_rec_mobile_2.0_serving
2021-03-22 16:15:02 +08:00
#Fetch结果列表以client_config中fetch_var的alias_name为准
2021-05-12 14:42:15 +08:00
fetch_list: ["save_infer_model/scale_0.tmp_1"]
2021-03-22 16:15:02 +08:00
#计算硬件ID当devices为""或不写时为CPU预测当devices为"0", "0,1,2"时为GPU预测表示使用的GPU卡
2021-05-12 14:42:15 +08:00
devices: "0"
2021-03-22 16:15:02 +08:00
2021-05-12 20:21:13 +08:00
ir_optim: True