Hacker News new | ask | show | jobs
by luispedrocoelho 3059 days ago
"spending an hour figuring out what arcane incantation I need to pass to np.einsum to get the operation I want"

Yes, I have also had this experience and I hate how in the end, the code is very hard to read, while the for loop was probably trivial.

1 comments

Every time I thought I needed einsum or similar arcane ops, I found that a Numba optimization for loop did the job.
Numba is nice, but it's another large dependency to pull in. If I can avoid it I will.