I use gprof2dot together with cProfile:
https://taoofmac.com/space/blog/2014/07/07/2030
Here's a handy command line for it:
https://github.com/rcarmo/sushy/blob/master/Makefile#L86
...and a large diagram of a profiling session:
https://github.com/rcarmo/sushy/blob/master/pages/blog/2015/...