mirror of
https://github.com/hpcaitech/ColossalAI.git
synced 2025-06-27 15:57:16 +00:00
* [inference] support only TP (#4998) * support only tp * enable tp * add support for bloom (#5008) * [refactor] refactor gptq and smoothquant llama (#5012) * refactor gptq and smoothquant llama * fix import error * fix linear import torch-int * fix smoothquant llama import error * fix import accelerate error * fix bug * fix import smooth cuda * fix smoothcuda * [Inference Refactor] Merge chatglm2 with pp and tp (#5023) merge chatglm with pp and tp * [Refactor] remove useless inference code (#5022) * remove useless code * fix quant model * fix test import bug * mv original inference legacy * fix chatglm2 * [Refactor] refactor policy search and quant type controlling in inference (#5035) * [Refactor] refactor policy search and quant type controling in inference * [inference] update readme (#5051) * update readme * update readme * fix architecture * fix table * fix table * [inference] udpate example (#5053) * udpate example * fix run.sh * fix rebase bug * fix some errors * update readme * add some features * update interface * update readme * update benchmark * add requirements-infer --------- Co-authored-by: Bin Jia <45593998+FoolPlayer@users.noreply.github.com> Co-authored-by: Zhongkai Zhao <kanezz620@gmail.com>
51 lines
1.5 KiB
Bash
51 lines
1.5 KiB
Bash
script_dir=$(cd "$(dirname "$0")" && pwd)
|
|
cd "${script_dir}"
|
|
|
|
# 7b, fp16, 2 gpu, 1024, 128
|
|
for BATCH_SIZE in 2 4 8 16; do
|
|
CUDA_VISIBLE_DEVICES=0,1 colossalai run --nproc_per_node 2 --master_port 29800 ./benchmark.py \
|
|
--model="7b" \
|
|
--dtype="fp16" \
|
|
--batch_size=${BATCH_SIZE} \
|
|
--seq_len=1024 \
|
|
--new_length=128 \
|
|
--mb_size=$((${BATCH_SIZE}/2)) \
|
|
--pp_size=2
|
|
done
|
|
|
|
# 7b, fp16, 2 gpu, 512, 512
|
|
for BATCH_SIZE in 2 4 8 16 32; do
|
|
CUDA_VISIBLE_DEVICES=0,1 colossalai run --nproc_per_node 2 --master_port 29800 ./benchmark.py \
|
|
--model="7b" \
|
|
--dtype="fp16" \
|
|
--batch_size=${BATCH_SIZE} \
|
|
--seq_len=512 \
|
|
--new_length=512 \
|
|
--mb_size=$((${BATCH_SIZE}/2)) \
|
|
--pp_size=2
|
|
done
|
|
|
|
# 7b, fp16, 2 gpu, 1024, 128
|
|
for BATCH_SIZE in 2 4 8; do
|
|
CUDA_VISIBLE_DEVICES=0,1 colossalai run --nproc_per_node 2 --master_port 29800 ./benchmark.py \
|
|
--model="13b" \
|
|
--dtype="fp16" \
|
|
--batch_size=${BATCH_SIZE} \
|
|
--seq_len=1024 \
|
|
--new_length=128 \
|
|
--mb_size=$((${BATCH_SIZE}/2)) \
|
|
--pp_size=2
|
|
done
|
|
|
|
# 13b, fp16, 2 gpu, 512, 512
|
|
for BATCH_SIZE in 2 4 8 16; do
|
|
CUDA_VISIBLE_DEVICES=0,1 colossalai run --nproc_per_node 2 --master_port 29800 ./benchmark.py \
|
|
--model="13b" \
|
|
--dtype="fp16" \
|
|
--batch_size=${BATCH_SIZE} \
|
|
--seq_len=512 \
|
|
--new_length=512 \
|
|
--mb_size=$((${BATCH_SIZE}/2)) \
|
|
--pp_size=2
|
|
done
|