Grab this script and run yours like this:
python3 lsprofcalltree.py <your_script.py>
and analize it with kcachegrind.
kcachegrind <your_script.py.log>
I found the original script at python.org.