memray to profile python process. It helped me a lot to analyze python process on air.


pip install memray

sudo memray attach PID -o /tmp/FILE

sudo memray attach PID

https://github.com/bloomberg/memray https://github.com/bloomberg/memray/issues/653