Open chaithyagr opened 1 year ago
Are you still facing this issue ?
So I am facing this issue now (using multiprocessing) I have made some basic profiling using tuna for the visualization.
As we can see, the loading time is mostly due to external libraries (torch, sigpy, matplotlib and sigpy) are in the top three.
However, after this initial import there is no extra cost (import are cached internally by python)
Several possibilities:
Related stuff: https://stackoverflow.com/questions/4177735/best-practice-for-lazy-loading-python-modules https://wiki.python.org/moin/PythonSpeed/PerformanceTips#Import_Statement_Overhead
Reproducing the profiling:
python -X importtime -c "import mrinufft" 2> import.log
tuna import.log
For now imports seem really slow, make it faster for faster debug cycles