Instrumentalize code to measure latency and QPS (and save results)#2266
Open
cadurosar wants to merge 1 commit intocastorini:masterfrom
Open
Instrumentalize code to measure latency and QPS (and save results)#2266cadurosar wants to merge 1 commit intocastorini:masterfrom
cadurosar wants to merge 1 commit intocastorini:masterfrom
Conversation
Codecov ReportAttention:
Additional details and impacted files@@ Coverage Diff @@
## master #2266 +/- ##
============================================
- Coverage 61.67% 61.45% -0.23%
Complexity 1244 1244
============================================
Files 196 196
Lines 11554 11601 +47
Branches 1490 1494 +4
============================================
+ Hits 7126 7129 +3
- Misses 3889 3931 +42
- Partials 539 541 +2 ☔ View full report in Codecov by Sentry. |
Member
|
Hi @cadurosar, thanks for the PR, this is very neat. |
|
|
||
| @Option(name = "-instrumentalize", usage = "Add instrumentation to better report latency and QPS") | ||
| public boolean instrumentalize = false; | ||
|
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Here’s a pull request to add instrumentation to anserini and try to make latency/qps measuring standardized and a part of the retrieval. It basically stores the retrieval latencies and then computes average, median and p99 latency and stores in a file. Note that these are “best effort” latencies as you get the result before it is pretreated by Lucene in order to make it readable, but they are not exactly the server latency (imagine a server running Lucene and you are outside of it, it would be the latency including packet traffic but not result parsing).
Testing with arguana based on: https://github.com/cadurosar/anserini/blob/instrumentalize/docs/regressions/regressions-beir-v1.0.0-arguana-splade-distil-cocodenser-medium.md:
Without instrumentation:
Only information on QPS, need to read logs to get it.
With instrumentation:
Has latency information and creates a file which is the run name + _Efficiency. On this example "runs/run.beir-v1.0.0-arguana-splade_distil_cocodenser_medium.splade_distil_cocodenser_medium.topics.beir-v1.0.0-arguana.test.splade_distil_cocodenser_medium.txt_Efficiency"
This is just a first version, tell me what you think @lintool @ArthurChen189