Rename variable
This commit is contained in:
parent
88b0d9effc
commit
b7148838f5
1 changed files with 2 additions and 2 deletions
|
@ -856,7 +856,7 @@ if not dir_model.is_dir():
|
||||||
print(f'Error: {args.model} is not a directory', file=sys.stderr)
|
print(f'Error: {args.model} is not a directory', file=sys.stderr)
|
||||||
sys.exit(1)
|
sys.exit(1)
|
||||||
|
|
||||||
ftype = {
|
ftype_map = {
|
||||||
"f32": gguf.GGMLQuantizationType.F32,
|
"f32": gguf.GGMLQuantizationType.F32,
|
||||||
"f16": gguf.GGMLQuantizationType.F16,
|
"f16": gguf.GGMLQuantizationType.F16,
|
||||||
}
|
}
|
||||||
|
@ -872,7 +872,7 @@ print(f"Loading model: {dir_model.name}")
|
||||||
hparams = Model.load_hparams(dir_model)
|
hparams = Model.load_hparams(dir_model)
|
||||||
|
|
||||||
model_class = Model.from_model_architecture(hparams["architectures"][0])
|
model_class = Model.from_model_architecture(hparams["architectures"][0])
|
||||||
model_instance = model_class(dir_model, ftype[args.outtype], fname_out, args.bigendian)
|
model_instance = model_class(dir_model, ftype_map[args.outtype], fname_out, args.bigendian)
|
||||||
|
|
||||||
print("Set model parameters")
|
print("Set model parameters")
|
||||||
model_instance.set_gguf_parameters()
|
model_instance.set_gguf_parameters()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue