You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Kevin Zollman supplied the example System Dynamics Modeler diagram below.
in the GUI, this is read in by JHotDraw, which handles it correctly. but we can't use JHotDraw from org.nlogo.headless, so we rolled our own code in sdm.AggregateManagerLite to read SDM diagrams, and that code fails on this case.
in the generated code, in system-dynamics-go in the GUI we see:
let new-type-1 ( type-1 + local-t1-replicator )
let new-type-2 ( type-2 + local-t2-replicator )
but from headless (adding println(source) to AggregateManagerLite.load and running headless.Main with run --model /Users/tisue/Desktop/PD-replicator.nlogo --experiment experiment) we see:
let new-type-1 ( type-1 + local-t1-replicator )
let new-type-2 ( type-2 )
The text was updated successfully, but these errors were encountered:
This issue can be worked around as follows. In headless, incorrect code is being generated and run. But in the GUI, the generated code is correct. So you can take the correct code from the Code tab in the SDM window, copy it, and paste it into the Code tab in the main window. Then, delete the SDM diagram. The resulting model should work properly both in the GUI and headless.
Kevin Zollman supplied the example System Dynamics Modeler diagram below.
in the GUI, this is read in by JHotDraw, which handles it correctly. but we can't use JHotDraw from org.nlogo.headless, so we rolled our own code in
sdm.AggregateManagerLite
to read SDM diagrams, and that code fails on this case.NetLogo 4.1 has the same issue.
in the generated code, in
system-dynamics-go
in the GUI we see:but from headless (adding
println(source)
toAggregateManagerLite.load
and runningheadless.Main
withrun --model /Users/tisue/Desktop/PD-replicator.nlogo --experiment experiment
) we see:The text was updated successfully, but these errors were encountered: