import pywapor takes a very long time

Issue #24 resolved
Alexander Kalinovsky created an issue

Hi,
import pywapor

The import time for the pywapor module takes too long: 1-1.5 minutes.

I quickly looked at the nested imports: it seems there are no imports with lengthy operations.
Perhaps this is all due to poorly cyclical imports?

What could be the problem?

python 3.10.*

Comments (5)

  1. Alexander Kalinovsky reporter

    @bert.coever

    I think the problem is using numba for optimization. Profiling showed that 95% of the time is spent calling call and essentially compiling the entire project code.

    If you comment out all the decorators from numba like @jit and so on, then import will take ~1sec

  2. bert.coerver

    Hi Alexander, thanks for letting me know. I guess we could try to import those decorated functions when they are actually needed, instead of importing them at the start.

  3. Log in to comment