Skip to content

Commit 04feedb

Browse files
committedOct 24, 2024
Init working
1 parent e4e4662 commit 04feedb

File tree

5 files changed

+13
-3
lines changed

5 files changed

+13
-3
lines changed
 

‎.gitignore

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
**/__pycache__
2+
/data/nli_for_simcse.csv
3+
/e5v-8b*
4+
/merged-e5v-8b*
5+
/models
6+
/wandb
7+
/test.ipynb

‎ft_llm.py

+2
Original file line numberDiff line numberDiff line change
@@ -337,6 +337,8 @@ def train(
337337
bf16: bool = False,
338338
not_eol: bool = False,
339339
org_attn: bool = False,
340+
*arg,
341+
**kwarg
340342
):
341343
# set NCCL_DEBUG
342344

‎requirements.txt

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,6 @@ bitsandbytes==0.43.1
66
scipy
77
datasets==2.20.0
88
safetensors==0.4.3
9-
pandas==1.1.5
9+
pandas
1010
scikit-learn
1111
prettytable

‎retrieval.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ def init_model_and_transform(lora_path, bf16, fp32, use_e5v=False):
190190
model_name = "llava-hf/llava-v1.6-mistral-7b-hf"
191191

192192
if MODEL_TYPE == 'llava_llama3':
193-
model_name = "./llava-llama-3-8b"
193+
model_name = "models/llava-llama-3-8b"
194194

195195
if lora_path is not None:
196196
merge_path = 'merged-' + lora_path.replace('/', '-').replace('.', '')

‎run.sh

+2-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ NUM_NODES=4
2626
wandb online
2727

2828

29-
NCCL_DEBUG=ERROR deepspeed --num_gpus=$GPUS --num_nodes=$NUM_NODES ft_llm.py \
29+
NCCL_DEBUG=ERROR deepspeed ft_llm.py \
3030
--base_model $BASE_MODEL \
3131
--data_path 'data/nli_for_simcse.csv' \
3232
--batch_size $BATCH_SIZE \
@@ -42,5 +42,6 @@ NCCL_DEBUG=ERROR deepspeed --num_gpus=$GPUS --num_nodes=$NUM_NODES ft_llm.py \
4242
--deepspeed ds.config \
4343
--lora_target_modules q_proj,k_proj,v_proj,o_proj,gate_proj,down_proj,up_proj --logging_steps 1 --grad_checkpoint \
4444
--load_kbit $BIT \
45+
--bf16 true \
4546
${args[@]}
4647

0 commit comments

Comments
 (0)
Please sign in to comment.