Skip to content

Clean up ORC reader benchmarks with NVBench - #11543

Merged
rapids-bot[bot] merged 9 commits into
NVIDIA:branch-22.10from
PointKernel:refactor-orc-bench
Aug 23, 2022
Merged

rapids-bot[bot] merged 9 commits into
NVIDIA:branch-22.10from
PointKernel:refactor-orc-bench

Conversation

@PointKernel

@PointKernel PointKernel commented Aug 16, 2022 •

Copy link
Copy Markdown
Member

Description

Issue #10941

This PR rewrites the existing ORC reader benchmarks with nvbench w.r.t. #7960. It improves the input test case in which all data types were benchmarked with all compression and IO types. By splitting input into decode and io_compression, it reduces the number of test cases from 112 to 44.

The PR also removes the current row_selection test suite.

Checklist

  • I am familiar with the Contributing Guidelines.
  • New or existing tests cover these changes.
  • The documentation is up to date with these changes.

@PointKernel PointKernel added 3 - Ready for Review Ready for review by team CMake CMake build issue cuIO cuIO issue tech debt improvement Improvement / enhancement to an existing function non-breaking Non-breaking change labels Aug 16, 2022
@PointKernel PointKernel self-assigned this Aug 16, 2022
@PointKernel
PointKernel requested a review from a team as a code owner August 16, 2022 18:50
@PointKernel
PointKernel requested review from mythrocks and vuule August 16, 2022 18:50
@github-actions github-actions Bot added the libcudf Affects libcudf (C++/CUDA) code. label Aug 16, 2022
@vuule

vuule commented Aug 16, 2022

Copy link
Copy Markdown
Contributor

Discussed offline and decided to move the options benchmarks to NVBench as well in this PR. Will review once that's in.

@vuule vuule added 0 - Waiting on Author Waiting for author to respond to review and removed 3 - Ready for Review Ready for review by team labels Aug 16, 2022
@codecov

codecov Bot commented Aug 16, 2022 •

Copy link
Copy Markdown

Codecov Report

❗ No coverage uploaded for pull request base (branch-22.10@65a7821). Click here to learn what that means.
The diff coverage is n/a.

@@               Coverage Diff               @@
##             branch-22.10   #11543   +/-   ##
===============================================
  Coverage                ?   86.40%           
===============================================
  Files                   ?      145           
  Lines                   ?    22958           
  Branches                ?        0           
===============================================
  Hits                    ?    19837           
  Misses                  ?     3121           
  Partials                ?        0           

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@PointKernel PointKernel added 3 - Ready for Review Ready for review by team and removed 0 - Waiting on Author Waiting for author to respond to review labels Aug 16, 2022
Comment on lines +103 to +105
state.add_element_count(static_cast<double>(data_size) / time, "bytes_per_second");
state.add_element_count(mem_stats_logger.peak_memory_usage(), "peak_memory_usage");
state.add_element_count(source_sink.size(), "encoded_file_size");

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This use of add_element_count surprises me. We're basically using it to store arbitrary integers, stretching its core purpose a bit.

Also what do you think about adding state.add_global_memory_writes to show the size of the file in memory?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We're basically using it to store arbitrary integers, stretching its core purpose a bit.

Right, I see your concern. The latter two reporting peak memory usage and encoded file size are still fine but an API like add_element_rate would be more proper for mesurement like bytes per second.

Also what do you think about adding state.add_global_memory_writes to show the size of the file in memory?

I spent some time looking into auto throughput metrics like collect_stores_efficiency but found it's not easy to use since running it requires the system have performance counter privileges. e.g.

Run:  [1/8] throughput_bench [Device=0 T=1 Stride=1]
Warn: CUPTI failed to construct profiler: /home/yunsongw/Work/nvbench/nvbench/cupti_profiler.cxx:48: CUPTI call returned error: CUPTI_ERROR_INSUFFICIENT_PRIVILEGES
Fail: Unexpected error: /home/yunsongw/Work/nvbench/nvbench/cupti_profiler.cxx:48: CUPTI call returned error: CUPTI_ERROR_INSUFFICIENT_PRIVILEGES
Run:  [2/8] throughput_bench [Device=0 T=1 Stride=4]
Warn: CUPTI failed to construct profiler: /home/yunsongw/Work/nvbench/nvbench/cupti_profiler.cxx:48: CUPTI call returned error: CUPTI_ERROR_INSUFFICIENT_PRIVILEGES
Fail: Unexpected error: /home/yunsongw/Work/nvbench/nvbench/cupti_profiler.cxx:48: CUPTI call returned error: CUPTI_ERROR_INSUFFICIENT_PRIVILEGES

bytes_per_second measurement already includes the information provided by add_global_memory_writes so adding it won't help much in this particular case.

@vuule vuule left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

partial review, looking great so far

@PointKernel

PointKernel commented Aug 19, 2022 •

Copy link
Copy Markdown
Member Author
column_selection row_selection uses_index uses_numpy_dtype timestamp_type Samples CPU Time Noise GPU Time Noise bytes_per_second peak_memory_usage encoded_file_size
ALL NROWS YES YES EMPTY 11x 322.059 ms 0.02% 322.053 ms 0.02% 1667027311 771.392 MiB 175.078 MiB
ALL NROWS YES YES TIMESTAMP_NANOSECONDS 11x 322.123 ms 0.02% 322.116 ms 0.02% 1666701259 771.392 MiB 175.078 MiB
ALL NROWS YES NO EMPTY 11x 321.998 ms 0.02% 321.991 ms 0.02% 1667347298 752.252 MiB 175.078 MiB
ALL NROWS YES NO TIMESTAMP_NANOSECONDS 11x 322.715 ms 0.02% 322.708 ms 0.02% 1663645068 752.252 MiB 175.078 MiB
ALL NROWS NO YES EMPTY 11x 364.931 ms 0.03% 364.924 ms 0.03% 1471184767 771.392 MiB 175.078 MiB
ALL NROWS NO YES TIMESTAMP_NANOSECONDS 11x 364.808 ms 0.03% 364.801 ms 0.03% 1471682708 771.392 MiB 175.078 MiB
ALL NROWS NO NO EMPTY 11x 364.884 ms 0.07% 364.877 ms 0.07% 1471374729 752.252 MiB 175.078 MiB
ALL NROWS NO NO TIMESTAMP_NANOSECONDS 11x 364.809 ms 0.03% 364.802 ms 0.03% 1471677873 752.252 MiB 175.078 MiB

Here's an example output of the new benchmark.

@PointKernel
PointKernel requested a review from vuule August 19, 2022 17:55

@vuule vuule left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔥

@PointKernel

Copy link
Copy Markdown
Member Author

@gpucibot merge

@rapids-bot
rapids-bot Bot merged commit e431440 into NVIDIA:branch-22.10 Aug 23, 2022
@PointKernel
PointKernel deleted the refactor-orc-bench branch November 16, 2022 20:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3 - Ready for Review Ready for review by team CMake CMake build issue cuIO cuIO issue improvement Improvement / enhancement to an existing function libcudf Affects libcudf (C++/CUDA) code. non-breaking Non-breaking change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants