winglian commited on
Commit
7e82af3
1 Parent(s): cb554e7

Upload folder using huggingface_hub

Browse files
Files changed (4) hide show
  1. README.md +59 -0
  2. config.json +37 -0
  3. configs/pretrain-llava-mistral.yml +66 -0
  4. mm_projector.bin +3 -0
README.md ADDED
@@ -0,0 +1,59 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: apache-2.0
3
+ base_model: mistralai/Mistral-7B-v0.1
4
+ tags:
5
+ - generated_from_trainer
6
+ model-index:
7
+ - name: out
8
+ results: []
9
+ ---
10
+
11
+ <!-- This model card has been generated automatically according to the information the Trainer had access to. You
12
+ should probably proofread and complete it, then remove this comment. -->
13
+
14
+ [<img src="https://raw.githubusercontent.com/OpenAccess-AI-Collective/axolotl/main/image/axolotl-badge-web.png" alt="Built with Axolotl" width="200" height="32"/>](https://github.com/OpenAccess-AI-Collective/axolotl)
15
+ # out
16
+
17
+ This model is a pretrained version of the llava multimodal projector for [mistralai/Mistral-7B-v0.1](https://huggingface.co/mistralai/Mistral-7B-v0.1) on the liuhaotian/LLaVA-Pretrain dataset.
18
+
19
+ ## Model description
20
+
21
+ More information needed
22
+
23
+ ## Intended uses & limitations
24
+
25
+ More information needed
26
+
27
+ ## Training and evaluation data
28
+
29
+ More information needed
30
+
31
+ ## Training procedure
32
+
33
+ ### Training hyperparameters
34
+
35
+ The following hyperparameters were used during training:
36
+ - learning_rate: 0.002
37
+ - train_batch_size: 64
38
+ - eval_batch_size: 64
39
+ - seed: 42
40
+ - distributed_type: multi-GPU
41
+ - num_devices: 2
42
+ - gradient_accumulation_steps: 2
43
+ - total_train_batch_size: 256
44
+ - total_eval_batch_size: 128
45
+ - optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
46
+ - lr_scheduler_type: cosine
47
+ - lr_scheduler_warmup_steps: 10
48
+ - num_epochs: 1
49
+
50
+ ### Training results
51
+
52
+
53
+
54
+ ### Framework versions
55
+
56
+ - Transformers 4.34.1
57
+ - Pytorch 2.0.1+cu118
58
+ - Datasets 2.14.6
59
+ - Tokenizers 0.14.1
config.json ADDED
@@ -0,0 +1,37 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "_name_or_path": "mistralai/Mistral-7B-v0.1",
3
+ "architectures": [
4
+ "MistralForCausalLM"
5
+ ],
6
+ "bos_token_id": 1,
7
+ "eos_token_id": 2,
8
+ "freeze_mm_mlp_adapter": null,
9
+ "hidden_act": "silu",
10
+ "hidden_size": 4096,
11
+ "image_aspect_ratio": "square",
12
+ "image_grid_pinpoints": null,
13
+ "initializer_range": 0.02,
14
+ "intermediate_size": 14336,
15
+ "max_position_embeddings": 32768,
16
+ "mm_hidden_size": 1024,
17
+ "mm_projector_type": "mlp2x_gelu",
18
+ "mm_use_im_patch_token": false,
19
+ "mm_use_im_start_end": false,
20
+ "mm_vision_select_feature": "patch",
21
+ "mm_vision_select_layer": -2,
22
+ "mm_vision_tower": "openai/clip-vit-large-patch14",
23
+ "model_type": "llava_mistral",
24
+ "num_attention_heads": 32,
25
+ "num_hidden_layers": 32,
26
+ "num_key_value_heads": 8,
27
+ "rms_norm_eps": 1e-05,
28
+ "rope_theta": 10000.0,
29
+ "sliding_window": 4096,
30
+ "tie_word_embeddings": false,
31
+ "torch_dtype": "bfloat16",
32
+ "transformers_version": "4.34.1",
33
+ "tune_mm_mlp_adapter": true,
34
+ "use_cache": false,
35
+ "use_mm_proj": true,
36
+ "vocab_size": 32000
37
+ }
configs/pretrain-llava-mistral.yml ADDED
@@ -0,0 +1,66 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ base_model: mistralai/Mistral-7B-v0.1
2
+ model_type: MistralForCausalLM
3
+ tokenizer_type: LlamaTokenizer
4
+ is_mistral_derived_model: true
5
+
6
+ # multimodal pretrain
7
+ multimodal: true
8
+ mm_vision_tower: openai/clip-vit-large-patch14
9
+ tune_mm_mlp_adapter: true
10
+ mm_freeze_backbone: true
11
+ mm_vision_select_layer: -2
12
+ mm_projector_type: mlp2x_gelu
13
+ mm_image_folder: ./llava/
14
+ mm_use_im_patch_token: false
15
+
16
+ load_in_8bit: false
17
+ load_in_4bit: false
18
+ strict: false
19
+
20
+ datasets:
21
+ - path: ./data/blip_laion_cc_sbu_558k.json
22
+ dataset_prepared_path:
23
+ val_set_size: 0.0
24
+ output_dir: ./out
25
+
26
+ sequence_len: 2048
27
+ sample_packing: false
28
+ pad_to_sequence_len: true
29
+
30
+ wandb_project: axolotl-llava
31
+ wandb_entity: oaaic
32
+ wandb_watch:
33
+ wandb_run_id:
34
+ wandb_log_model:
35
+
36
+ gradient_accumulation_steps: 2
37
+ micro_batch_size: 64
38
+ num_epochs: 1
39
+ optimizer: adamw_torch
40
+ lr_scheduler: cosine
41
+ learning_rate: 0.002
42
+
43
+ train_on_inputs: false
44
+ group_by_length: false
45
+ bf16: true
46
+ fp16: false
47
+ tf32: false
48
+
49
+ gradient_checkpointing: true
50
+ early_stopping_patience:
51
+ resume_from_checkpoint:
52
+ local_rank:
53
+ logging_steps: 1
54
+ xformers_attention:
55
+ flash_attention: true
56
+
57
+ warmup_steps: 10
58
+ eval_steps:
59
+ save_steps: 0.1
60
+ debug:
61
+ deepspeed: deepspeed/zero2.json
62
+ weight_decay: 0.0
63
+ fsdp:
64
+ fsdp_config:
65
+ special_tokens:
66
+ pad_token: "<unk>"
mm_projector.bin ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:899a57019694a451a762dd4a78adb8c8c8ff7c9d37fb2822f6cb927ef997d105
3
+ size 41961085