3 ms·
> I haven't benchmarked this yet if you don't measure, you're just guessing. > after my first experiences with somewhat complex data transformations in numpy
by jstrong 7y ago
> I haven't benchmarked this yet
if you don't measure, you're just guessing.
> after my first experiences with somewhat complex data transformations in numpy and pandas
there are fast ways and slow ways to use numpy/pandas, but generally speaking, it's easy to get order of magnitude improvements using pandas compared to an RDBMS.
In pandas, for example, the data from a column is a contiguous in-memory array. Generally RDBMS data is row-oriented, possibly in memory or possibly on disk. Performing some numerical operation on the contiguous array is going to play to the cpu's strengths much better.