KshitijAmbilduke commited on
Commit
0f5c39f
1 Parent(s): b5cafa1

Upload 6 files

Browse files
new_extended_tokenizer/added_tokens.json ADDED
The diff for this file is too large to render. See raw diff
 
new_extended_tokenizer/special_tokens_map.json ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ {
2
+ "bos_token": {
3
+ "content": "<s>",
4
+ "lstrip": false,
5
+ "normalized": false,
6
+ "rstrip": false,
7
+ "single_word": false
8
+ },
9
+ "eos_token": {
10
+ "content": "</s>",
11
+ "lstrip": false,
12
+ "normalized": false,
13
+ "rstrip": false,
14
+ "single_word": false
15
+ },
16
+ "pad_token": "<PAD>",
17
+ "unk_token": {
18
+ "content": "<unk>",
19
+ "lstrip": false,
20
+ "normalized": false,
21
+ "rstrip": false,
22
+ "single_word": false
23
+ }
24
+ }
new_extended_tokenizer/tokenizer.json ADDED
The diff for this file is too large to render. See raw diff
 
new_extended_tokenizer/tokenizer.model ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9e556afd44213b6bd1be2b850ebbbd98f5481437a8021afaf58ee7fb1818d347
3
+ size 499723
new_extended_tokenizer/tokenizer_config.json ADDED
The diff for this file is too large to render. See raw diff
 
readme.md ADDED
@@ -0,0 +1,36 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Steps to run continued pretraining
2
+
3
+ 1. Install the environment from as given in `multilinguality_megatron/Readme.md`
4
+
5
+ 2. Run the following commands
6
+
7
+ ```bash
8
+ conda activate towerllm-env
9
+ bash multilinguality_megatron/convert2megatron.sh
10
+ bash multilinguality_megatron/model_sharding.sh
11
+ bash multilinguality_megatron/continue_pretraining.sh
12
+ ```
13
+
14
+ Arguments to take care of:
15
+ ```bash
16
+ convert2megatron.sh
17
+ --megatron_model: Path where the megatron weights are to be saved
18
+ --model: Path of huggingface model (KshitijAmbilduke/extended_non_uniform_model_tinyllama)
19
+ --size: 1 (for TinyLlama)
20
+ --repo: Location of the multilingual megatron repository
21
+
22
+
23
+ model_sharding.sh
24
+ --megatron_model: Path where the megatron weights are saved
25
+ --sharded_model: Path of folder to save shards of the model
26
+ --tp: Number of shards to create. (Number of shards == Number of GPUs used)
27
+ --vocab_size: 37005 (32000+5005)
28
+
29
+
30
+ continue_pretraining.sh
31
+ --data_path="1 data/data_text_document"
32
+ megatron_model: Path of folder containing sharded model
33
+ model_dir: Path for folding storing checkpoints
34
+ tokenizer_path: Path of extended tokenizer
35
+ tp: number of shards
36
+ ```