News for hackers. Stuff that matters.
Re:Analyzing Data 170,000x Faster with Python by sgarland on Monday October 30, 2023 @10:15PM (#38079338)
In theory, Node is faster than Python due to this, among other things.

In practice, I have seen Node apps blocking or crashing far more often than Python apps, which drags the performance down just a bit.

In the meantime, @njit decorator on Python functions, and boom, done.

Re:Analyzing Data 170,000x Faster with Python by pjmlp on Tuesday October 31, 2023 @03:52AM (#38081438)
I am yet to see such thing, to each its own I guess.

@njit doesn't work in regular Python, requires installing Numba and only works in very specific use cases.

Re:Analyzing Data 170,000x Faster with Python by sgarland on Tuesday October 31, 2023 @09:19AM (#38084389)
Well yes, it’s not native, but the point was that it’s very simple to use (and install).

As to specificity, I’d argue that it works on the things which stand to benefit the most from it. Parallelizing loops, vectorizing, etc.

Re:Analyzing Data 170,000x Faster with Python by FridgeSeal on Tuesday October 31, 2023 @04:40PM (#38091063)
For those playing at home wondering why you can’t just do this on all Python loops:

The numba jit is for numerical code. You won’t magically get better performance iterating over a bunch of things you get back from your db for example.