Today I came up with a Dynamo workflow to calculate the execution time of a series of nodes, it doesn’t need any dependency, but beware as it’s not sexy at all:
Basically, simple DateTime.Now
nodes do not update their values as the definition is run, so I created a dummy function called ForceTimeUpdate
in a code block that takes in a whatever input from the definition to trigger an update of the DateTime.Now
function. This is done by adding an empty TimeSpan
to it, that is generated from the code block input (the Count
and TimeSpan.Create
functions).
In the example above it takes 750ms to generate a matrix of 20x20x20 points and to count them.
If you know of a smarter way to do the same, please post it in the comments!
Download the definition: ElapsedTime.dyn