Code Monkey home page Code Monkey logo

xtensor-benchmark's Introduction

Benchmarks for linear algebra frameworks

This benchmarking suite allows a direct comparison of popular linear algebra frameworks in C++. The libraries are easy-to-install using the conda package manager:

conda env create -f environment.yml

The environment.yml installs the following libraries:

  • xtensor with xsimd
  • Eigen3
  • Armadillo
  • Blitz++

After setting up the environment, it is advised to create a build directory, and execute cmake:

mkdir build
cd build
cmake .. -DCMAKE_INSTALL_PREFIX=$CONDA_PREFIX -DBENCHMARK_ALL=ON

You should see a message for each found library, similar to the following:

          COMPILING WITH
======================================


Found eigen     : /home/myuser/miniconda3/envs/bench/include/eigen3
Found Blitz     : /home/myuser/miniconda3/envs/bench/include | /home/myuser/miniconda3/envs/bench/lib/libblitz.so
Found Armadillo : /home/myuser/miniconda3/envs/bench/include | /home/myuser/miniconda3/envs/bench/lib/libarmadillo.so
Found xtensor   : /home/myuser/miniconda3/envs/bench/include
Found xsimd     : /home/myuser/miniconda3/envs/bench/include

This allows you to make sure you're compiling with the correct, up-to-date versions of the libraries.

To build and run the benchmarks, just use the following command:

make xbenchmark

If you are only interested in specific benchmarks, build with make xtensor_benchmark and then run manually ./xtensor_benchmark --benchmark_filter=my_benchmark. The backend to the benchmarks is the popular google-benchmark suite, so look there for more documentation.

xtensor-benchmark's People

Contributors

benbovy avatar emmenlau avatar floatdrop avatar johanmabille avatar wolfv avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.