https://github.com/ggerganov/llama.cpp/pull/6920

#26
Files changed (1) hide show
  1. gguf-imat-llama-3.py +2 -2
gguf-imat-llama-3.py CHANGED
@@ -101,7 +101,7 @@ def download_model_repo():
101
  convert_model_to_gguf_f16(base_dir, model_dir, model_name, delete_model_dir, imatrix_file_name)
102
 
103
  def convert_model_to_gguf_f16(base_dir, model_dir, model_name, delete_model_dir, imatrix_file_name):
104
- convert_script = os.path.join(base_dir, "llama.cpp", "convert.py")
105
  gguf_dir = os.path.join(base_dir, "models", f"{model_name}-GGUF")
106
  gguf_model_path = os.path.join(gguf_dir, f"{model_name}-F16.gguf")
107
 
@@ -109,7 +109,7 @@ def convert_model_to_gguf_f16(base_dir, model_dir, model_name, delete_model_dir,
109
  os.makedirs(gguf_dir)
110
 
111
  if not os.path.exists(gguf_model_path):
112
- subprocess.run(["python", convert_script, model_dir, "--outfile", gguf_model_path, "--outtype", "f16", "--vocab-type", "bpe"])
113
 
114
  if delete_model_dir == 'yes' or delete_model_dir == 'y':
115
  shutil.rmtree(model_dir)
 
101
  convert_model_to_gguf_f16(base_dir, model_dir, model_name, delete_model_dir, imatrix_file_name)
102
 
103
  def convert_model_to_gguf_f16(base_dir, model_dir, model_name, delete_model_dir, imatrix_file_name):
104
+ convert_script = os.path.join(base_dir, "llama.cpp", "convert-hf-to-gguf.py")
105
  gguf_dir = os.path.join(base_dir, "models", f"{model_name}-GGUF")
106
  gguf_model_path = os.path.join(gguf_dir, f"{model_name}-F16.gguf")
107
 
 
109
  os.makedirs(gguf_dir)
110
 
111
  if not os.path.exists(gguf_model_path):
112
+ subprocess.run(["python", convert_script, model_dir, "--outfile", gguf_model_path, "--outtype", "f16"])
113
 
114
  if delete_model_dir == 'yes' or delete_model_dir == 'y':
115
  shutil.rmtree(model_dir)