Commit 82ba9393 authored by Stefan Schuhbaeck's avatar Stefan Schuhbaeck

json v0.4: add fixedSeed and simulationSeed to AttributesSimulation

Changes:

* add new seed handling: By default new scenario files will be created
  with a random seed, which is written in the attribute fixedSeed.
  If the Boolean switch useFixedSeed  is set, this defined seed will
  be used within one simulation. At the start of each simulation this
  seed, or if useFixedSeed is false a newly generated one, will be used
  and persisted in the attribute simulationSeed. All generated data
  of this simulation will be written to the defined output directory
  with a copy of the current scenario file. All data generated in this
  simulation run can be reproduced with specified simulationSeed.

* new features for VaderConsole(migrate): The migrate subcommand will
  now accept a list of files or Directories (or a mix of them) to
  perform a migration or a revert. If a path is specified the
  default behavior will only migrate the selected directory without
  traversing to the directory tree. If the --recursive or -r flag is
  set, the hole sub tree of all given directories will be converted.
  Directories or directory trees will be ignored if the directory
  contains one of the following marker files:
  - DO_NOT_MIGRATE_TREE or .DO_NOT_MIGRATE_TREE
  - DO_NOT_MIGRATE or .DO_NOT_MIGRATE

* remove hard coded sc  enario files encoded as strings to allow
  testResource migration with the VadereConsole

* ignore scenario.legacy files within testResources

