3 ms·
matlab has been jit compiled for years now, the "for loops are slow" dogma is over. numerical computing in python is kinda weird as it wasn't the original purp
by a-dub 5y ago
matlab has been jit compiled for years now, the "for loops are slow" dogma is over.
numerical computing in python is kinda weird as it wasn't the original purpose and the fast math libraries were bolted on as an afterthought, but even then tools like numba do the same in python, although there's a bunch of nuance in writing simple enough python and hinting at the correct types for the variables in order to get it to compile something reasonable.
julia's let's use strict types, jit compile everything from day one and avoid locking approach is nice though.
- toxik 5y agoAfter numba’ing several nontrivial pieces of numpy code in my life, you might as well just rewrite it in nopython mode for Cython unless it’s very trivial stuff. Numba errors and partial coverage of numpy is a huge time sink in my experience.
- a-dub 5y agoit gets even more fun when you need to support both mkl and standard numpy libraries, as well as several bit widths. but it can be done and goes to show that it's not going to be putting optimization experts out of work yet. reading about the state of autograd libraries in julia seems to indicate the same.