mirror of
https://github.com/deepset-ai/haystack.git
synced 2025-11-01 18:29:32 +00:00
Separate data and view for benchmarks (#451)
* separate data and view for benchmarks * fixed typo
This commit is contained in:
parent
465ccbc12e
commit
25f34babce
@ -1,36 +0,0 @@
|
||||
<html>
|
||||
<head>
|
||||
<script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
|
||||
<script type="text/javascript">
|
||||
google.charts.load('current', {'packages':['bar']});
|
||||
google.charts.setOnLoadCallback(drawChart);
|
||||
|
||||
function drawChart() {
|
||||
var data = google.visualization.arrayToDataTable(
|
||||
[
|
||||
["Model", "Top 10 Accuracy", "Time"],
|
||||
["RoBERTa", 72.22222222222222, 56.033346766999784],
|
||||
["MiniLM", 38.88888888888889, 49.28621050500078],
|
||||
["BERT base", 31.48148148148148, 42.67899718899935],
|
||||
["BERT large", 53.70370370370371, 74.21550956300052],
|
||||
["XLMR large", 72.22222222222222, 76.56486266000047]
|
||||
]);
|
||||
|
||||
var options = {
|
||||
chart: {
|
||||
title: 'Reader Performance',
|
||||
subtitle: 'Time and Accuracy Benchmarks',
|
||||
},
|
||||
bars: 'horizontal' // Required for Material Bar Charts.
|
||||
};
|
||||
|
||||
var chart = new google.charts.Bar(document.getElementById('barchart_material'));
|
||||
|
||||
chart.draw(data, google.charts.Bar.convertOptions(options));
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<div id="barchart_material" style="width: 900px; height: 500px;"></div>
|
||||
</body>
|
||||
</html>
|
||||
39
docs/_src/benchmarks/reader_performance.json
Normal file
39
docs/_src/benchmarks/reader_performance.json
Normal file
@ -0,0 +1,39 @@
|
||||
{
|
||||
"chart_type": "BarChart",
|
||||
"title": "Reader Performance",
|
||||
"subtitle": "Time and Accuracy Benchmarks",
|
||||
"description": "",
|
||||
"bars": "horizontal",
|
||||
"columns": [
|
||||
"Model",
|
||||
"Top 10 Accuracy",
|
||||
"Time"
|
||||
],
|
||||
"data": [
|
||||
{
|
||||
"model": "RoBERTa",
|
||||
"accuracy": 72.22222222222222,
|
||||
"time": 56.033346766999784
|
||||
},
|
||||
{
|
||||
"model": "MiniLM",
|
||||
"accuracy": 38.88888888888889,
|
||||
"time": 49.28621050500078
|
||||
},
|
||||
{
|
||||
"model": "BERT base",
|
||||
"accuracy": 31.48148148148148,
|
||||
"time": 42.67899718899935
|
||||
},
|
||||
{
|
||||
"model": "BERT large",
|
||||
"accuracy": 53.70370370370371,
|
||||
"time": 74.21550956300052
|
||||
},
|
||||
{
|
||||
"model": "XLMR large",
|
||||
"accuracy": 72.22222222222222,
|
||||
"time": 76.56486266000047
|
||||
}
|
||||
]
|
||||
}
|
||||
@ -1,44 +0,0 @@
|
||||
<html>
|
||||
<head>
|
||||
<script type="text/javascript" src="https://www.gstatic.com/charts/loader.js"></script>
|
||||
<script type="text/javascript">
|
||||
google.charts.load('current', {'packages':['bar']});
|
||||
google.charts.setOnLoadCallback(drawChart);
|
||||
|
||||
function drawChart() {
|
||||
var data = google.visualization.arrayToDataTable(
|
||||
[
|
||||
["Model", "Recall", "Index Time", "Query Time"],
|
||||
["BM24 (Elasticsearch)", 1.0, 3.868239733, 0.47588522500000074],
|
||||
["DPR (FAISS)", 0.9629629629629629, 18.181850872000723, 1.358759985992947,],
|
||||
]);
|
||||
|
||||
var options = {
|
||||
chart: {
|
||||
title: 'Reader Performance',
|
||||
subtitle: 'Time and Accuracy Benchmarks',
|
||||
},
|
||||
bars: 'horizontal', // Required for Material Bar Charts.
|
||||
series: {
|
||||
0: { axis: 'recall' }, // Bind series 0 to an axis named 'distance'.
|
||||
1: { axis: 'time' }, // Bind series 1 to an axis named 'brightness'.
|
||||
2: { axis: 'time' } // Bind series 1 to an axis named 'brightness'.
|
||||
},
|
||||
axes: {
|
||||
x: {
|
||||
recall: {label: 'recall'}, // Bottom x-axis.
|
||||
time: {side: 'top', label: 'seconds'} // Top x-axis.
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
var chart = new google.charts.Bar(document.getElementById('barchart_material'));
|
||||
|
||||
chart.draw(data, google.charts.Bar.convertOptions(options));
|
||||
}
|
||||
</script>
|
||||
</head>
|
||||
<body>
|
||||
<div id="barchart_material" style="width: 900px; height: 500px;"></div>
|
||||
</body>
|
||||
</html>
|
||||
37
docs/_src/benchmarks/retriever_performance.json
Normal file
37
docs/_src/benchmarks/retriever_performance.json
Normal file
@ -0,0 +1,37 @@
|
||||
{
|
||||
"chart_type": "BarChart",
|
||||
"title": "Retriever Performance",
|
||||
"subtitle": "Time and Accuracy Benchmarks",
|
||||
"description": "",
|
||||
"bars": "horizontal",
|
||||
"columns": [
|
||||
"Model",
|
||||
"Recall",
|
||||
"Index Time",
|
||||
"Query Time"
|
||||
],
|
||||
"series": {
|
||||
"s0": "recall",
|
||||
"s1": "time",
|
||||
"s2": "time"
|
||||
},
|
||||
"axes": {
|
||||
"label": "recall",
|
||||
"time_side": "top",
|
||||
"time_label": "seconds"
|
||||
},
|
||||
"data": [
|
||||
{
|
||||
"model": "BM25 (Elasticsearch)",
|
||||
"recall": 1.0,
|
||||
"index_time": 3.868239733,
|
||||
"query_time": 0.47588522500000074
|
||||
},
|
||||
{
|
||||
"model": "DPR (FAISS)",
|
||||
"recall": 0.9629629629629629,
|
||||
"index_time": 18.181850872000723,
|
||||
"query_time": 1.358759985992947
|
||||
}
|
||||
]
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user