File size: 1,801 Bytes
11c47aa |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 |
---
license: apache-2.0
datasets:
- Vi-VLM/Vista
language:
- vi
---
- Merged LoRA
- Training script
```bash
#!/bin/bash
PRETRAIN_CKPT_PATH=checkpoints/llava-qwen1.5-0.5b-pretrain-vista_description-3ep
BASE_MODEL=Qwen/Qwen1.5-0.5B
ROOT_DATA=data/llm_data
WANDB_PROJECT=chart-vision-llm CUDA_VISIBLE_DEVICES=0,1,2,3,4 deepspeed moellava/train/train_mem.py \
--lora_enable True --lora_r 128 --lora_alpha 256 --mm_projector_lr 0.00000125 \
--deepspeed ./scripts/zero2.json \
--model_name_or_path $BASE_MODEL \
--version qwen \
--data_path $ROOT_DATA/json_files/vista_llava.json \
--image_folder ${ROOT_DATA}/coco2017/train2017 \
--image_tower google/siglip-base-patch16-256-multilingual \
--image_projector_type mlp2x_gelu \
--pretrain_mm_mlp_adapter $PRETRAIN_CKPT_PATH/mm_projector.bin \
--tune_mm_mlp_adapter True \
--mm_vision_select_layer -2 \
--mm_use_im_start_end False \
--mm_use_im_patch_token False \
--image_aspect_ratio pad \
--group_by_modality_length True \
--bf16 True \
--output_dir ./checkpoints/ft-llava-qwen1.5-0.5b-vista_llava-lora-2ep \
--num_train_epochs 2 \
--per_device_train_batch_size 8 \
--per_device_eval_batch_size 2 \
--gradient_accumulation_steps 2 \
--evaluation_strategy "no" \
--save_strategy "steps" \
--save_steps 5000 \
--save_total_limit 1 \
--learning_rate 2e-5 \
--weight_decay 0. \
--warmup_ratio 0.03 \
--lr_scheduler_type "cosine" \
--logging_steps 10 \
--tf32 True \
--model_max_length 2048 \
--gradient_checkpointing True \
--dataloader_num_workers 4 \
--lazy_preprocess True \
--report_to wandb \
--push_to_hub True \
--cache_dir cache_dir \
--run_name ft-llava-qwen1.5-0.5b-vista_llava-lora-2ep
``` |