All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] fio_generate_plots with setable resolution
@ 2011-08-05 14:33 Martin Steigerwald
  2011-08-05 17:49 ` Jens Axboe
  0 siblings, 1 reply; 3+ messages in thread
From: Martin Steigerwald @ 2011-08-05 14:33 UTC (permalink / raw)
  To: fio


[-- Attachment #1.1: Type: text/plain, Size: 467 bytes --]

Hi!

Use

fio_generate_plots somename 1600 1200

or something like that.

Just quit and dirty ATM. On interest I can make up a patch for inclusion 
in fio package *after* I finished my article ;).

Fonts tend to get small on hi resolutions. It seems gnuplot takes them as 
pixel not points/dots (related to some dots per inch).

Ciao,
-- 
Martin 'Helios' Steigerwald - http://www.Lichtvoll.de
GPG: 03B0 0D6C 0040 0710 4AFA  B82F 991B EAAC A599 84C7

[-- Attachment #1.2: fio_generate_plots_resolution.diff --]
[-- Type: text/x-patch, Size: 2270 bytes --]

--- /usr/bin/fio_generate_plots	2011-08-03 14:30:09.000000000 +0200
+++ fio_generate_plots	2011-08-05 16:28:37.966057883 +0200
@@ -15,6 +15,15 @@
 
 TITLE=$1
 
+# set resolution
+if [ "$2"x != "x" -a "$3"x != "x" ]; then
+	XRES="$2"
+	YRES="$3"
+else
+	XRES=800
+	YRES=600
+fi
+
 PLOT_LINE=""
 for i in *bw.log; do
 	if [ ! -r $i ]; then
@@ -30,7 +39,7 @@
 
 if [ "$PLOT_LINE"x != "x" ]; then
 	echo Making bw logs
-	echo "set title 'Bandwidth - $TITLE'; set xlabel 'time (msec)'; set ylabel 'KB/sec'; set terminal png; set output '$TITLE-bw.png'; plot " $PLOT_LINE | $GNUPLOT -
+	echo "set title 'Bandwidth - $TITLE'; set xlabel 'time (msec)'; set ylabel 'KB/sec'; set terminal png size $XRES,$YRES; set output '$TITLE-bw.png'; plot " $PLOT_LINE | $GNUPLOT -
 fi
 
 PLOT_LINE=""
@@ -48,7 +57,7 @@
 
 if [ "$PLOT_LINE"x != "x" ]; then
 	echo Making slat logs $PLOT_LINE
-	echo "set title 'Submission latency - $TITLE'; set xlabel 'time (msec)'; set ylabel 'latency (msec)'; set terminal png; set output '$TITLE-slat.png'; plot " $PLOT_LINE | $GNUPLOT -
+	echo "set title 'Submission latency - $TITLE'; set xlabel 'time (msec)'; set ylabel 'latency (msec)'; set terminal png size $XRES,$YRES; set output '$TITLE-slat.png'; plot " $PLOT_LINE | $GNUPLOT -
 fi
 
 PLOT_LINE=""
@@ -66,7 +75,7 @@
 
 if [ "$PLOT_LINE"x != "x" ]; then
 	echo Making clat logs $PLOT_LINE
-	echo "set title 'Completion latency - $TITLE'; set xlabel 'time (msec)'; set ylabel 'latency (msec)'; set terminal png; set output '$TITLE-clat.png'; plot " $PLOT_LINE | $GNUPLOT -
+	echo "set title 'Completion latency - $TITLE'; set xlabel 'time (msec)'; set ylabel 'latency (msec)'; set terminal png size $XRES,$YRES; set output '$TITLE-clat.png'; plot " $PLOT_LINE | $GNUPLOT -
 fi
 
 PLOT_LINE=""
@@ -84,5 +93,5 @@
 
 if [ "$PLOT_LINE"x != "x" ]; then
 	echo Making lat logs $PLOT_LINE
-	echo "set title 'Latency - $TITLE'; set xlabel 'time (msec)'; set ylabel 'latency (msec)'; set terminal png; set output '$TITLE-lat.png'; plot " $PLOT_LINE | $GNUPLOT -
+	echo "set title 'Latency - $TITLE'; set xlabel 'time (msec)'; set ylabel 'latency (msec)'; set terminal png size $XRES,$YRES; set output '$TITLE-lat.png'; plot " $PLOT_LINE | $GNUPLOT -
 fi

[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 198 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2011-08-05 20:17 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-08-05 14:33 [PATCH] fio_generate_plots with setable resolution Martin Steigerwald
2011-08-05 17:49 ` Jens Axboe
2011-08-05 20:17   ` Martin Steigerwald

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.