Commit 55e6810d authored by Benedikt Kleinmeier's avatar Benedikt Kleinmeier
Browse files

Moved "Development Setup" from "README.md" to "CONTRIBUTING.md" so that "README.md" is conciser.

CHANGELOG.md:
- Added the section "# Changelog: Vadere" and corrected indention level of following sections.
- Also adapted the correspoding guide "Writing Changelog Entries.md".
parent a1f3607a
Pipeline #77618 failed with stages
in 102 minutes and 23 seconds
# Changelog: Vadere
**Note:** Before writing into this file, read the guidelines in [Writing Changelog Entries.md](Documentation/contributing/Writing Changelog Entries.md). **Note:** Before writing into this file, read the guidelines in [Writing Changelog Entries.md](Documentation/contributing/Writing Changelog Entries.md).
# In Progress: v0.7 ## In Progress: v0.7
## Added ### Added
- `VadereConsole`: Add option `--logname <filename>` to specify the name for the log file. - `VadereConsole`: Add option `--logname <filename>` to specify the name for the log file.
Please note that the log file `log.out` is always written (because this file is configured Please note that the log file `log.out` is always written (because this file is configured
...@@ -24,9 +26,9 @@ ...@@ -24,9 +26,9 @@
sub-command. This will will turn the ScenarioChecker on or off for the command sub-command. This will will turn the ScenarioChecker on or off for the command
line. If the Checker detects an error the simulation will not be executed. line. If the Checker detects an error the simulation will not be executed.
# v0.6 (2018-09-07) ## v0.6 (2018-09-07)
## Added ### Added
- Graphical simulation result is displayed in a table view to show run-time and overlap information if the corresponding processors are loaded. The Simulation result dialog can be deactivated in the preferences. (5ffca5a3: Simulator, GUI) - Graphical simulation result is displayed in a table view to show run-time and overlap information if the corresponding processors are loaded. The Simulation result dialog can be deactivated in the preferences. (5ffca5a3: Simulator, GUI)
- Added new OutputProcessors for Overlaps. (8028c523: Simulator) - Added new OutputProcessors for Overlaps. (8028c523: Simulator)
...@@ -39,7 +41,7 @@ ...@@ -39,7 +41,7 @@
- Added sub commands to "VadereConsole": project-run, scenario-run, suq, migrate (c7e0538c: GUI) - Added sub commands to "VadereConsole": project-run, scenario-run, suq, migrate (c7e0538c: GUI)
- In the onlinevisualization it is now possible to display the target potential field of a selected pedestrian. (123457aa: GUI) - In the onlinevisualization it is now possible to display the target potential field of a selected pedestrian. (123457aa: GUI)
## Changed ### Changed
- PedestrianOverlapProcessor returns two values "distance", "overlaps"for each overlap detected. (5ffca5a3: Simulator) - PedestrianOverlapProcessor returns two values "distance", "overlaps"for each overlap detected. (5ffca5a3: Simulator)
* If no overlap occurs the output is empty. * If no overlap occurs the output is empty.
...@@ -49,21 +51,21 @@ ...@@ -49,21 +51,21 @@
* Move /scenario/attributesModel/org.vadere.state.attributes.models.AttributesCGM/groupSizeDistribution to each source in /scenario/topography/sources/[]/groupSizeDistribution. This allows different group size distribution for each source * Move /scenario/attributesModel/org.vadere.state.attributes.models.AttributesCGM/groupSizeDistribution to each source in /scenario/topography/sources/[]/groupSizeDistribution. This allows different group size distribution for each source
* Rename /scenario/attributesModel/*/timeCostAttributes/standardDerivation to standardDeviation. * Rename /scenario/attributesModel/*/timeCostAttributes/standardDerivation to standardDeviation.
## Performance ### Performance
- Faster distance computation. (6214738c: Simulator) - Faster distance computation. (6214738c: Simulator)
* To compute the distance from a point x the closest obstacle we compute the distances on a Cartesian grid of cell size equal to the default value of AttributesFloorField.potentialFieldResolution. There are two methods to compute the distances. * To compute the distance from a point x the closest obstacle we compute the distances on a Cartesian grid of cell size equal to the default value of AttributesFloorField.potentialFieldResolution. There are two methods to compute the distances.
* Brute force (default): Compute the distance for a grid point x by computing all distances (for all obstacles) taking the minimal * Brute force (default): Compute the distance for a grid point x by computing all distances (for all obstacles) taking the minimal
* Eikonal Equation solvers (unused): Use obstacles to be the targets are of the eikonal equation and solve the equation using one of the solvers (default is the Fast Marching Method). * Eikonal Equation solvers (unused): Use obstacles to be the targets are of the eikonal equation and solve the equation using one of the solvers (default is the Fast Marching Method).
# v0.2 (2016-12-22) ## v0.2 (2016-12-22)
## Added ### Added
- Stability and usability improved, additional pedestrian simulation models are supported. (babf0b67: GUI, Simulator, State, Utils) - Stability and usability improved, additional pedestrian simulation models are supported. (babf0b67: GUI, Simulator, State, Utils)
# v0.1 (2016-08-05) ## v0.1 (2016-08-05)
## Added ### Added
- Initial release of the software as open source. (72391fab: GUI, Simulator, State, Utils) - Initial release of the software as open source. (72391fab: GUI, Simulator, State, Utils)
Contribution guidelines # Contributing: Vadere
=======================
Workflow This guide explains the repository structure, how to set up the development environment and introduces coding guidelines.
--------
## Repository Structure
The repository contains following `folders`:
- The Vadere source code: divided into the sofware modules `VadereGui`, `VadereMeshing`, `VaderSimulator`, `VadereState`, `VadereUtils`
- `VadereModelTests`: pre-shipped tests for different locomotion models (e.g., gradient navigation model, optimal steps model, social force model)
- `Tools`: scripts which are executing during the continuous integration phase.
- `.gitlab`: templates for creating issues in the Vadere [issue tracker](https://gitlab.lrz.de/vadere/vadere/issues) (this files are implicitly used by GitLab).
- `.gitlab-ci.yml`: instructions which are executed during the [continuous integration pipeline](https://docs.gitlab.com/ee/ci/quick_start/).
## Development Setup
1. Follow the **installation instructions** in the [README.md](README.md) to install all required software and to get the source code.
2. Open a shell and `cd` into the project directory.
3. Run `mvn clean install`.
The project can now be imported *As Maven Project* into your IDE.
### Eclipse
1. *File* > *Import* > *Maven* > *Existing Maven Projects*
2. Choose `pom.xml` as *Root Directory* and click *Finish*
3. Open *Vaderegui (gui)* > *src* > *org.vadere.gui.projectview* > `Vadereapplication`
### IntelliJ IDEA
1. On the welcome-screen select *Import Project*
2. Select `pom.xml` > *Next* > *Next* > *Next* > *Finish*
3. Open *VadereGui (gui)* > *src* > *org.vadere.gui.projectview* > `VadereApplication`
4. lick the *run*-icon next to the `main` method
5. Edit the run configuration for `VadereApplication` to build the project using Maven instead of IntelliJ's internal builder to avoid compilation errors:
6. Click *Edit Configurations* (in dropdown menu next to the play/debug button)
7. Under *Before launch*, add *Run Maven Goal* and use the Maven goal `compile`
Alternatively, run `mvn eclipse:eclipse` using the [Maven Eclipse Plugin](http://maven.apache.org/plugins/maven-eclipse-plugin/usage.html) or `mvn idea:idea` using the [Maven IntelliJ Plugin](http://maven.apache.org/plugins/maven-idea-plugin/).
## Workflow
To efficiently contribute to this project, you need an LRZ GitLab account. To efficiently contribute to this project, you need an LRZ GitLab account.
Please contact us and we will send you an invitation. Please contact us and we will send you an invitation.
The workflow then is the following.
1. **Fork this Git repository** ### Use the Issue Tracker
2. Clone your own fork to your computer
3. Checkout a new branch and work on your new feature or bugfix Please, use the [issue tracker](https://gitlab.lrz.de/vadere/vadere/issues) for both
4. Push your branch and **send us a merge request**
- to request a feature or to report a bug (see [how to write new issues](https://gitlab.lrz.de/vadere/vadere/issues/179))
- to work on a feature (see [how to work on an issue]())
### Steps for External Contributors
The workflow is the following:
1. **Fork this Git repository**
2. Clone your own fork to your computer
3. Checkout a new branch and work on your new feature or bugfix
4. Push your branch and **send us a merge request**
These steps are explained in more detail at the These steps are explained in more detail at the
[GitHub help pages](https://help.github.com/articles/fork-a-repo/). [GitHub help pages](https://help.github.com/articles/fork-a-repo/).
Merge/pull requests are described [on GitLab](https://about.gitlab.com/2014/09/29/gitlab-flow/#mergepull-requests-with-gitlab-flow). Merge/pull requests are described [on GitLab](https://about.gitlab.com/2014/09/29/gitlab-flow/#mergepull-requests-with-gitlab-flow).
Coding style guide ## Style Guides
------------------
### For Coding
Basic rules: Basic rules:
- No warnings - No warnings
- No unused imports - No unused imports
- No unecessary `this.` qualifiers - No unecessary `this.` qualifiers
- Use the formatting tool! - Use the formatting tool!
- Eclipse: select text (optional) and press <kbd>ctrl</kbd> + <kbd>shift</kbd> + <kbd>f</kbd> - Eclipse: select text (optional) and press <kbd>ctrl</kbd> + <kbd>shift</kbd> + <kbd>f</kbd>
- IntelliJ: select text (optional) and <kbd>ctrl</kbd> + <kbd>alt</kbd> + <kbd>l</kbd> - IntelliJ: select text (optional) and <kbd>ctrl</kbd> + <kbd>alt</kbd> + <kbd>l</kbd>
For source code formatting, we use an adapted version of For source code formatting, we use an adapted version of
[Google's Coding style guide](https://google.github.io/styleguide/javaguide.html). [Google's Coding style guide](https://google.github.io/styleguide/javaguide.html).
Please check the [README in this repository](https://gitlab.lrz.de/vadere/styleguide) Please check the [README in this repository](https://gitlab.lrz.de/vadere/styleguide)
for the style guide and for how to import the style settings into your IDE. for the style guide and for how to import the style settings into your IDE.
Commit style guide ### For Commit Messages
------------------
These are examples for a good commit messages: These are examples for a good commit messages:
...@@ -52,13 +98,13 @@ used in multiple places. ...@@ -52,13 +98,13 @@ used in multiple places.
Rules: Rules:
1. Separate subject from body with a blank line 1. Separate subject from body with a blank line
2. Limit the subject line to 50 characters 2. Limit the subject line to 50 characters
3. Capitalize the subject line 3. Capitalize the subject line
4. Do not end the subject line with a period 4. Do not end the subject line with a period
5. Use the imperative mood in the subject line 5. Use the imperative mood in the subject line
6. Wrap the body at 72 characters 6. Wrap the body at 72 characters
7. Use the body to explain what and why vs. how 7. Use the body to explain what and why vs. how
Source: http://chris.beams.io/posts/git-commit/ Source: http://chris.beams.io/posts/git-commit/
...@@ -70,10 +116,9 @@ Reasons include: ...@@ -70,10 +116,9 @@ Reasons include:
Rules 1, 3, and 4 never hurt and should always be applied. Rules 1, 3, and 4 never hurt and should always be applied.
Miscellaneous ### Miscellaneous
-------------
### Author tag in JavaDoc #### Author Tag in JavaDoc
If you make important contributions to a Java class, and especially if you feel If you make important contributions to a Java class, and especially if you feel
responsible for that class, please add yourself as an author to the class-level responsible for that class, please add yourself as an author to the class-level
...@@ -90,8 +135,14 @@ public class Foo { ...@@ -90,8 +135,14 @@ public class Foo {
... ...
``` ```
### Tests required #### Tests Required
Especially if you implement new functionality, please also provide JUnit tests. Especially if you implement new functionality, please also provide JUnit tests.
The test classes should be located in the `tests/` folder but in the same The test classes should be located in the `tests/` folder but in the same
package as the class under test. package as the class under test.
## Contributors
People who have contributed code to the project at the Munich University of Applied Sciences (in alphabetical order):
Florian Albrecht, Benjamin Degenhart, Felix Dietrich, Marion Gödel, Benedikt Kleinmeier, Daniel Lehmberg, Jakob Schöttl, Stefan Schuhbäck, Michael Seitz, Swen Stemmer, Isabella von Sivers, Mario Teixeira Parente, Peter Zarnitz, Benedikt Zönnchen
{
"name" : "OSM",
"description" : "",
"release" : "0.1",
"topographyhash" : "c963def1f0d4d3384fc5aa0486bbc1e69ef2dd39",
"attributeshash" : "58bf2959425a3dbf54b9c531df95eedff3b02b8d",
"processWriters" : [ ],
"vadere" : {
"mainModel" : "org.vadere.simulator.models.osm.OptimalStepsModel",
"attributesModel" : {
"org.vadere.state.attributes.models.AttributesOSM" : {
"stepCircleResolution" : 18,
"numberOfCircles" : 1,
"varyStepDirection" : false,
"stepLengthIntercept" : 0.4625,
"stepLengthSlopeSpeed" : 0.2345,
"stepLengthSD" : 0.036,
"movementThreshold" : 0.0,
"optimizationType" : "DISCRETE",
"movementType" : "ARBITRARY",
"dynamicStepLength" : false,
"updateType" : "EVENT_DRIVEN",
"seeSmallWalls" : false,
"minimumStepLength" : false,
"targetPotentialModel" : "org.vadere.simulator.models.potential.fields.PotentialFieldTargetGrid",
"pedestrianPotentialModel" : "org.vadere.simulator.models.potential.PotentialFieldPedestrianCompact",
"obstaclePotentialModel" : "org.vadere.simulator.models.potential.PotentialFieldObstacleCompact",
"submodels" : [ ]
},
"org.vadere.state.attributes.models.AttributesPotentialCompact" : {
"pedPotentialWidth" : 0.5,
"pedPotentialHeight" : 12.6,
"obstPotentialWidth" : 0.25,
"obstPotentialHeight" : 20.1,
"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" : {
"standardDerivation" : 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" : {
"finishTime" : 200.0,
"simTimeStepLength" : 0.4,
"realTimeSimTimeRatio" : 0.1,
"writeSimulationData" : true,
"visualizationEnabled" : true,
"printFPS" : false,
"needsBoundary" : false,
"digitsPerCoordinate" : 2,
"useRandomSeed" : true,
"randomSeed" : 1
},
"topography" : {
"attributes" : {
"bounds" : {
"x" : 0.0,
"y" : 0.0,
"width" : 30.0,
"height" : 30.0
},
"boundingBoxWidth" : 0.5,
"bounded" : true
},
"obstacles" : [ {
"shape" : {
"x" : 0.5,
"y" : 26.0,
"width" : 23.5,
"height" : 1.0,
"type" : "RECTANGLE"
},
"id" : -1
}, {
"shape" : {
"x" : 25.0,
"y" : 26.0,
"width" : 4.5,
"height" : 1.0,
"type" : "RECTANGLE"
},
"id" : -1
}, {
"shape" : {
"x" : 16.0,
"y" : 24.0,
"width" : 13.5,
"height" : 1.0,
"type" : "RECTANGLE"
},
"id" : -1
}, {
"shape" : {
"x" : 0.5,
"y" : 24.0,
"width" : 14.5,
"height" : 1.0,
"type" : "RECTANGLE"
},
"id" : -1
}, {
"shape" : {
"x" : 0.5,
"y" : 22.0,
"width" : 9.5,
"height" : 1.0,
"type" : "RECTANGLE"
},
"id" : -1
}, {
"shape" : {
"x" : 11.0,
"y" : 22.0,
"width" : 10.0,
"height" : 1.0,
"type" : "RECTANGLE"
},
"id" : -1
}, {
"shape" : {
"x" : 22.0,
"y" : 22.0,
"width" : 7.5,
"height" : 1.0,
"type" : "RECTANGLE"
},
"id" : -1
}, {
"shape" : {
"x" : 0.5,
"y" : 20.0,
"width" : 25.5,
"height" : 1.0,
"type" : "RECTANGLE"
},
"id" : -1
}, {
"shape" : {
"x" : 27.0,
"y" : 20.0,
"width" : 2.5,
"height" : 1.0,
"type" : "RECTANGLE"
},
"id" : -1
}, {
"shape" : {
"x" : 0.5,
"y" : 18.0,
"width" : 0.5,
"height" : 1.0,
"type" : "RECTANGLE"
},
"id" : -1
}, {
"shape" : {
"x" : 2.0,
"y" : 18.0,
"width" : 27.6,
"height" : 1.0,
"type" : "RECTANGLE"
},
"id" : -1
}, {
"shape" : {
"x" : 0.5,
"y" : 16.0,
"width" : 26.5,
"height" : 1.0,
"type" : "RECTANGLE"
},
"id" : -1
}, {
"shape" : {
"x" : 28.0,
"y" : 16.0,
"width" : 1.5,
"height" : 1.0,
"type" : "RECTANGLE"
},
"id" : -1
}, {
"shape" : {
"type" : "POLYGON",
"points" : [ {
"x" : 24.0,
"y" : 12.9
}, {
"x" : 21.3,
"y" : 16.0
}, {
"x" : 24.0,
"y" : 16.0
}, {
"x" : 28.0,
"y" : 14.0
}, {
"x" : 28.0,
"y" : 13.0
} ]
},
"id" : -1
} ],
"stairs" : [ ],
"targets" : [ {
"id" : 2,
"absorbing" : true,
"shape" : {
"x" : 2.0,
"y" : 2.1,
"width" : 26.0,
"height" : 9.9,
"type" : "RECTANGLE"
},
"waitingTime" : 0.0,
"waitingTimeYellowPhase" : 0.0,
"parallelWaiters" : 0,
"individualWaiting" : true,
"deletionDistance" : 0.1,
"startingWithRedLight" : false,
"nextSpeed" : -1.0
} ],
"sources" : [ {
"id" : 1,
"shape" : {
"x" : 1.0,
"y" : 28.0,
"width" : 1.0,
"height" : 1.0,
"type" : "RECTANGLE"
},
"spawnDelay" : -1.0,
"interSpawnTimeDistribution" : "org.vadere.state.scenario.ConstantDistribution",
"distributionParameters" : [ 1.0 ],
"spawnNumber" : 5,
"startTime" : 0.0,
"endTime" : 30.0,
"spawnAtRandomPositions" : false,
"useFreeSpaceOnly" : false,
"targetIds" : [ 2 ],
"dynamicElementType" : "PEDESTRIAN"
} ],
"dynamicElements" : [ {
"targetIds" : [ 2 ],
"position" : {
"x" : 23.0,
"y" : 29.0
},
"velocity" : {
"x" : 0.0,
"y" : 0.0
},
"nextTargetListIndex" : -1,
"freeFlowSpeed" : 1.34,
"attributes" : {
"id" : -1,
"radius" : 0.195,
"densityDependentSpeed" : false,
"speedDistributionMean" : 1.34,
"speedDistributionStandardDeviation" : 0.0,
"minimumSpeed" : 0.3,
"maximumSpeed" : 3.0,
"acceleration" : 2.0
},
"idAsTarget" : -1,
"modelPedestrianMap" : { },
"isChild" : false,
"isLikelyInjured" : false,
"groupIds" : [ ],
"type" : "PEDESTRIAN"
}, {
"targetIds" : [ 2 ],
"position" : {
"x" : 12.7,
"y" : 19.5
},
"velocity" : {
"x" : 0.0,
"y" : 0.0
},
"nextTargetListIndex" : -1,
"freeFlowSpeed" : 1.34,
"attributes" : {
"id" : -1,
"radius" : 0.195,
"densityDependentSpeed" : false,
"speedDistributionMean" : 1.34,
"speedDistributionStandardDeviation" : 0.0,
"minimumSpeed" : 0.3,
"maximumSpeed" : 3.0,
"acceleration" : 2.0
},
"idAsTarget" : -1,
"modelPedestrianMap" : { },
"isChild" : false,
"isLikelyInjured" : false,
"groupIds" : [ ],
"type" : "PEDESTRIAN"
}, {
"targetIds" : [ 2 ],
"position" : {
"x" : 27.3,
"y" : 28.4
},
"velocity" : {
"x" : 0.0,
"y" : 0.0
},
"nextTargetListIndex" : -1,
"freeFlowSpeed" : 1.34,
"attributes" : {
"id" : -1,
"radius" : 0.195,
"densityDependentSpeed" : false,
"speedDistributionMean" : 1.34,
"speedDistributionStandardDeviation" : 0.0,
"minimumSpeed" : 0.3,
"maximumSpeed" : 3.0,
"acceleration" : 2.0
},
"idAsTarget" : -1,
"modelPedestrianMap" : { },
"isChild" : false,
"isLikelyInjured" : false,
"groupIds" : [ ],
"type" : "PEDESTRIAN"
}, {
"targetIds" : [ 2 ],
"position" : {
"x" : 16.3,
"y" : 28.6
},
"velocity" : {
"x" : 0.0,
"y" : 0.0
},
"nextTargetListIndex" : -1,
"freeFlowSpeed" : 1.34,
"attributes" : {
"id" : -1,
"radius" : 0.195,
"densityDependentSpeed" : false,
"speedDistributionMean" : 1.34,
"speedDistributionStandardDeviation" : 0.0,
"minimumSpeed" : 0.3,
"maximumSpeed" : 3.0,
"acceleration" : 2.0
},
"idAsTarget" : -1,
"modelPedestrianMap" : { },
"isChild" : false,
"isLikelyInjured" : false,
"groupIds" : [ ],
"type" : "PEDESTRIAN"
} ],
"attributesPedestrian" : {
"radius" : 0.195,