Skip to content

Commit 33a5244

Browse files
compare-llama-bench.py: fix long hexsha args (ggml-org#6424)
1 parent 226e819 commit 33a5244

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

scripts/compare-llama-bench.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,9 @@ def get_commit_hexsha8(name):
178178
for t in repo.tags:
179179
if t.name == name:
180180
return t.commit.hexsha[:8]
181+
for c in repo.iter_commits("--all"):
182+
if c.hexsha[:8] == name[:8]:
183+
return c.hexsha[:8]
181184
return None
182185

183186

@@ -224,7 +227,7 @@ def get_commit_hexsha8(name):
224227
hexsha8_compare = get_commit_hexsha8(known_args.compare)
225228
name_compare = known_args.compare
226229
if hexsha8_compare is None:
227-
print(f"ERROR: cannot find data for baseline={known_args.compare}.")
230+
print(f"ERROR: cannot find data for compare={known_args.compare}.")
228231
sys.exit(1)
229232
# Otherwise, search for the commit for llama-bench was most recently run
230233
# and that is not a parent of master:

0 commit comments

Comments
 (0)