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

perf(frequency): Use byte records instead of string records #891

Merged
merged 1 commit into from
Dec 16, 2024

Conversation

nwagner84
Copy link
Member

@nwagner84 nwagner84 commented Dec 16, 2024

Benchmark 1: ./pica-v0.25 frequency -su -H 'gnd_id,label,count' '041A/*{ (9, a) | 9? && 7 =~ "^T[bfgpsu][1z]$" }' DUMP.dat --where '[email protected] =^ "A" && 041A/*.9?' -o freq.csv
  Time (mean ± σ):     244.640 s ± 20.967 s    [User: 210.942 s, System: 18.619 s]
  Range (min … max):   229.814 s … 259.465 s    2 runs

Benchmark 2: ./pica-main frequency -su -H 'gnd_id,label,count' '041A/*{ (9, a) | 9? && 7 =~ "^T[bfgpsu][1z]$" }' DUMP.dat --where '[email protected] =^ "A" && 041A/*.9?' -o freq.csv
  Time (mean ± σ):     212.046 s ±  1.081 s    [User: 192.311 s, System: 18.450 s]
  Range (min … max):   211.281 s … 212.810 s    2 runs

Summary
  './pica-main frequency -su -H 'gnd_id,label,count' '041A/*{ (9, a) | 9? && 7 =~ "^T[bfgpsu][1z]$" }' DUMP.dat --where '[email protected] =^ "A" && 041A/*.9?' -o freq.csv' ran
    1.15 ± 0.10 times faster than './pica-v0.25 frequency -su -H 'gnd_id,label,count' '041A/*{ (9, a) | 9? && 7 =~ "^T[bfgpsu][1z]$" }' DUMP.dat --where '[email protected] =^ "A" && 041A/*.9?' -o freq.csv'

@nwagner84 nwagner84 added A-frequency Area: The frequency command C-optimization Category: optimization labels Dec 16, 2024
@nwagner84 nwagner84 self-assigned this Dec 16, 2024
@nwagner84 nwagner84 changed the title perf(frequency): Switch to byte records perf(frequency): Use byte records instead of string records Dec 16, 2024
@nwagner84 nwagner84 merged commit 5656ad6 into main Dec 16, 2024
20 checks passed
@nwagner84 nwagner84 deleted the freq-byte-record branch December 16, 2024 08:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-frequency Area: The frequency command C-optimization Category: optimization
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant