lm-finetuner: Merger: Dequantize before merging lora adapter; More lora options;
This commit is contained in:
@@ -8,7 +8,7 @@ from transformers import (
|
||||
|
||||
class ModelLoader:
|
||||
def load(self, path: str, forceCpu: bool, q4OnGpu: bool, context: Context):
|
||||
q4 = q4OnGpu and context.accel and not forceCpu
|
||||
q4 = context.qLora and q4OnGpu and context.accel and not forceCpu
|
||||
|
||||
bbConfig = BitsAndBytesConfig(
|
||||
load_in_4bit=True,
|
||||
@@ -28,4 +28,6 @@ class ModelLoader:
|
||||
if not forceCpu:
|
||||
baseModel = baseModel.to(context.device)
|
||||
|
||||
print(baseModel)
|
||||
|
||||
return baseModel
|
||||
|
||||
Reference in New Issue
Block a user