Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support creating more report formats. #4203

Merged
merged 1 commit into from
Sep 19, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 10 additions & 2 deletions tests/performance/ecommerce_hybrid_search/create_report.py
Original file line number Diff line number Diff line change
Expand Up @@ -124,15 +124,15 @@ def main():
parser.add_argument('vespa_file', type=str, help='Path to Vespa result file')
parser.add_argument('es_file', type=str, help='Path to ES result file')
parser.add_argument('report_type',
choices=['feed', 'query_1', 'query_n'],
choices=['feed', 'query_1', 'query_n', 'query_n_filter', 'query_n_refeed'],
help='Type of report to create')
parser.add_argument('--format', default='df', choices=['csv', 'df'], help='Output format printed to stdout')
parser.add_argument('--cpus', default=128, help='The number of CPUs used for the performance tests')

args = parser.parse_args()
report = args.report_type
global cpu_cores
cpu_cores = args.cpus
cpu_cores = int(args.cpus)
if report == 'feed':
print_feed_ratio_summary(args.vespa_file, args.es_file, args.format)
elif report == 'query_1':
Expand All @@ -142,6 +142,14 @@ def main():
print_query_ratio_summary(args.vespa_file, args.es_file,
"phase == 'after_flush' and filter == False",
args.format)
elif report == 'query_n_filter':
print_query_ratio_summary(args.vespa_file, args.es_file,
"phase == 'after_flush' and filter == True",
args.format)
elif report == 'query_n_refeed':
print_query_ratio_summary(args.vespa_file, args.es_file,
"phase == 'during_refeed' and filter == False",
args.format)


if __name__ == "__main__":
Expand Down