class documentation

class Snapshot(Metric): (source)

View In Hierarchy

A metric to track memory usage via tracemalloc snapshots.

Method __enter__ Undocumented
Method __exit__ Undocumented
Method __init__ Initialize the metric and register it under the specified name.
Method take_snapshot Stores a tracemalloc snapshot.
Instance Variable count Undocumented
Instance Variable enabled Undocumented
Instance Variable groupby Undocumented
Instance Variable nframes Undocumented
Instance Variable running Undocumented
Instance Variable snapshots Undocumented
Method _start_tracemalloc Undocumented
Method _stop_tracemalloc Undocumented
Method _summary Return a string summarizing the value of the metric.

Inherited from Metric:

Method __str__ Undocumented
Property name Undocumented
Method _merge Merge data from another metric of the same type.
Instance Variable _name Undocumented
def __enter__(self): (source)

Undocumented

def __exit__(self, exc_type, exc_value, traceback): (source)

Undocumented

def __init__(self, name, enabled=False, groupby='lineno', nframes=1, count=10): (source)

Initialize the metric and register it under the specified name.

def take_snapshot(self, where=''): (source)

Stores a tracemalloc snapshot.

Undocumented

Undocumented

Undocumented

Undocumented

Undocumented

snapshots: list = (source)

Undocumented

def _start_tracemalloc(self): (source)

Undocumented

def _stop_tracemalloc(self): (source)

Undocumented

def _summary(self): (source)

Return a string summarizing the value of the metric.