actuarialopensource / benchmarks

Some performance tests for actuarial applications
MIT License
14 stars 4 forks source link

Presentation of output #27

Open alecloudenback opened 1 year ago

alecloudenback commented 1 year ago

I think the first table like this facilitates comparison more so than the latte:

Times are in nanoseconds:
┌──────────┬──────────────────┬───────────────────┬─────────┬─────────────┬───────────────┐
│ Language │          Package │          Function │  Median │        Mean │ Relative Mean │
├──────────┼──────────────────┼───────────────────┼─────────┼─────────────┼───────────────┤
│   Python │  numpy_financial │               irr │ missing │  5339167688 │       332824x │
│   Python │           better │ irr_binary_search │ missing │     6167798 │          384x │
│   Python │           better │        irr_newton │ missing │      945813 │           59x │
│    Julia │ ActuaryUtilities │               irr │   16000 │       16042 │            1x │
└──────────┴──────────────────┴───────────────────┴─────────┴─────────────┴───────────────┘

vs

basic_term_benchmark:
- Julia CacheFlow basic_term:
    mean: TrialEstimate(192.127 ms)
    result: 1.4489630534602132e7
- Python jax basic_term_m:
    mean: 337.39129650000166 milliseconds
    result: 14489630.53460337
  Python lifelib basic_term_m:
    mean: 1182.7541804499986 milliseconds
    result: 14489630.534601536
  Python scratch basic_term_m:
    mean: 957.6274868500008 milliseconds
    result: 14489630.534603368