File size: 535 Bytes
1d7da3b 48f4c05 1d7da3b |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
def validate_config(cfg):
if cfg.adapter == "qlora":
if cfg.merge_lora:
# can't merge qlora if loaded in 8bit or 4bit
assert cfg.load_in_8bit is False
assert cfg.load_4bit is False
assert cfg.load_in_4bit is False
else:
assert cfg.load_in_8bit is False
assert cfg.load_4bit is False
assert cfg.load_in_4bit is True
# TODO
# MPT 7b
# https://github.com/facebookresearch/bitsandbytes/issues/25
# no 8bit adamw w bf16
|