How to identify reasons for bad performance

Hallo there dear community,

recently i experience absolut abyssal script performance in dynamo (revit 23) and want to get to the bottom of it.

I have several script that mostly set or read parameters from specific elements and then transform that information via notes, python scripts or custom blocks. Some of them export to excel, some dont.

I run into cases where runnig those scripts via dynamo lead to loading for over a minute just to give me like 10-20 secs of breathing room to do something and then the loading starts again.

Following my Task-Manager my CPU is used for like 13%, RAM for about 80%, will upgrade this to 64gb soon. and the rest on 0 to 4%.

Are there additional reason it is so slow?

The refresh rate is manual, our modells arent really that large either.

Packages i have installed:
archi-lab 2023.
clockwork
Data-Shapes
DynamoforIronPython2.7
Rhythm
GenerativDesign
ZeroTouchNodes

Dynamo Core 2.16.1.2727
Dynamo Revit 2.16.1.6510

Thank You

Hi @Huettig ,

Can’t do a lot of work in the garage if you don’t bring your car. :wink:
Please share some files, screenshots, Revit samples, etc.

The only thing I can recommend to do is to use the TuneUp package to see how long each node takes to finish executing to narrow down what is causing long run times.

3 Likes

In my experience it comes down to too many custom nodes, too much data (e.g. maybe asking the model for all of its geometry), branching pathways versus using levels to carry data together and large transactions changing the model (in which case your model size will be the driver).

2 Likes

Hey,

thank you for your reply.
Here is a one of the more problematic scripts which pretty much load always after it was run once.


038 GAEB Import Parameter2.dyn (122.6 KB)
it reads following excel:
Excelwindowtest.xlsx (23.6 KB)

i tried giving a basic revit model too, but yeah that a little to much data.
Here is a screenshot atleast:

Thank you

This is probably the most problematic node I can see:

image

Collecting all elements in a model is generally not great, better to target specific categories and/or families if possible.

2 Likes

Hi, @Huettig!

Did you grab each node’s run times with TuneUp extension?

yes,

TuneUp is cool and all but my primary issue is not the inital run time. What bugs me is that if there occurs to be an error somewhere and i want to move/do stuff in the script after it is executed i pretty much cant do it, because dynamo then loads again.

makes error handeling very frustrating.

but here is the tuneup:

i will start with eliminating the all elements custom node block at the start and then maybe optimizing my python scripts. Thank You all.

Did you try click on Force Re-execute after changes has been made? Some times it’s works faster and more consistent, when you rerun all things from scratch.

Try to freeze “Parameterzuweisung 18.01.2023” at first. Try to replace it with standard node for parameters writing, If slowness is related to this node.