]> git.djapps.eu Git - pkg/ggml/sources/llama.cpp/commitdiff
Revert "weights_only" arg - this causing more trouble than help
authorGeorgi Gerganov <redacted>
Sun, 12 Mar 2023 18:59:01 +0000 (20:59 +0200)
committerGeorgi Gerganov <redacted>
Sun, 12 Mar 2023 18:59:01 +0000 (20:59 +0200)
README.md
convert-pth-to-ggml.py

index 1c80d8a33ec59b5df65faefeaf53f573b35266cf..3437862068592ef625caaba71f3b284e3eb9170a 100644 (file)
--- a/README.md
+++ b/README.md
@@ -136,7 +136,6 @@ ls ./models
 65B 30B 13B 7B tokenizer_checklist.chk tokenizer.model
 
 # install Python dependencies
-# preferred versions: python 3.10 (not 3.11), torch 1.13.1+
 python3 -m pip install torch numpy sentencepiece
 
 # convert the 7B model to ggml FP16 format
index ef50fc65a447f92d5d1068c605d3304de4592d49..fc217c7ec3b328a613be93efa57fc793f282e641 100644 (file)
@@ -86,8 +86,7 @@ for p in range(n_parts):
     if (p > 0):
         fname_out = sys.argv[1] + "/ggml-model-" + ftype_str[ftype] + ".bin" + "." + str(p)
 
-    # weights_only requires torch 1.13.1, remove this param or update if you get an "invalid keyword argument" error
-    model = torch.load(fname_model, map_location="cpu", weights_only=True)
+    model = torch.load(fname_model, map_location="cpu")
 
     fout = open(fname_out, "wb")