6.4.1.cProfile, snakeviz
流程
1.將程式簡化成一個可以反覆執行的.py
2.以cProfile做效能分析(profiling), 找出程式裡的效能瓶頸處
python -m cProfile -o profile.stats -s cumulative testViewer.py
3.以snakeviz做進一步效能分析
snakeviz profile.stats
Last updated
Was this helpful?
1.將程式簡化成一個可以反覆執行的.py
2.以cProfile做效能分析(profiling), 找出程式裡的效能瓶頸處
python -m cProfile -o profile.stats -s cumulative testViewer.py
3.以snakeviz做進一步效能分析
snakeviz profile.stats
Last updated
Was this helpful?