jeremiecoullon

Joined 11 years ago

Karma
110
Submissions
35
Member since
Aug 18
Computational stats / ML researcher. https://www.jeremiecoullon.com/
View on Hacker News

Recent submissions

Comment · 4 years ago
I just discovered this field; I needed an algorithm to compute a low rank approximation of a large covariance matrix without first building the matrix. I'm using algorithm 16 in this paper which is simple but very good!
Comment · 5 years ago
Nice to know that numba has these features; I'll have to check it out at some point!
Comment · 5 years ago
I haven't tried numba but I've heard good things about it! Nice linked tutorial. If I understand correctly, you pass in jitted functions (using numba, and jax) into iminuit which does the optimisation?

With Jax you can write native for loops that can also be jitted (I imagine you can also do this in numba?); this can then be really fast. Though in that case you would have to write the optimisation algorithm yourself which is not always practical!

Another big speedup in Jax is due to vmap/pmap, which allow to vectorise/parallelise computation. For example you can build a massive gram matrix really quickly using vmap.

Another point: Jax can also run on GPU (like numba :) ) without having to rewrite anything.

Comment · 5 years ago
I've been using JAX (https://jax.readthedocs.io/en/latest/) for scientific computing in general (in particular MCMC algorithms), as it's really fast. Even on a CPU you get massive speedups compared to numpy (can be up to 2 or 3 orders of magnitude faster in some cases).

The main selling point of the library is automatic differential and compilation to XLA, but I've been using it even when I don't need gradients, as it's really fast (due to compilation). I also really like the random number generator as it's very good for reproducibility.

I've played around with Julia in the past and really liked it, but in terms speed Jax has pretty much solved that problem for me

Comment · 5 years ago
I hadn't seen that; thanks!
Comment · 5 years ago
Comment · 5 years ago
The way to represent negative numbers (page 3 of the manual) is really cool: to do "a - b" you add a to the complement of b (with the complement of b being 2 - |b|).

It feels really similar to modular arithmetic: -3 = 7 (modulo 10)

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton