Skip to content

Commit

Permalink
New plot
Browse files Browse the repository at this point in the history
  • Loading branch information
matthiasgoergens committed Jan 15, 2025
1 parent 9901ed1 commit 45dfef5
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions plotting/plot.gnuplot
Original file line number Diff line number Diff line change
Expand Up @@ -5,14 +5,14 @@

# 1) Choose SVG output
set terminal png size 1600,1200 font "Helvetica,10"
set output 'sp1_ceno_cpu_time.png'
set output 'sp1_ceno_mem.png'

# 2) Basic plot settings
set title "Scatterplot of sp1 vs ceno for sorting a vector"
set key left box
set grid
set xlabel "input length"
set ylabel "time to prove sorting (s)"
set ylabel "maximum memory in kiB"

# =========== DEFINE FUNCTIONS FOR FIT ===========
# We'll fit each data set separately to its own line.
Expand All @@ -22,16 +22,16 @@ f_ceno(x) = a_ceno*x + b_ceno
# =========== DO THE FITS ===========

# Fit sp1 data
fit f_sp1(x) "sp1.data" using 1:($3 + $4) via a_sp1, b_sp1
fit f_sp1(x) "sp1.data" using 1:6 via a_sp1, b_sp1

# Fit ceno data
fit f_ceno(x) "ceno.data" using 1:($3 + $4) via a_ceno, b_ceno
fit f_ceno(x) "ceno.data" using 1:6 via a_ceno, b_ceno

# 3) Plot: sp1 and ceno from the same data file
plot "sp1.data" using 1:($3 + $4) \
plot "sp1.data" using 1:6 \
with points title "SP1 with AVX512", \
f_sp1(x) title sprintf("sp1 fit: y=%.5fx+%.3f", a_sp1, b_sp1) lw 2, \
"ceno.data" using 1:($3 + $4) \
"ceno.data" using 1:6 \
with points title "Ceno", \
f_ceno(x) title sprintf("ceno fit: y=%.5fx+%.3f", a_ceno, b_ceno) lw 2

Expand Down
Binary file added plotting/sp1_ceno_mem.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 45dfef5

Please sign in to comment.