Comparing Python, Numpy, Numba and C++ for matrix multiplication

前端 未结 4 1225
北荒
北荒 2020-12-15 19:18

In a program I am working on, I need to multiply two matrices repeatedly. Because of the size of one of the matrices, this operation takes some time and I wanted to see whic

4条回答
  •  半阙折子戏
    2020-12-15 19:53

    Definitely use -O3 for optimization. This turns vectorizations on, which should significantly speed your code up.

    Numba is supposed to do that already.

提交回复
热议问题