cazyundee commited on
Commit
6a6f8c0
·
verified ·
1 Parent(s): 005dc00

Use RAM loaded CPU model benchmark

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -260,7 +260,7 @@ def _run_bench_locked(model_filter=None):
260
  env["GGML_CUDA"] = "0"
261
  t0 = time.time()
262
  to = 90 if mi["size_gb"] <= 6 else 180
263
- command = [bench, "-m", mp, "-t", str(nt), "-ngl", "0", "-p", "32", "-n", "64", "-r", "1", "-o", "json"]
264
  _log(f"Running llama-bench for {mi['name']} on CPU with {nt} threads")
265
  p = subprocess.run(command, capture_output=True, text=True, timeout=to, env=env)
266
  wt = time.time()-t0
@@ -327,7 +327,7 @@ def _run_cpu_smoke(model_filter):
327
  result["phases"]["download"] = {"ok": False, "elapsed_sec": round(time.time() - t0, 2), "error": str(exc)}
328
  return result
329
 
330
- command = [cli, "-m", path, "-t", str(result["threads"]), "-ngl", "0", "-c", "256", "-n", "1", "-p", "Say hi.", "--no-display-prompt", "--no-warmup"]
331
  t0 = time.time()
332
  try:
333
  run = subprocess.run(command, capture_output=True, text=True, timeout=180, env=env)
 
260
  env["GGML_CUDA"] = "0"
261
  t0 = time.time()
262
  to = 90 if mi["size_gb"] <= 6 else 180
263
+ command = [bench, "-m", mp, "-t", str(nt), "-ngl", "0", "-c", "256", "-p", "32", "-n", "64", "-r", "1", "--no-mmap", "-o", "json"]
264
  _log(f"Running llama-bench for {mi['name']} on CPU with {nt} threads")
265
  p = subprocess.run(command, capture_output=True, text=True, timeout=to, env=env)
266
  wt = time.time()-t0
 
327
  result["phases"]["download"] = {"ok": False, "elapsed_sec": round(time.time() - t0, 2), "error": str(exc)}
328
  return result
329
 
330
+ command = [cli, "-m", path, "-t", str(result["threads"]), "-ngl", "0", "-c", "256", "-n", "1", "-p", "Say hi.", "--no-display-prompt", "--no-warmup", "--no-mmap", "-fa", "0"]
331
  t0 = time.time()
332
  try:
333
  run = subprocess.run(command, capture_output=True, text=True, timeout=180, env=env)