Skip to content

Benchmarking Stan #20

@spinkney

Description

@spinkney

I'm not sure if this will give exactly what you want as it's more meant for benchmarking speed of forward/rev model vs size.

For the mvn benchmarks, it's known that multivariate_normal and multivariate_normal_prec are not fully optimized (see stan-dev/math#2544). The benchmark to compare against at this time is multivariate_normal_cholesky.

Steps to bench:

  1. Clone stan-math.
  2. Setup Google Benchmark
cd lib/benchmark_1.5.1
mkdir build && cd build
cmake .. -DCMAKE_BUILD_TYPE=RELEASE
make
cd ../../..
  1. Run the develop branch benchmark
git checkout develop
./benchmarks/benchmark.py "multi_normal_cholesky_lpdf(vector, vector, matrix) => real" --skip_similar_signatures --csv benchmark_results.csv

The benchmark_results.csv contains the benchmarks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions