mtasic85 commited on
Commit
d73bbdd
·
1 Parent(s): 6ffe1e7

cpt core 4

Browse files
scripts/cpt_core_model_4.py CHANGED
@@ -20,7 +20,7 @@ model, tokenizer = FastLanguageModel.from_pretrained(
20
  dtype=dtype,
21
  load_in_4bit=load_in_4bit,
22
  )
23
- print(f'{model=}')
24
 
25
  # print('Ignore loaded tokenizer by FastLanguageModel.from_pretrained and using AutoTokenizer.from_pretrained')
26
  # tokenizer = AutoTokenizer.from_pretrained('..', trust_remote_code=True, use_fast=True)
@@ -44,8 +44,7 @@ model = FastLanguageModel.get_peft_model(
44
  use_rslora = True, # We support rank stabilized LoRA
45
  loftq_config = None, # And LoftQ
46
  )
47
-
48
- print(f'{model=}')
49
 
50
 
51
  from datasets import Dataset
@@ -85,8 +84,10 @@ trainer = UnslothTrainer(
85
  packing=False, # Can make training 5x faster for short sequences.
86
 
87
  args = UnslothTrainingArguments(
88
- per_device_train_batch_size=16,
89
- gradient_accumulation_steps=64,
 
 
90
 
91
  warmup_ratio=0,
92
  num_train_epochs=1,
 
20
  dtype=dtype,
21
  load_in_4bit=load_in_4bit,
22
  )
23
+ # print(f'{model=}')
24
 
25
  # print('Ignore loaded tokenizer by FastLanguageModel.from_pretrained and using AutoTokenizer.from_pretrained')
26
  # tokenizer = AutoTokenizer.from_pretrained('..', trust_remote_code=True, use_fast=True)
 
44
  use_rslora = True, # We support rank stabilized LoRA
45
  loftq_config = None, # And LoftQ
46
  )
47
+ # print(f'{model=}')
 
48
 
49
 
50
  from datasets import Dataset
 
84
  packing=False, # Can make training 5x faster for short sequences.
85
 
86
  args = UnslothTrainingArguments(
87
+ # per_device_train_batch_size=16,
88
+ # gradient_accumulation_steps=64,
89
+ per_device_train_batch_size=2,
90
+ gradient_accumulation_steps=8,
91
 
92
  warmup_ratio=0,
93
  num_train_epochs=1,
scripts/{requirements.in → requirements-litgpt.in} RENAMED
File without changes
scripts/requirements-unsloth.in ADDED
@@ -0,0 +1,10 @@
 
 
 
 
 
 
 
 
 
 
 
1
+ # litgpt compatible litdata
2
+ litdata==0.2.17
3
+
4
+ # unsloth
5
+ unsloth
6
+ xformers
7
+ trl
8
+ peft
9
+ accelerate
10
+ bitsandbytes