* add test for MigrationAssistant v0.3 to v0.4
parent 35205f58
......@@ -3,6 +3,9 @@ target/
*.out
*.preferences.xml
#Tools and build utils
bin/
#IntelliJ
.idea/
*.iml
......@@ -17,9 +20,11 @@ target/
VadereGui/*.png
VadereGui/*.svg
VadereGui/*.mov
VadereGui/testResources/**/*.legacy
VadereUtils/testreports/*.txt
VadereUtils/output/*
VadereSimulator/resources/current_commit_hash.txt
VadereSimulator/testResources/**/*.legacy
#model test output
VadereModelTests/TestOSM/output/*
......@@ -41,7 +46,6 @@ VadereModelTests/TestOVM/processed output/*
VadereUtils/output/*
#deprecated: can potentially be removed
bin/
VadereGui/output/
#mac osx files
......
{
"name" : "Neues_Szenario",
"description" : "",
"release" : "0.3",
"release" : "0.4",
"commithash" : "warning: no commit hash",
"processWriters" : {
"files" : [ {
......@@ -194,6 +194,23 @@
"scenario" : {
"mainModel" : "org.vadere.simulator.models.osm.OptimalStepsModel",
"attributesModel" : {
"org.vadere.state.attributes.models.AttributesFloorField" : {
"createMethod" : "HIGH_ACCURACY_FAST_MARCHING",
"potentialFieldResolution" : 0.1,
"obstacleGridPenalty" : 0.1,
"targetAttractionStrength" : 1.0,
"timeCostAttributes" : {
"standardDeviation" : 0.7,
"type" : "UNIT",
"obstacleDensityWeight" : 3.5,
"pedestrianSameTargetDensityWeight" : 3.5,
"pedestrianOtherTargetDensityWeight" : 3.5,
"pedestrianWeight" : 3.5,
"queueWidthLoading" : 1.0,
"pedestrianDynamicWeight" : 6.0,
"loadingType" : "CONSTANT"
}
},
"org.vadere.state.attributes.models.AttributesOSM" : {
"stepCircleResolution" : 18,
"numberOfCircles" : 1,
......@@ -221,23 +238,6 @@
"useHardBodyShell" : false,
"obstDistanceDeviation" : 0.0,
"visionFieldRadius" : 5.0
},
"org.vadere.state.attributes.models.AttributesFloorField" : {
"createMethod" : "HIGH_ACCURACY_FAST_MARCHING",
"potentialFieldResolution" : 0.1,
"obstacleGridPenalty" : 0.1,
"targetAttractionStrength" : 1.0,
"timeCostAttributes" : {
"standardDeviation" : 0.7,
"type" : "UNIT",
"obstacleDensityWeight" : 3.5,
"pedestrianSameTargetDensityWeight" : 3.5,
"pedestrianOtherTargetDensityWeight" : 3.5,
"pedestrianWeight" : 3.5,
"queueWidthLoading" : 1.0,
"pedestrianDynamicWeight" : 6.0,
"loadingType" : "CONSTANT"
}
}
},
"attributesSimulation" : {
......@@ -249,8 +249,9 @@
"printFPS" : false,
"needsBoundary" : false,
"digitsPerCoordinate" : 2,
"useRandomSeed" : true,
"randomSeed" : 1
"useFixedSeed" : true,
"fixedSeed" : 1,
"simulationSeed" : null
},
"topography" : {
"attributes" : {
......@@ -338,8 +339,8 @@
"maximumSpeed" : 3.0,
"acceleration" : 2.0
},
"attributesCar" : null,
"dynamicElements" : [ ]
"dynamicElements" : [ ],
"attributesCar" : null
}
}
}
\ No newline at end of file
{
"name" : "basic_5_1_roadReachTarget_ovm1",
"description" : "",
"release" : "0.3",
"release" : "0.4",
"commithash" : "warning: no commit hash",
"processWriters" : {
"files" : [ ],
"processors" : [ ],
......@@ -53,8 +54,9 @@
"printFPS" : false,
"needsBoundary" : false,
"digitsPerCoordinate" : 2,
"useRandomSeed" : true,
"randomSeed" : 1
"useFixedSeed" : true,
"fixedSeed" : 1,
"simulationSeed" : null
},
"topography" : {
"attributes" : {
......@@ -108,7 +110,6 @@
"groupSizeDistribution" : [ 1.0 ],
"dynamicElementType" : "CAR"
} ],
"dynamicElements" : [ ],
"attributesPedestrian" : {
"radius" : 0.195,
"densityDependentSpeed" : false,
......@@ -133,7 +134,8 @@
"x" : 1.0,
"y" : 0.0
}
}
},
"dynamicElements" : [ ]
}
}
}
\ No newline at end of file
{
"name" : "basic_5_2_roadReachTarget_ovm1",
"description" : "",
"release" : "0.3",
"release" : "0.4",
"commithash" : "warning: no commit hash",
"processWriters" : {
"files" : [ ],
"processors" : [ ],
......@@ -53,8 +54,9 @@
"printFPS" : false,
"needsBoundary" : false,
"digitsPerCoordinate" : 2,
"useRandomSeed" : true,
"randomSeed" : 1
"useFixedSeed" : true,
"fixedSeed" : 1,
"simulationSeed" : null
},
"topography" : {
"attributes" : {
......@@ -125,7 +127,6 @@
"groupSizeDistribution" : [ 1.0 ],
"dynamicElementType" : "CAR"
} ],
"dynamicElements" : [ ],
"attributesPedestrian" : {
"radius" : 0.195,
"densityDependentSpeed" : false,
......@@ -150,7 +151,8 @@
"x" : 1.0,
"y" : 0.0
}
}
},
"dynamicElements" : [ ]
}
}
}
\ No newline at end of file
{
"name" : "testtrafficlight",
"description" : "",
"release" : "0.3",
"release" : "0.4",
"commithash" : "warning: no commit hash",
"processWriters" : {
"files" : [ ],
"processors" : [ ],
......@@ -10,6 +11,23 @@
"scenario" : {
"mainModel" : "org.vadere.simulator.models.osm.OptimalStepsModel",
"attributesModel" : {
"org.vadere.state.attributes.models.AttributesFloorField" : {
"createMethod" : "HIGH_ACCURACY_FAST_MARCHING",
"potentialFieldResolution" : 0.1,
"obstacleGridPenalty" : 0.1,
"targetAttractionStrength" : 1.0,
"timeCostAttributes" : {
"standardDeviation" : 0.7,
"type" : "UNIT",
"obstacleDensityWeight" : 3.5,
"pedestrianSameTargetDensityWeight" : 3.5,
"pedestrianOtherTargetDensityWeight" : 3.5,
"pedestrianWeight" : 3.5,
"queueWidthLoading" : 1.0,
"pedestrianDynamicWeight" : 6.0,
"loadingType" : "CONSTANT"
}
},
"org.vadere.state.attributes.models.AttributesOSM" : {
"stepCircleResolution" : 18,
"numberOfCircles" : 1,
......@@ -37,23 +55,6 @@
"useHardBodyShell" : false,
"obstDistanceDeviation" : 0.0,
"visionFieldRadius" : 5.0
},
"org.vadere.state.attributes.models.AttributesFloorField" : {
"createMethod" : "HIGH_ACCURACY_FAST_MARCHING",
"potentialFieldResolution" : 0.1,
"obstacleGridPenalty" : 0.1,
"targetAttractionStrength" : 1.0,
"timeCostAttributes" : {
"standardDeviation" : 0.7,
"type" : "UNIT",
"obstacleDensityWeight" : 3.5,
"pedestrianSameTargetDensityWeight" : 3.5,
"pedestrianOtherTargetDensityWeight" : 3.5,
"pedestrianWeight" : 3.5,
"queueWidthLoading" : 1.0,
"pedestrianDynamicWeight" : 6.0,
"loadingType" : "CONSTANT"
}
}
},
"attributesSimulation" : {
......@@ -65,8 +66,9 @@
"printFPS" : false,
"needsBoundary" : false,
"digitsPerCoordinate" : 2,
"useRandomSeed" : true,
"randomSeed" : 1
"useFixedSeed" : true,
"fixedSeed" : 1,
"simulationSeed" : null
},
"topography" : {
"attributes" : {
......@@ -137,7 +139,6 @@
"groupSizeDistribution" : [ 1.0 ],
"dynamicElementType" : "PEDESTRIAN"
} ],
"dynamicElements" : [ ],
"attributesPedestrian" : {
"radius" : 0.195,
"densityDependentSpeed" : false,
......@@ -162,7 +163,8 @@
"x" : 1.0,
"y" : 0.0
}
}
},
"dynamicElements" : [ ]
}
}
}
\ No newline at end of file
{
"name" : "basic_1_chicken_gnm1",
"description" : "",
"release" : "0.3",
"release" : "0.4",
"commithash" : "warning: no commit hash",
"processWriters" : {
"files" : [ ],
"processors" : [ ],
......@@ -10,19 +11,6 @@
"scenario" : {
"mainModel" : "org.vadere.simulator.models.gnm.GradientNavigationModel",
"attributesModel" : {
"org.vadere.state.attributes.models.AttributesGNM" : {
"attributesODEIntegrator" : {
"solverType" : "DORMAND_PRINCE_45",
"stepSizeMin" : 1.0E-4,
"stepSizeMax" : 1.0,
"toleranceAbsolute" : 1.0E-5,
"toleranceRelative" : 1.0E-4
},
"floorGradientProviderType" : "FLOOR_EIKONAL_DISCRETE",
"targetPotentialModel" : "org.vadere.simulator.models.potential.fields.PotentialFieldTargetGrid",
"pedestrianPotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldPedestrianGNM",
"obstaclePotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldObstacleGNM"
},
"org.vadere.state.attributes.models.AttributesFloorField" : {
"createMethod" : "HIGH_ACCURACY_FAST_MARCHING",
"potentialFieldResolution" : 0.1,
......@@ -40,6 +28,19 @@
"loadingType" : "CONSTANT"
}
},
"org.vadere.state.attributes.models.AttributesGNM" : {
"attributesODEIntegrator" : {
"solverType" : "DORMAND_PRINCE_45",
"stepSizeMin" : 1.0E-4,
"stepSizeMax" : 1.0,
"toleranceAbsolute" : 1.0E-5,
"toleranceRelative" : 1.0E-4
},
"floorGradientProviderType" : "FLOOR_EIKONAL_DISCRETE",
"targetPotentialModel" : "org.vadere.simulator.models.potential.fields.PotentialFieldTargetGrid",
"pedestrianPotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldPedestrianGNM",
"obstaclePotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldObstacleGNM"
},
"org.vadere.state.attributes.models.AttributesPotentialGNM" : {
"pedestrianBodyPotential" : 3.59,
"pedestrianRecognitionDistance" : 0.7,
......@@ -56,8 +57,9 @@
"printFPS" : false,
"needsBoundary" : false,
"digitsPerCoordinate" : 2,
"useRandomSeed" : true,
"randomSeed" : 1
"useFixedSeed" : true,
"fixedSeed" : 1,
"simulationSeed" : null
},
"topography" : {
"attributes" : {
......@@ -138,7 +140,6 @@
"groupSizeDistribution" : [ 1.0 ],
"dynamicElementType" : "PEDESTRIAN"
} ],
"dynamicElements" : [ ],
"attributesPedestrian" : {
"radius" : 0.195,
"densityDependentSpeed" : false,
......@@ -148,7 +149,8 @@
"maximumSpeed" : 2.2,
"acceleration" : 2.0
},
"attributesCar" : null
"attributesCar" : null,
"dynamicElements" : [ ]
}
}
}
\ No newline at end of file
{
"name" : "basic_1_chicken_gnm2",
"description" : "",
"release" : "0.3",
"release" : "0.4",
"commithash" : "warning: no commit hash",
"processWriters" : {
"files" : [ ],
"processors" : [ ],
......@@ -10,19 +11,6 @@
"scenario" : {
"mainModel" : "org.vadere.simulator.models.gnm.GradientNavigationModel",
"attributesModel" : {
"org.vadere.state.attributes.models.AttributesGNM" : {
"attributesODEIntegrator" : {
"solverType" : "DORMAND_PRINCE_45",
"stepSizeMin" : 1.0E-4,
"stepSizeMax" : 1.0,
"toleranceAbsolute" : 1.0E-5,
"toleranceRelative" : 1.0E-4
},
"floorGradientProviderType" : "FLOOR_EUCLIDEAN_CONTINUOUS",
"targetPotentialModel" : "org.vadere.simulator.models.potential.fields.PotentialFieldTargetGrid",
"pedestrianPotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldPedestrianGNM",
"obstaclePotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldObstacleGNM"
},
"org.vadere.state.attributes.models.AttributesFloorField" : {
"createMethod" : "NONE",
"potentialFieldResolution" : 0.1,
......@@ -40,6 +28,19 @@
"loadingType" : "CONSTANT"
}
},
"org.vadere.state.attributes.models.AttributesGNM" : {
"attributesODEIntegrator" : {
"solverType" : "DORMAND_PRINCE_45",
"stepSizeMin" : 1.0E-4,
"stepSizeMax" : 1.0,
"toleranceAbsolute" : 1.0E-5,
"toleranceRelative" : 1.0E-4
},
"floorGradientProviderType" : "FLOOR_EUCLIDEAN_CONTINUOUS",
"targetPotentialModel" : "org.vadere.simulator.models.potential.fields.PotentialFieldTargetGrid",
"pedestrianPotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldPedestrianGNM",
"obstaclePotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldObstacleGNM"
},
"org.vadere.state.attributes.models.AttributesPotentialGNM" : {
"pedestrianBodyPotential" : 3.59,
"pedestrianRecognitionDistance" : 0.7,
......@@ -56,8 +57,9 @@
"printFPS" : false,
"needsBoundary" : false,
"digitsPerCoordinate" : 2,
"useRandomSeed" : true,
"randomSeed" : 1
"useFixedSeed" : true,
"fixedSeed" : 1,
"simulationSeed" : null
},
"topography" : {
"attributes" : {
......@@ -138,7 +140,6 @@
"groupSizeDistribution" : [ 1.0 ],
"dynamicElementType" : "PEDESTRIAN"
} ],
"dynamicElements" : [ ],
"attributesPedestrian" : {
"radius" : 0.195,
"densityDependentSpeed" : false,
......@@ -148,7 +149,8 @@
"maximumSpeed" : 2.2,
"acceleration" : 2.0
},
"attributesCar" : null
"attributesCar" : null,
"dynamicElements" : [ ]
}
}
}
\ No newline at end of file
{
"name" : "basic_2_density_gnm1",
"description" : "",
"release" : "0.3",
"release" : "0.4",
"commithash" : "warning: no commit hash",
"processWriters" : {
"files" : [ ],
"processors" : [ ],
......@@ -10,19 +11,6 @@
"scenario" : {
"mainModel" : "org.vadere.simulator.models.gnm.GradientNavigationModel",
"attributesModel" : {
"org.vadere.state.attributes.models.AttributesGNM" : {
"attributesODEIntegrator" : {
"solverType" : "DORMAND_PRINCE_45",
"stepSizeMin" : 1.0E-4,
"stepSizeMax" : 1.0,
"toleranceAbsolute" : 1.0E-5,
"toleranceRelative" : 1.0E-4
},
"floorGradientProviderType" : "FLOOR_EIKONAL_DISCRETE",
"targetPotentialModel" : "org.vadere.simulator.models.potential.fields.PotentialFieldTargetGrid",
"pedestrianPotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldPedestrianGNM",
"obstaclePotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldObstacleGNM"
},
"org.vadere.state.attributes.models.AttributesFloorField" : {
"createMethod" : "HIGH_ACCURACY_FAST_MARCHING",
"potentialFieldResolution" : 0.1,
......@@ -40,6 +28,19 @@
"loadingType" : "CONSTANT"
}
},
"org.vadere.state.attributes.models.AttributesGNM" : {
"attributesODEIntegrator" : {
"solverType" : "DORMAND_PRINCE_45",
"stepSizeMin" : 1.0E-4,
"stepSizeMax" : 1.0,
"toleranceAbsolute" : 1.0E-5,
"toleranceRelative" : 1.0E-4
},
"floorGradientProviderType" : "FLOOR_EIKONAL_DISCRETE",
"targetPotentialModel" : "org.vadere.simulator.models.potential.fields.PotentialFieldTargetGrid",
"pedestrianPotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldPedestrianGNM",
"obstaclePotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldObstacleGNM"
},
"org.vadere.state.attributes.models.AttributesPotentialGNM" : {
"pedestrianBodyPotential" : 3.59,
"pedestrianRecognitionDistance" : 0.7,
......@@ -56,8 +57,9 @@
"printFPS" : false,
"needsBoundary" : false,
"digitsPerCoordinate" : 2,
"useRandomSeed" : true,
"randomSeed" : 1
"useFixedSeed" : true,
"fixedSeed" : 1,
"simulationSeed" : null
},
"topography" : {
"attributes" : {
......@@ -147,7 +149,6 @@
"groupSizeDistribution" : [ 1.0 ],
"dynamicElementType" : "PEDESTRIAN"
} ],
"dynamicElements" : [ ],
"attributesPedestrian" : {
"radius" : 0.195,
"densityDependentSpeed" : false,
......@@ -157,7 +158,8 @@
"maximumSpeed" : 2.2,
"acceleration" : 2.0
},
"attributesCar" : null
"attributesCar" : null,
"dynamicElements" : [ ]
}
}
}
\ No newline at end of file
{
"name" : "basic_3_1_wall_gnm1",
"description" : "",
"release" : "0.3",
"release" : "0.4",
"commithash" : "warning: no commit hash",
"processWriters" : {
"files" : [ ],
"processors" : [ ],
......@@ -10,19 +11,6 @@
"scenario" : {
"mainModel" : "org.vadere.simulator.models.gnm.GradientNavigationModel",
"attributesModel" : {
"org.vadere.state.attributes.models.AttributesGNM" : {
"attributesODEIntegrator" : {
"solverType" : "DORMAND_PRINCE_45",
"stepSizeMin" : 1.0E-4,
"stepSizeMax" : 1.0,
"toleranceAbsolute" : 1.0E-5,
"toleranceRelative" : 1.0E-4
},
"floorGradientProviderType" : "FLOOR_EUCLIDEAN_CONTINUOUS",
"targetPotentialModel" : "org.vadere.simulator.models.potential.fields.PotentialFieldTargetGrid",
"pedestrianPotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldPedestrianGNM",
"obstaclePotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldObstacleGNM"
},
"org.vadere.state.attributes.models.AttributesFloorField" : {
"createMethod" : "NONE",
"potentialFieldResolution" : 0.1,
......@@ -40,6 +28,19 @@
"loadingType" : "CONSTANT"
}
},
"org.vadere.state.attributes.models.AttributesGNM" : {
"attributesODEIntegrator" : {
"solverType" : "DORMAND_PRINCE_45",
"stepSizeMin" : 1.0E-4,
"stepSizeMax" : 1.0,
"toleranceAbsolute" : 1.0E-5,
"toleranceRelative" : 1.0E-4
},
"floorGradientProviderType" : "FLOOR_EUCLIDEAN_CONTINUOUS",
"targetPotentialModel" : "org.vadere.simulator.models.potential.fields.PotentialFieldTargetGrid",
"pedestrianPotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldPedestrianGNM",
"obstaclePotentialModel" : "org.vadere.simulator.models.gnm.PotentialFieldObstacleGNM"
},
"org.vadere.state.attributes.models.AttributesPotentialGNM" : {
"pedestrianBodyPotential" : 3.59,
"pedestrianRecognitionDistance" : 0.7,
......@@ -56,8 +57,9 @@
"printFPS" : false,
"needsBoundary" : false,
"digitsPerCoordinate" : 2,
"useRandomSeed" : true,
"randomSeed" : 1
"useFixedSeed" : true,
"fixedSeed" : 1,
"simulationSeed" : null
},
"topography" : {
"attributes" : {
......@@ -120,7 +122,6 @@
"groupSizeDistribution" : [ 1.0 ],
"dynamicElementType" : "PEDESTRIAN"
} ],
"dynamicElements" : [ ],
"attributesPedestrian" : {
"radius" : 0.195,
"densityDependentSpeed" : false,
......@@ -130,7 +131,8 @@
"maximumSpeed" : 2.2,
"acceleration" : 2.0
},
"attributesCar" : null
"attributesCar" : null,
"dynamicElements" : [ ]
}
}
}
\ No newline at end of file