def METHOD_NAME(self, key, *args, **kwargs):
    ctx = TimingContext(self, key, *args, **kwargs)
    if key not in self:
        self[key] = ctx.initial_value()
    parent_ctx = self._open_contexts_stack[-1]
    parent_tree_node = parent_ctx.timing_tree_node
    if key not in parent_tree_node.timing:
        parent_tree_node.timing[key] = TimingTreeNode(ctx.initial_value())
    ctx.set_tree_node(parent_tree_node.timing[key])
    return ctx