Skip to content
Permalink
Browse files

Created a more file of small_data analysis called complete_analysis (…

…which isn't complete yet, I need analysis3.csv). Added code to generate plot for blocks vs time vs algorithm for 1 thread.
  • Loading branch information
rjm11010 committed May 3, 2017
1 parent 8cf890b commit ae4f00b9fdb50444c270ba6ce2a81e6de732401f
Showing with 197 additions and 6 deletions.
  1. +13 −6 data_analysis.R
  2. +184 −0 parallel/complete_analysis.csv
@@ -7,10 +7,12 @@ library(ggplot2)
# Load the data
# Change path to file
# data_path <- '../parallel/analysis.csv' # You can use this instead
data_path <- '/home/reynaldo/Documents/School/Spring2017/HPC/project/parallel_mcmc/parallel/analysis.csv'
data_path <- '/home/reynaldo/Documents/School/Spring2017/HPC/project/parallel_mcmc/parallel/complete_analysis.csv'
perf_data <- read.csv(file=data_path, header=TRUE, sep=",")
melted_data <- melt(perf_data, id=c("trial", "block", "thread"))
five_hundred_trials <- melted_data[which(melted_data$trial == 500), ]
five_hundred_trials$thread = as.factor(five_hundred_trials$thread)


# Generate Plots

@@ -23,7 +25,6 @@ base_plot <- base_plot + ggtitle("Blocks vs Time") + theme(plot.title = element_
base_plot

# Find which combination of blocks and threads works best
five_hundred_trials$thread = as.factor(five_hundred_trials$thread)
ours_five_hundred_trials <- five_hundred_trials[which(five_hundred_trials$variable == "our_time"), ]
ours_five_hundred_trials <- ours_five_hundred_trials[which(!is.na(ours_five_hundred_trials$thread)), ]

@@ -34,10 +35,16 @@ line_base <- line_base + xlab("Blocks") + ylab("Time (seconds)") + labs(colour
line_base <- line_base + ggtitle("Blocks vs Time vs Threads") + theme(plot.title = element_text(hjust = 0.5))
line_base

# Line Plot
line_base <- ggplot(five_hundred_trials, aes(x=block, y=value, group=variable, shape=variable, color=variable)) +

# Best Number of threads vs The other implementations for Blocks vs Time
one_threads_500_trials <- five_hundred_trials[which(five_hundred_trials$thread == 1), ]

line_base <- ggplot(one_threads_500_trials, aes(x=block, y=value, group=variable, shape=variable, color=variable)) +
geom_line() +
geom_point()
line_base <- line_base + xlab("Blocks") + ylab("Time (seconds)")
line_base <- line_base + ggtitle("Blocks vs Time") + theme(plot.title = element_text(hjust = 0.5))
line_base <- line_base + xlab("Blocks") + ylab("Time (seconds)") + labs(colour = "Implementations", shape="Implementations")
line_base <- line_base + ggtitle("Blocks vs Time vs Implementation") + theme(plot.title = element_text(hjust = 0.5))
line_base



@@ -0,0 +1,184 @@
trial,block,thread,seq_time,our_time,their_time
1000,10,1,2.48,7.14,5.51
1000,10,1,2.53,6.67,5.51
1000,10,16,2.50,139.07,5.48
1000,10,16,2.54,178.51,5.44
1000,10,2,2.51,8.21,5.53
1000,10,2,2.52,8.76,5.73
1000,10,32,2.51,538.93,5.67
1000,10,4,2.52,13.49,5.76
1000,10,4,2.56,16.78,5.43
1000,10,8,2.48,38.57,5.68
1000,10,8,2.50,49.38,5.51
1000,1,1,2.52,15.32,3.50
1000,1,1,2.56,17.62,5.64
1000,1,16,2.50,27.86,5.47
1000,1,16,2.52,4.98,3.51
1000,1,2,2.49,9.16,3.48
1000,1,2,2.50,11.39,5.43
1000,1,32,2.48,52.96,5.74
1000,1,32,2.54,8.68,3.48
1000,1,4,2.53,8.39,5.42
1000,1,4,2.56,6.09,3.47
1000,1,8,2.53,7.11,5.84
1000,1,8,2.54,4.80,3.48
1000,2,1,2.50,11.11,5.80
1000,2,1,2.53,9.06,3.53
1000,2,16,2.49,8.60,3.49
1000,2,16,2.53,12.81,5.52
1000,2,2,2.52,6.00,3.49
1000,2,2,2.53,8.29,5.54
1000,2,32,2.51,33.89,5.45
1000,2,32,2.54,24.51,3.52
1000,2,4,2.49,7.04,5.56
1000,2,4,2.52,4.74,3.48
1000,2,8,2.48,27.41,5.68
1000,2,8,2.48,4.85,3.46
1000,3,1,2.50,6.92,3.48
1000,3,1,2.51,9.33,5.67
1000,3,16,2.50,15.13,3.48
1000,3,16,2.50,21.80,5.75
1000,3,2,2.48,5.03,3.43
1000,3,2,2.49,7.32,5.64
1000,3,32,2.51,51.25,3.50
1000,3,32,2.55,68.31,5.77
1000,3,4,2.48,4.48,3.49
1000,3,4,2.51,20.97,5.62
1000,3,8,2.51,6.26,3.49
1000,3,8,2.54,9.66,5.54
1000,4,1,2.51,8.08,5.41
1000,4,1,2.56,5.88,3.52
1000,4,16,2.51,33.86,5.76
1000,4,16,2.52,26.73,5.79
1000,4,2,2.48,7.51,5.56
1000,4,2,2.49,4.64,3.43
1000,4,32,2.49,116.94,5.75
1000,4,32,2.53,90.77,5.67
1000,4,4,2.49,9.10,5.70
1000,4,4,2.53,7.95,5.80
1000,4,8,2.52,10.62,5.57
1000,4,8,2.55,12.74,5.42
1000,5,1,2.48,7.32,5.71
1000,5,1,2.48,7.45,5.60
1000,5,16,2.55,49.56,5.50
1000,5,16,2.58,38.65,5.47
1000,5,2,2.48,6.85,5.81
1000,5,2,2.51,7.19,5.40
1000,5,32,2.52,139.01,5.45
1000,5,32,2.60,178.62,5.43
1000,5,4,2.50,32.43,5.55
1000,5,4,2.52,7.65,5.66
1000,5,8,2.51,17.09,5.76
1000,5,8,2.54,13.71,5.54
1000,6,1,2.49,7.02,5.72
1000,6,1,2.50,7.37,5.83
1000,6,16,2.48,53.47,5.64
1000,6,16,2.51,68.46,5.76
1000,6,2,2.53,6.64,5.64
1000,6,2,2.55,7.03,5.40
1000,6,32,2.50,253.79,5.50
1000,6,32,2.51,197.33,5.52
1000,6,4,2.48,8.74,5.50
1000,6,4,2.50,9.83,5.65
1000,6,8,2.48,17.27,5.44
1000,6,8,2.54,23.41,5.85
1000,7,1,2.49,6.93,5.51
1000,7,1,2.50,7.14,5.43
1000,7,16,2.51,70.84,5.40
1000,7,16,2.51,90.67,5.52
1000,7,2,2.48,6.81,5.54
1000,7,2,2.48,7.59,5.54
1000,7,32,2.51,342.33,5.46
1000,7,32,2.54,266.71,5.59
1000,7,4,2.50,9.88,5.60
1000,7,4,2.52,11.09,5.50
1000,7,8,2.49,27.16,5.48
1000,7,8,2.50,21.47,5.72
1000,8,1,2.49,6.63,5.56
1000,8,1,2.52,6.93,5.61
1000,8,16,2.51,116.35,5.51
1000,8,16,2.52,90.62,5.77
1000,8,2,2.52,7.20,5.69
1000,8,2,2.53,26.16,5.58
1000,8,32,2.49,444.95,5.70
1000,8,32,2.54,346.69,5.90
1000,8,4,2.48,12.75,5.58
1000,8,4,2.56,12.69,5.52
1000,8,8,2.50,33.50,5.39
1000,8,8,2.51,26.50,5.41
1000,9,1,2.53,7.05,5.69
1000,9,1,2.57,6.84,5.53
1000,9,16,2.52,145.90,5.79
1000,9,16,2.53,113.43,6.01
1000,9,2,2.52,8.06,5.59
1000,9,2,2.53,7.56,5.47
1000,9,32,2.52,437.83,5.73
1000,9,32,2.52,560.67,5.59
1000,9,4,2.51,12.51,5.68
1000,9,4,2.52,14.89,5.59
1000,9,8,2.51,41.42,6.13
1000,9,8,2.52,32.33,5.51
1500,1,1,3.77,24.00,6.07
1500,1,2,3.76,14.91,5.99
1500,1,4,3.76,10.19,6.00
1500,1,8,3.78,8.27,5.87
500,10,1,1.25,5.79,4.94
500,10,16,1.27,91.35,5.14
500,10,2,1.25,6.78,5.38
500,10,32,1.25,347.22,4.99
500,10,4,1.25,10.76,5.09
500,10,8,1.28,27.12,5.07
500,1,1,1.32,11.04,5.19
500,1,16,1.23,11.17,5.09
500,1,2,1.25,7.83,5.12
500,1,32,1.23,19.00,5.06
500,1,4,1.23,6.29,5.26
500,1,8,1.23,5.71,4.91
500,2,1,1.24,7.77,4.93
500,2,16,1.26,8.75,5.10
500,2,2,1.23,6.46,5.08
500,2,32,1.24,19.14,5.01
500,2,4,1.31,5.81,5.20
500,2,8,1.31,11.47,5.36
500,3,1,1.26,6.83,5.16
500,3,16,1.24,13.03,5.14
500,3,2,1.25,5.91,5.15
500,3,32,1.26,36.76,5.08
500,3,4,1.28,9.60,5.05
500,3,8,1.30,7.16,5.15
500,4,1,1.28,6.42,5.03
500,4,16,1.24,19.18,5.13
500,4,2,1.25,7.63,5.07
500,4,32,1.29,60.84,5.30
500,4,4,1.27,6.24,5.02
500,4,8,1.25,8.76,5.15
500,5,1,1.27,6.14,5.01
500,5,16,1.24,26.93,4.97
500,5,2,1.28,5.66,5.10
500,5,32,1.27,91.70,5.16
500,5,4,1.29,7.33,5.05
500,5,8,1.23,10.78,5.47
500,6,1,1.24,5.86,5.38
500,6,16,1.25,36.46,5.02
500,6,2,1.24,5.90,5.24
500,6,32,1.25,129.10,5.10
500,6,4,1.25,7.49,4.99
500,6,8,1.23,13.03,5.03
500,7,1,1.27,5.94,5.04
500,7,16,1.30,48.24,4.95
500,7,2,1.25,6.21,5.07
500,7,32,1.26,173.50,5.05
500,7,4,1.23,7.91,5.04
500,7,8,1.24,15.93,5.00
500,8,1,1.24,5.87,5.11
500,8,16,1.26,60.60,4.93
500,8,2,1.26,6.27,5.56
500,8,32,1.23,224.66,5.02
500,8,4,1.25,8.68,5.42
500,8,8,1.24,19.21,5.11
500,9,1,1.28,6.08,5.30
500,9,16,1.25,75.13,5.04
500,9,2,1.25,6.55,5.15
500,9,32,1.26,282.70,4.96
500,9,4,1.31,9.61,5.14
500,9,8,1.30,23.06,4.95

0 comments on commit ae4f00b

Please sign in to comment.
You can’t perform that action at this time.