个人资料API服务器#
在对api_server进行基准测试之前,请安装lmdeploy预编译包并下载脚本和测试数据集:
pip install lmdeploy
git clone --depth=1 https://github.com/InternLM/lmdeploy
cd lmdeploy/benchmark
首先启动服务器(您可以参考这里获取指南),然后运行以下命令:
python3 benchmark/profile_restful_api.py --backend lmdeploy --num-prompts 5000 --dataset-path ShareGPT_V3_unfiltered_cleaned_split.json
有关profile_restful_api.py
的详细参数说明,请运行帮助命令python3 benchmark/profile_restful_api.py -h
。