hf_baichuan2_7b_base.py 621 Bytes
Newer Older
Leymore's avatar
Leymore committed
1
2
3
4
5
from opencompass.models import HuggingFaceCausalLM

models = [
    dict(
        type=HuggingFaceCausalLM,
6
7
8
        abbr='baichuan2-7b-base-hf',
        path="baichuan-inc/Baichuan2-7B-Base",
        tokenizer_path='baichuan-inc/Baichuan2-7B-Base',
Leymore's avatar
Leymore committed
9
10
11
        tokenizer_kwargs=dict(
            padding_side='left',
            truncation_side='left',
Leymore's avatar
Leymore committed
12
            trust_remote_code=True,
13
            use_fast=False,
Leymore's avatar
Leymore committed
14
15
16
17
        ),
        max_out_len=100,
        max_seq_len=2048,
        batch_size=8,
18
        model_kwargs=dict(device_map='auto', trust_remote_code=True),
Leymore's avatar
Leymore committed
19
20
21
        run_cfg=dict(num_gpus=1, num_procs=1),
    )
]