I am not able to read a relatively complex Vensim model with eight model views.
I tried two ways and neither worked.
Read the model with the default arguments:
model = pysd.read_vensim('C:\Users\...path...\model.mdl')
*** TypeError: cannot unpack non-iterable NoneType object
Read the model with split_views = True
model = pysd.read_vensim('C:\Users\...path...\model.mdl', split_views=True)
*** parsimonious.exceptions.IncompleteParseError: Rule 'line' matched in its entirety, but it didn't consume all the text. The non-matching portion of the text begins with '|14|BU|0-0-128' (line 1, column 71).
In case 2, the text '|14|BU|0-0-128' raising the error is located toward the end of the mdl file (in text view), having to do with the sketch information generated automatically by Vensim. In particular, the line is in a block related to the eighth and last view:
...
10,73,simulator mode,194,665,68,11,8,131,0,18,-1,0,0,0,-1--1--1,0-0-0,|14|BU|0-0-128
12,74,105057302,192,632,80,20,3,60,0,0,0,0,0,0
simulator mode,0,1,1
30,75,f1303_17 - Copy0027.bmp,370,641,79,29,8,3,0,0,-1,0,0,0
12,76,34931712,812,203,221,110,3,188,0,0,1,0,0,0
...
Hello,
I am not able to read a relatively complex Vensim model with eight model views.
I tried two ways and neither worked.
model = pysd.read_vensim('C:\Users\...path...\model.mdl') *** TypeError: cannot unpack non-iterable NoneType object
model = pysd.read_vensim('C:\Users\...path...\model.mdl', split_views=True) *** parsimonious.exceptions.IncompleteParseError: Rule 'line' matched in its entirety, but it didn't consume all the text. The non-matching portion of the text begins with '|14|BU|0-0-128' (line 1, column 71).
In case 2, the text '|14|BU|0-0-128' raising the error is located toward the end of the mdl file (in text view), having to do with the sketch information generated automatically by Vensim. In particular, the line is in a block related to the eighth and last view: ... 10,73,simulator mode,194,665,68,11,8,131,0,18,-1,0,0,0,-1--1--1,0-0-0,|14|BU|0-0-128 12,74,105057302,192,632,80,20,3,60,0,0,0,0,0,0 simulator mode,0,1,1 30,75,f1303_17 - Copy0027.bmp,370,641,79,29,8,3,0,0,-1,0,0,0 12,76,34931712,812,203,221,110,3,188,0,0,1,0,0,0 ...
Thanks for any advice.