'Arguments:
stack_depth (int): The number of stack frames above this constructor to capture.
include_arguments (bool): Whether to store the arguments that are passed
when capturing a stack trace.'

def __init__(self, stack_depth, include_arguments=True):

    self.include_arguments = include_arguments
    self._top_of_stack = traceback.extract_stack(limit=stack_depth)[0]
    if self.include_arguments:
        self._stacks = defaultdict((lambda : defaultdict(int)))
    else:
        self._stacks = defaultdict(int)
