Skip to content

Commit 2b4c569

Browse files
committed
include how total_time modified when flattening
1 parent c01071f commit 2b4c569

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

pyomo/common/timing.py

+6
Original file line numberDiff line numberDiff line change
@@ -978,6 +978,12 @@ def flatten(self):
978978
"""Flatten the HierarchicalTimer in-place, moving all the timing
979979
categories into a single level
980980
981+
If any timers moved into the same level have the same identifier,
982+
the ``total_time`` and ``n_calls`` fields are added together.
983+
The ``total_time`` of a "child timer" that is "moved upwards" is
984+
subtracted from the ``total_time`` of that timer's original
985+
parent.
986+
981987
"""
982988
if self.stack:
983989
raise RuntimeError(

0 commit comments

Comments
 (0)