tracemalloc.Snapshot.compare_to()

compare_to(old_snapshot: Snapshot, group_by: str, cumulative: bool=False)

Compute the differences with an old snapshot. Get statistics as a sorted list of StatisticDiff instances grouped by group_by.

See the Snapshot.statistics() method for group_by and cumulative parameters.

The result is sorted from the biggest to the smallest by: absolute value of StatisticDiff.size_diff, StatisticDiff.size, absolute value of StatisticDiff.count_diff, Statistic.count and then by StatisticDiff.traceback.

doc_python
2016-10-07 17:45:16
Comments
Leave a Comment

Please login to continue.