You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 3 Next »

Exercise outline

We want to run the FM model and set its time parameters.

Run a FM model (and set its time parameters)


Add the following import statement to the region Import libs:

# .NET lib
from System import TimeSpan

# DeltaShell libs
from DelftTools.Shell.Core.Workflow import ActivityRunner


And add this code to the end of the script :

#region Run model (this takes some time +- 0.5 min)

fmModel.TimeStep = TimeSpan.FromMinutes(1) # time step 1 min
fmModel.StopTime = fmModel.StartTime.AddHours(1) # calculate 1 hour

ActivityRunner.RunActivity(fmModel)

#endregion



  • No labels