identifying contributors to large file size and slow run time

Use this forum to post Vensim related questions.
Post Reply
Tim_IEA
Junior Member
Posts: 2
Joined: Fri Nov 19, 2021 1:59 am
Vensim version: DSS

identifying contributors to large file size and slow run time

Post by Tim_IEA »

Hi All,

Thanks for past help and thanks in advance for future help!

I'm looking to improve the run time of my model and reduce the output file size. I would like to know if there are any tools or means to identify which variables make the biggest contribution to slowing the model down and/or to the output file size.

There are usual suspects I'm addressing (reducing the number of subscripts in variables, vector select instead of sum used as sumproduct) but it would be good to have a more targeted approach across the thousands of variables in the model.

Any other advice is appreciated!
Thanks very much,
Tim
Administrator
Super Administrator
Posts: 4573
Joined: Wed Mar 05, 2003 3:10 am

Re: identifying contributors to large file size and slow run time

Post by Administrator »

There is a post on Tom's blog about how to optimize models, these steps can really speed up model execution.
https://metasd.com/2011/01/optimizing-vensim-models/

For saving, all you can really do is use a savelist and play with saveper.
Advice to posters seeking help (it really helps us to help you)
http://www.ventanasystems.co.uk/forum/v ... f=2&t=4391

Units are important!
http://www.bbc.co.uk/news/magazine-27509559
tomfid
Administrator
Posts: 3806
Joined: Wed May 24, 2006 4:54 am

Re: identifying contributors to large file size and slow run time

Post by tomfid »

I probably need to update that post.

Compiled simulation is definitely the most reliable big win. The mdl.bat installed with Vensim now handles most versions of Visual Studio without editing, so it's easy.

File size is strictly proportional to variable count, which tends to be driven mostly by subscript complexity. It's also directly influenced by SAVEPER, so if you can get away with a longer period, you can save a lot of space.

I find VECTOR SELECT gains to be spotty.

One thing that's really expensive is GET DATA functions. These should be wrapped in an Initial() if at all possible.
Post Reply