better SQL
This commit is contained in:
parent
97c809448f
commit
829565b13d
1 changed files with 4 additions and 7 deletions
|
@ -1,19 +1,16 @@
|
|||
#!/usr/bin/env python3
|
||||
|
||||
import sqlite3
|
||||
import numpy as np
|
||||
import matplotlib.pyplot as plt
|
||||
|
||||
con = sqlite3.connect("llama.sqlite")
|
||||
cur = con.cursor()
|
||||
|
||||
ts = []
|
||||
res = cur.execute("SELECT n_gpu_layers, 1000000.0*n_eval/t_eval_us FROM llama_runs ORDER BY n_gpu_layers;")
|
||||
ts = np.array(res.fetchall())
|
||||
|
||||
for ngl in range(0, 36):
|
||||
res = cur.execute(f"SELECT t_eval_us,n_eval FROM llama_runs WHERE n_gpu_layers={ngl};")
|
||||
t_eval_us, n_eval = res.fetchone()
|
||||
ts.append(n_eval * 1000000/t_eval_us)
|
||||
|
||||
plt.plot(ts)
|
||||
plt.plot(ts[:, 0], ts[:, 1])
|
||||
plt.xlim(0, 35)
|
||||
plt.ylim(0, 130)
|
||||
plt.title("7b q4_0, 3700X, 3200 MHz dual-channel RAM, RTX 3090")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue