find var number for user model
Is there any way to use python to find the starting var number for a user-written model? It seems like you should be able to provide the name of the user model and get PSSE to tell you where the vars are for that model.

Comments
Hi Adam I saw some ways to get info on built in models: https://psspy.org/psse-help-forum/question/656/accessing-model-index-values-eg-var-nums-from-python/, but not for user-written ones. What is your method for accessing through the user interface right now?
Currently, we place the user models at the beginning of the dyre file in a certain order so that we can just count the var locations and know where they are stored. This practice dates back a long ways and I'm looking for a more flexible way to find these var locations so that we don't have to ...
... worry about the dyre order anymore. I just thought of one way to do it: we could have a python script look through the vars and find unique sets of consecutive var values that would correspond to certain models. These models don't changes very often so this might actually be a workable fix.
Are you able to post some pseudo-code showing how you might go about it?