PyANGKernel.GKGenericScenario

class GKGenericScenario

A base class for scenarios (Static and Dynamic)

Inheritance diagram of PyANGKernel.GKGenericScenario

Inherited by: GKScenario

Synopsis

Methods

Virtual methods

Note

This documentation may contain snippets that were automatically translated from C++ to Python. We always welcome contributions to the snippet translation. If you see an issue with the translation, you can also let us know by creating a ticket on https:/bugreports.qt.io/projects/PYSIDE

__init__()
addExperiment(experiment)
Parameters:

experimentGKGenericExperiment

Adds an experiment to this scenario

addGeometryConfiguration(configuration)
Parameters:

configurationGKGeometryConfiguration

Adds the configuration to this scenario

addStrategy(strategy)
Parameters:

strategyGKStrategy

Adds a strategy to this scenario. Policies are not activated yet (they can be at the experiment)

addTrafficCondition(condition)
Parameters:

conditionGKSimulationEvent

Adds a traffic condition to the scenario.

canRunRemotely()
Return type:

bool

Returns true if this scenario can be executed using a remote executor.

getDBOptions()
Return type:

GKDataBaseInfo

It returns the database information associated with this scenario. If returnProjectDB is true and the DB uses refers to the Project ( useProjectDB ) it will return the project DB ( getProjectDatabase ), if false or it don’t use the Project DB it will return the DB in this scenario.

getDate()
Return type:

QDate

Returns the simulation data. Used to document a scenario. It do not have any effect in the simulation results.

getDemand()
Return type:

GKTrafficDemand

Returns the traffic demand that will be used. If it is NULL no simulation will be possible.

getDuration()
Return type:

GKTimeDuration

getExperiments()
Return type:

GKFolder

Gets all the experiments belonging to this scenario

getGeometryConfigurations()
Return type:

.list of const GKGeometryConfiguration

Returns the geometry configurations used in this scenario

getInitialTime()
Return type:

QTime

getInputPathAssignmentPlan()
Return type:

GKPathAssignmentPlan

Returns the path assignment plan object used as input

getMasterControlPlan()
Return type:

GKMasterControlPlan

Returns the master control plans. It can be NULL (no control plans will be used but an external control plan via Aimsun extensions can still be used).

getProblemNet()
Return type:

GKProblemNet

Is this scenario in a subnetwork?. A scenario can be either a global one (at model level) or inside a subnetwork (but not both).

getPublicLinePlan()
Return type:

GKPublicLinePlan

Returns the transit plans. It can be NULL (no transit)

getRealDataSet()
Return type:

GKRealDataSet

A real data set associated with the scenario and used to validate it.

getStrategiesAndConditions()
Return type:

.list of GKObject

All the strategies and traffic conditions.

getTemperature()
Return type:

float

Get environment Temperature (Celsius degrees). Used by Battery consumption model

getTrafficDemands()
Return type:

GKFolder

helper function: list all the available traffic demand items, either from the project or from the subnetwork

getValueForVariable(variable)
Parameters:

variable – str

Return type:

str

Returns the value of a variable. If the variable is not defined it will return QString().

If the variable is not really a variable then it will be returned as is.

getVariables()
Return type:

Dictionary with keys of type .QString and values of type QString.

Returns all the variables in this scenario and its values.

hasSameGeometryConfigurations(otherSce)
Parameters:

otherSceGKGenericScenario

Return type:

bool

Returns true if this scenario and the one gives as parameter have the same geometry configurations active.

removeAllStrategiesAndConditions()

Removes all the strategies and traffic conditions from this scenario. The objects is not deleted.

removeExperiment(experiment)
Parameters:

experimentGKGenericExperiment

Removes the experiment ‘experiment’ from this scenario

removeGeometryConfiguration(configuration)
Parameters:

configurationGKGeometryConfiguration

Removes the configuration to this scenario

removeStrategy(strategy)
Parameters:

strategyGKStrategy

Removes a strategy from this scenario. The object is not deleted. *

Warning

The specified strategy MUST be one of the scenario’s strategies.

removeTrafficCondition(condition)
Parameters:

conditionGKSimulationEvent

Removes a traffic condition from this scenario. The object is not deleted. *

Warning

The specified traffic condition MUST be one of the scenario’s traffic conditions.

savesAnyData()
Return type:

bool

Returns true if this scenario will save any data after execution. If false running it using a remote executor will produce nothing.

setDBOptions(db)
Parameters:

dbGKDataBaseInfo

It sets the database information associated with this scenario.

setDate(aDate)
Parameters:

aDateQDate

Sets the simulation data. Used to document a scenario. It do not have any effect in the simulation results.

setDemand(ademand)
Parameters:

ademandGKTrafficDemand

Sets the traffic demand that will be used. If is NULL no simulation will be possible.

setGeometryConfigurations(value)
Parameters:

value – .list of const GKGeometryConfiguration

Sets the geometry configurations used in this scenario

setInputPathAssignmentPlan(arg__1)
Parameters:

arg__1GKPathAssignmentPlan

Sets the path assignment plan object used as input

setMasterControlPlan(amasterCP)
Parameters:

amasterCPGKMasterControlPlan

Sets the master control plans. It can be NULL (no control plans will be used but an external control plan via Aimsun extensions can still be used).

setProblemNet(apn)
Parameters:

apnGKProblemNet

Set this scenario in a subnetwork. A scenario can be either a global one (at model level) or inside a subnetwork (but not both).

setPublicLinePlan(aplan)
Parameters:

aplanGKPublicLinePlan

Sets the transit plans. It can be NULL (no transit)

setRealDataSet(dataSet)
Parameters:

dataSetGKRealDataSet

A real data set associated with the scenario and used to validate it.

setTemperature(aTemperature)
Parameters:

aTemperature – float

Set environment Temperature (Celsius degrees). Used by Battery consumption model

setValueForVariable(variable, value)
Parameters:
  • variable – str

  • value – str

Sets the value (second argument) for a variable (first argument) in this scenario.

setVariables(newList)
Parameters:

newList – Dictionary with keys of type .QString and values of type QString.

Sets all the variables in this scenario and its values.

usesGeometryConfiguration(configuration)
Parameters:

configurationGKGeometryConfiguration

Return type:

bool

Returns true if the configuration is used in this scenario

usesStrategyOrCondition(strategyOrCondition)
Parameters:

strategyOrConditionGKObject

Return type:

bool

Returns true if the strategy or traffic condition is used in this scenario.