安裝:
pip install py-spy
監控pid生成火焰圖,文件爲profile.svg
py-spy record -o profile.svg --pid pid
參考文檔:https://www.xingmal.com/article/article/1232585298689527808
安裝:
pip install py-spy
監控pid生成火焰圖,文件爲profile.svg
py-spy record -o profile.svg --pid pid
參考文檔:https://www.xingmal.com/article/article/1232585298689527808
shell腳本獲取腳本所在目錄 執行腳本的父目錄不一定是當前的工作目錄。 url=$(dirname $(readlink -f $0))