This commit is contained in:
Quentin 2019-09-18 08:53:01 +02:00
parent 0c959ac6b6
commit b988b2cd13
3 changed files with 26 additions and 23 deletions

View file

@ -3,7 +3,7 @@ library(sqldf)
library(plyr)
library(cowplot)
thunder_ms <- read.csv("thunder_configure_19.csv")
thunder_ms <- read.csv("thunder_configure_20.csv")
thunder_ms <- sqldf("select run,ident,jmax,links,latency, CAST(latency as real) / 1000. as lat_ms from thunder_ms")
thunder_ms$links <- as.factor(thunder_ms$links)
@ -14,8 +14,8 @@ v1 <- ggplot(data = thunder_ms, aes(x = jmax, y=lat_ms, fill=links)) +
geom_boxplot(outlier.size=0.1) +
geom_hline(yintercept=800, color = "red", linetype="dashed") +
geom_hline(yintercept=400, color = "DarkGreen") +
annotate("text", x=7, y=550, label= "high", color="DarkGreen") +
annotate("text", x=7, y=1000, label= "acceptable", color="red") +
annotate("text", x=7.1, y=650, label= "high", color="DarkGreen") +
annotate("text", x=7, y=1200, label= "acceptable", color="red") +
coord_cartesian(xlim = c(1, 7)) +
#ylim(0,1000) +
scale_fill_grey() +
@ -30,14 +30,17 @@ thunder_rcv <- sqldf("select run,jmax,links,(9900-COUNT(latency)*1.0)/9900 as dl
thunder_rcv$jmax <- as.factor(thunder_rcv$jmax)
thunder_rcv$links <- as.factor(thunder_rcv$links)
v2 <- ggplot(data = thunder_rcv, aes(x = jmax, y=dlv, fill=links)) +
geom_boxplot(outlier.size=0.1) +
#geom_boxplot(outlier.size=0.1) +
geom_violin(scale='width') +
scale_y_continuous(labels = scales::percent) +
scale_fill_grey() +
coord_cartesian(ylim = c(0,0.2)) +
#scale_y_log10(labels = scales::percent) +
ylab("dropped packets") +
xlab("max allowed jitter") +
theme_classic()
thunder_bw <- read.csv("thunder_configure_19_bw.csv")
thunder_bw <- read.csv("thunder_configure_20_bw.csv")
thunder_bw <- sqldf("select run,jmax,links,udp_sent,udp_rcv,cells_sent,cells_rcv,1.0*cells_sent/udp_sent as sent_ratio,1.0*cells_rcv/udp_rcv as rcv_ratio from thunder_bw where udp_sent > 4000")
thunder_bw$jmax <- as.factor(thunder_bw$jmax)
thunder_bw$links <- as.factor(thunder_bw$links)
@ -45,7 +48,7 @@ thunder_bw$links <- as.factor(thunder_bw$links)
v3 <- ggplot(data = thunder_bw, aes(x = jmax, y=sent_ratio, fill=links)) +
geom_boxplot(outlier.size=0.1) +
#scale_y_log10() +
#scale_y_log10(labels = scales::percent) +
coord_cartesian(ylim = c(1,2)) +
scale_fill_grey() +
ylab("bandwidth ratio") +
xlab("max allowed jitter") +
@ -55,7 +58,7 @@ v3 <- ggplot(data = thunder_bw, aes(x = jmax, y=sent_ratio, fill=links)) +
t1 <- plot_grid(v1, v2, v3, labels = c('A', 'B', 'C'), ncol=1)
t1 + ggsave("thunder_configure.png", dpi=300, dev='png', height=15, width=15, units="cm")
thunder_links <- read.csv("thunder_configure_16_links.csv")
thunder_links <- read.csv("thunder_configure_partial_links.csv")
links_down_at_least_once <- sqldf("select run,xp_time,link_id, COUNT(status) as downcount, SUM(delta) as elapsed from thunder_links where status='down' group by run,link_id,xp_time")
links_down_at_least_once2 <- sqldf("select row_number () OVER (PARTITION BY run ORDER BY elapsed DESC) sorting,run,link_id,downcount,elapsed,xp_time,1.0*elapsed/xp_time down_ratio from links_down_at_least_once")
links_down_at_least_once2$sorting <- as.factor(links_down_at_least_once2$sorting)
@ -92,7 +95,7 @@ v5 <- ggplot(data = downtime, aes(x=sorting, y=dur)) +
gobal_links <- sqldf(
"
select ts,run,durations_global,8-COUNT(status) as down_link_count,xp_time
select ts,run,durations_global,12-COUNT(status) as down_link_count,xp_time
from thunder_links
where will_change_global='True' and status='up' and durations_global > 0
group by ts,run,durations_global
@ -148,16 +151,16 @@ v8 <- ggplot(data=latency_evol, aes(x=ident,y=lat_ms)) +
ylab("Latency (ms)") +
theme_classic()
thunder_drop <- read.csv("thunder_configure_16_drop.csv")
thunder_drop_2 <- sqldf("select run, packet_range, 1.0*count / 990 as packet_ratio, row_number() OVER (partition by packet_range order by run) sorting from thunder_drop where run LIKE '%-26' ")
thunder_drop <- read.csv("thunder_configure_partial_drop.csv")
thunder_drop_2 <- sqldf("select run, packet_range, 1.0*count / 990 as packet_ratio, row_number() OVER (partition by packet_range order by run) sorting from thunder_drop where run LIKE '%-23' ")
#cats <- c("0-989","990-1979","1980-2969","2970-3959","3960-4949","4950-5939","5940-6929","6930-7919","7920-8909","8910-9899")
thunder_drop_2$packet_range <- as.factor(thunder_drop_2$packet_range)
thunder_drop_2$sorting <- as.factor(thunder_drop_2$sorting)
thunder_drop_2$packet_range <- factor(
mapvalues(thunder_drop_2$packet_range, cats, cats),
levels = cats,
ordered = TRUE)
#thunder_drop_2$packet_range <- factor(
# mapvalues(thunder_drop_2$packet_range, cats, cats),
# levels = cats,
# ordered = TRUE)
v9 <- ggplot(data = thunder_drop_2, aes(x=packet_range, y=packet_ratio,fill=sorting)) +
geom_bar(stat="summary",position = "dodge") +
@ -171,8 +174,8 @@ v9 <- ggplot(data = thunder_drop_2, aes(x=packet_range, y=packet_ratio,fill=sort
theme_classic() +
theme(axis.text.x = element_text(angle = 45, hjust = 1), legend.key.size = unit(0.2, "cm"))
thunder_drop_burst <- read.csv("thunder_configure_16_drop_burst.csv")
tdb_ag <- sqldf("select run,count,COUNT(count) as oc from thunder_drop_burst where run LIKE '%-24' group by run,count")
thunder_drop_burst <- read.csv("thunder_configure_partial_drop_burst.csv")
tdb_ag <- sqldf("select run,count,COUNT(count) as oc from thunder_drop_burst where run LIKE '%-23' group by run,count")
tdb_ag_2 <- sqldf(
"
select
@ -203,7 +206,7 @@ v10 <- ggplot(data = tdb_ag_2, aes(x=count, y=oc_ratio)) +
scale_fill_grey() +
theme_classic()
thunder_red <- read.csv("thunder_configure_16_red.csv")
thunder_red <- read.csv("thunder_configure_partial_red.csv")
tred <- sqldf(
"
select
@ -217,7 +220,7 @@ from
thunder_red tr,
(select run,SUM(occur) as total from thunder_red group by run) as ag
WHERE
tr.run LIKE '%-26'
tr.run LIKE '%-23'
and tr.run = ag.run
")

View file

@ -410,19 +410,19 @@ thunder_configure_2_full_parse_bw:
thunder_configure_2_full_parse_links:
@. parse_lib.sh && \
parse_thunder_links thunder_configure_2 27
parse_thunder_links thunder_configure_2 41
thunder_configure_2_full_parse_drop:
@. parse_lib.sh && \
parse_thunder_drop thunder_configure_2 27
parse_thunder_drop thunder_configure_2 41
thunder_configure_2_full_parse_drop_burst:
@. parse_lib.sh && \
parse_thunder_drop_burst thunder_configure_2 27
parse_thunder_drop_burst thunder_configure_2 41
thunder_configure_2_full_parse_red:
@. parse_lib.sh && \
parse_thunder_red thunder_configure_2 27
parse_thunder_red thunder_configure_2 41
tor_just_many_latencies:
./run-3 \

View file

@ -54,7 +54,7 @@ parse_thunder_links() {
echo "run,ts,link_id,status,delta,duration,will_change,xp_time,durations_global,will_change_global"
get_xp $1 | while read r; do
for i in $(seq 0 1 $2); do
grep -q 'thunder-client 9900 30 100 8 450' out/$r-$i/info.txt && cat out/$r-$i/log/client-donar-stdout.log | ./links_parse.py $r-$i || true
grep -q 'thunder-client 9900 30 100 12 250' out/$r-$i/info.txt && cat out/$r-$i/log/client-donar-stdout.log | ./links_parse.py $r-$i || true
done
done
}