Commit 0d4b4372 authored by Mohcine Chraibi's avatar Mohcine Chraibi

Merge branch 'develop' into 'master'

Develop in Master

See merge request !9
parents 2ad0b01d a6053882
Pipeline #9599 passed with stages
in 1 minute and 17 seconds
...@@ -85,3 +85,4 @@ scripts/stefan copy/ ...@@ -85,3 +85,4 @@ scripts/stefan copy/
scripts/stefan/ scripts/stefan/
test.py test.py
/Release/ /Release/
build*
...@@ -25,6 +25,7 @@ configure-linux: ...@@ -25,6 +25,7 @@ configure-linux:
script: script:
- mkdir -p build - mkdir -p build
- cd build - cd build
- which git
- cmake -DCMAKE_BUILD_TYPE=Debug -DBoost_NO_SYSTEM_PATHS=true -DBOOST_ROOT=~/boost_1_61_0 .. - cmake -DCMAKE_BUILD_TYPE=Debug -DBoost_NO_SYSTEM_PATHS=true -DBOOST_ROOT=~/boost_1_61_0 ..
- echo "configure | ${CI_PROJECT_DIR}" - echo "configure | ${CI_PROJECT_DIR}"
stage: configure stage: configure
...@@ -48,7 +49,8 @@ make-linux: ...@@ -48,7 +49,8 @@ make-linux:
- cd build - cd build
- make -j$nproc - make -j$nproc
- echo "compile | ${CI_PROJECT_DIR}" - echo "compile | ${CI_PROJECT_DIR}"
tags:
- linux
after_script: after_script:
- echo "End CI" # todo: run report script - echo "End CI" # todo: run report script
This diff is collapsed.
...@@ -71,10 +71,10 @@ Analysis::Analysis() ...@@ -71,10 +71,10 @@ Analysis::Analysis()
_building = NULL; _building = NULL;
_projectRootDir=""; _projectRootDir="";
_deltaF=5; // half of the time interval that used to calculate instantaneous velocity of ped i. Here v_i = (X(t+deltaF) - X(t+deltaF))/(2*deltaF). X is location. _deltaF=5; // half of the time interval that used to calculate instantaneous velocity of ped i. Here v_i = (X(t+deltaF) - X(t+deltaF))/(2*deltaF). X is location.
_DoesUseMethodA = false; // Method A (Zhang2011a) _DoesUseMethodA = false; // Method A (Zhang2011a)
_DoesUseMethodB = false; // Method B (Zhang2011a) _DoesUseMethodB = false; // Method B (Zhang2011a)
_DoesUseMethodC = false; // Method C //calculate and save results of classic in separate file _DoesUseMethodC = false; // Method C //calculate and save results of classic in separate file
_DoesUseMethodD = false; // Method D--Voronoi method _DoesUseMethodD = false; // Method D--Voronoi method
_cutByCircle = false; //Adjust whether cut each original voronoi cell by a circle _cutByCircle = false; //Adjust whether cut each original voronoi cell by a circle
_getProfile = false; // Whether make field analysis or not _getProfile = false; // Whether make field analysis or not
_outputGraph = false; // Whether output the data for plot the fundamental diagram each frame _outputGraph = false; // Whether output the data for plot the fundamental diagram each frame
...@@ -119,27 +119,6 @@ void Analysis::InitArgs(ArgumentParser* args) ...@@ -119,27 +119,6 @@ void Analysis::InitArgs(ArgumentParser* args)
{ {
string s = "Parameter:\n"; string s = "Parameter:\n";
switch (args->GetLog()) {
case 0:
// no log file
//Log = new OutputHandler();
break;
case 1:
if(Log) delete Log;
Log = new STDIOHandler();
break;
case 2: {
char name[CLENGTH]="";
sprintf(name,"%s.P0.dat",args->GetErrorLogFile().c_str());
if(Log) delete Log;
Log = new FileHandler(name);
}
break;
default:
Log->Write("Wrong option for Log file!");
exit(0);
}
if(args->GetIsMethodA()) { if(args->GetIsMethodA()) {
_DoesUseMethodA = true; _DoesUseMethodA = true;
vector<int> Measurement_Area_IDs = args->GetAreaIDforMethodA(); vector<int> Measurement_Area_IDs = args->GetAreaIDforMethodA();
...@@ -188,6 +167,7 @@ void Analysis::InitArgs(ArgumentParser* args) ...@@ -188,6 +167,7 @@ void Analysis::InitArgs(ArgumentParser* args)
_getProfile = args->GetIsGetProfile(); _getProfile = args->GetIsGetProfile();
_outputGraph = args->GetIsOutputGraph(); _outputGraph = args->GetIsOutputGraph();
_plotGraph = args->GetIsPlotGraph(); _plotGraph = args->GetIsPlotGraph();
_plotIndex = args->GetIsPlotIndex();
_isOneDimensional=args->GetIsOneDimensional(); _isOneDimensional=args->GetIsOneDimensional();
_vComponent = args->GetVComponent(); _vComponent = args->GetVComponent();
_IgnoreBackwardMovement =args->GetIgnoreBackwardMovement(); _IgnoreBackwardMovement =args->GetIgnoreBackwardMovement();
...@@ -273,7 +253,9 @@ std::map<int, polygon_2d> Analysis::ReadGeometry(const std::string& geometryFile ...@@ -273,7 +253,9 @@ std::map<int, polygon_2d> Analysis::ReadGeometry(const std::string& geometryFile
_highVertexY = geo_maxY; _highVertexY = geo_maxY;
_lowVertexX = geo_minX; _lowVertexX = geo_minX;
_lowVertexY = geo_minY; _lowVertexY = geo_minY;
//cout<<"INFO: \tGeometry polygon is:\t"<<dsv(geoPoly)<<endl; // using boost::geometry::dsv;
// cout<<"INFO: \tGeometry polygon is:\t" << dsv(geoPoly[1])<<endl;
return geoPoly; return geoPoly;
} }
...@@ -375,7 +357,7 @@ int Analysis::RunAnalysis(const string& filename, const string& path) ...@@ -375,7 +357,7 @@ int Analysis::RunAnalysis(const string& filename, const string& path)
Log->Write("INFO:\tSuccess with Method C using measurement area id %d!\n",_areaForMethod_C[i]->_id); Log->Write("INFO:\tSuccess with Method C using measurement area id %d!\n",_areaForMethod_C[i]->_id);
if(_plotTimeseriesC[i]) if(_plotTimeseriesC[i])
{ {
string parameters_Timeseries="python3 \""+_scriptsLocation+"/_Plot_timeseries_rho_v.py\" -p \""+ _projectRootDir+VORO_LOCATION + "\" -n "+filename+ string parameters_Timeseries="python \""+_scriptsLocation+"/_Plot_timeseries_rho_v.py\" -p \""+ _projectRootDir+VORO_LOCATION + "\" -n "+filename+
" -f "+boost::lexical_cast<std::string>(data.GetFps()); " -f "+boost::lexical_cast<std::string>(data.GetFps());
int res=system(parameters_Timeseries.c_str()); int res=system(parameters_Timeseries.c_str());
Log->Write("INFO:\t time series result: %d ",res); Log->Write("INFO:\t time series result: %d ",res);
...@@ -403,6 +385,7 @@ int Analysis::RunAnalysis(const string& filename, const string& path) ...@@ -403,6 +385,7 @@ int Analysis::RunAnalysis(const string& filename, const string& path)
method_D.SetGridSize(_grid_size_X, _grid_size_Y); method_D.SetGridSize(_grid_size_X, _grid_size_Y);
method_D.SetOutputVoronoiCellData(_outputGraph); method_D.SetOutputVoronoiCellData(_outputGraph);
method_D.SetPlotVoronoiGraph(_plotGraph); method_D.SetPlotVoronoiGraph(_plotGraph);
method_D.SetPlotVoronoiIndex(_plotIndex);
method_D.SetDimensional(_isOneDimensional); method_D.SetDimensional(_isOneDimensional);
method_D.SetCalculateProfiles(_getProfile); method_D.SetCalculateProfiles(_getProfile);
method_D.SetTrajectoriesLocation(path); method_D.SetTrajectoriesLocation(path);
...@@ -417,7 +400,7 @@ int Analysis::RunAnalysis(const string& filename, const string& path) ...@@ -417,7 +400,7 @@ int Analysis::RunAnalysis(const string& filename, const string& path)
Log->Write("INFO:\tSuccess with Method D using measurement area id %d!\n",_areaForMethod_D[i]->_id); Log->Write("INFO:\tSuccess with Method D using measurement area id %d!\n",_areaForMethod_D[i]->_id);
if(_plotTimeseriesD[i]) if(_plotTimeseriesD[i])
{ {
string parameters_Timeseries="python3 \""+_scriptsLocation+"/_Plot_timeseries_rho_v.py\" -p \""+ _projectRootDir+VORO_LOCATION + "\" -n "+filename+ string parameters_Timeseries="python \""+_scriptsLocation+"/_Plot_timeseries_rho_v.py\" -p \""+ _projectRootDir+VORO_LOCATION + "\" -n "+filename+
" -f "+boost::lexical_cast<std::string>(data.GetFps()); " -f "+boost::lexical_cast<std::string>(data.GetFps());
int res=system(parameters_Timeseries.c_str()); int res=system(parameters_Timeseries.c_str());
Log->Write("INFO:\t time series result: %d ",res); Log->Write("INFO:\t time series result: %d ",res);
...@@ -493,9 +476,5 @@ int Analysis::mkpath(char* file_path, mode_t mode) ...@@ -493,9 +476,5 @@ int Analysis::mkpath(char* file_path, mode_t mode)
} }
return 0; return 0;
} }
// delete
#endif #endif
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
* \file Analysis.h * \file Analysis.h
* \date Oct 10, 2014 * \date Oct 10, 2014
* \version v0.7 * \version v0.7
* \copyright <2009-2015> Forschungszentrum Jlich GmbH. All rights reserved. * \copyright <2009-2015> Forschungszentrum Jülich GmbH. All rights reserved.
* *
* \section License * \section License
* This file is part of JuPedSim. * This file is part of JuPedSim.
...@@ -133,7 +133,11 @@ private: ...@@ -133,7 +133,11 @@ private:
int _circleEdges; int _circleEdges;
bool _getProfile; // Whether make field analysis or not bool _getProfile; // Whether make field analysis or not
bool _outputGraph; // Whether output the data for plot the voronoi diagram each frame bool _outputGraph; // Whether output the data for plot the voronoi diagram each frame
bool _plotGraph; // Whether plot the voronoi diagram each frame bool _plotGraph; // Whether plot the voronoi diagram each
// frame. if (outputGraph==true)
bool _plotIndex; // Whether plot the voronoi diagram each
// frame with index of pedesrians
// if (outputGraph==true and _polotGraph==true)
std::vector<bool> _plotTimeseriesA; std::vector<bool> _plotTimeseriesA;
std::vector<bool> _plotTimeseriesC; std::vector<bool> _plotTimeseriesC;
std::vector<bool> _plotTimeseriesD; std::vector<bool> _plotTimeseriesD;
......
# Change Log # Change Log
All notable changes to `jpsreport` will be documented in this file. All notable changes to `jpsreport` will be documented in this file.
## v0.8.2 [unreleased]
## v0.8.3 [unreleased]
### Added ### Added
- Option to output log in a file instead of the screen fe66fa49
```
<logfile>log.txt</logfile>
```
- Output useful debug information like date, git and compiler versions. !6 and discussion in #79
- Option to plot Voronoi diagrams with index instead of little blue circles `plot_index`. Use as:
```xml
<output_voronoi_cells enabled="true" plot_graphs="true" plot_index="true"/>
```
- new format of returned polygons `"index | polygon"` 6fa459ad9ffe5a07699c05b655bcf90f114ed635
- Exit if `framerate` is not found. c1308ef8
- Use the effective distance in method B in case `length_in_movement_direction` is not defined. (2c321cef) ### Changed
- Pass Matrix by reference bff89e48
- Better fonts in plot scripts. 56d6a8f7
### Fixed
- Ignore empty line in traj file. 3a3ae04e
- Fixes for profile plots. a8a1414c
- Fix parsing of framerate. 2ad0b01d
## v0.8.2 [06.11.2017]
### Added
- Use the effective distance in method B in case `length_in_movement_direction` is not defined. (2c321cef)
- Added an error warning when the number of agents in the trajectory is not corresponding to total ids or the ped ids are not continuous in the first frame. - Added an error warning when the number of agents in the trajectory is not corresponding to total ids or the ped ids are not continuous in the first frame.
### Changed ### Changed
- Code does not come with Boost anymore. User should install Boost before using jpsreport. (2c0c69f3) - Code does not come with Boost anymore. User should install Boost before using jpsreport. (2c0c69f3)
- use boost matrix instead of double pointers (9ff5c978) - use boost matrix instead of double pointers (9ff5c978)
- Use own index numbers (9a0d8ec8) - Use own index numbers (9a0d8ec8)
- Use Python3 in scripts. - Use Python3 in scripts.
### Fixed ### Fixed
- Fixed SegFault due to reading files from different OS. (9a42c9dd) - Fix SegFault due to reading files from different OS. (9a42c9dd)
## v0.8.1 [11.10.2016] ## v0.8.1 [11.10.2016]
...@@ -23,7 +47,7 @@ All notable changes to `jpsreport` will be documented in this file. ...@@ -23,7 +47,7 @@ All notable changes to `jpsreport` will be documented in this file.
- Two options `startframe` and `stopframe` are added for each measurement area for method D to assign the time periods for analysis. - Two options `startframe` and `stopframe` are added for each measurement area for method D to assign the time periods for analysis.
- Individual density based on Voronoi method is added for one dimensional case in the output file (Individual headway is moved to the 5th column). - Individual density based on Voronoi method is added for one dimensional case in the output file (Individual headway is moved to the 5th column).
- z-position of each measurement area can be assigned in inifile so that the trajectories in geometries with several floors can be analyzed. - z-position of each measurement area can be assigned in inifile so that the trajectories in geometries with several floors can be analyzed.
...@@ -66,7 +90,7 @@ All notable changes to `jpsreport` will be documented in this file. ...@@ -66,7 +90,7 @@ All notable changes to `jpsreport` will be documented in this file.
- Issue a warning when the voronoi cell cannot be calculated. - Issue a warning when the voronoi cell cannot be calculated.
- A warning will will be given and the program stops if trajectory for a given pedestrian ID is not continuous. - A warning will will be given and the program stops if trajectory for a given pedestrian ID is not continuous.
### Changed ### Changed
...@@ -93,7 +117,7 @@ All notable changes to `jpsreport` will be documented in this file. ...@@ -93,7 +117,7 @@ All notable changes to `jpsreport` will be documented in this file.
- when path of trajectory is not given absolutely, the default location is the same folder with the inifile - when path of trajectory is not given absolutely, the default location is the same folder with the inifile
## v0.7 ## v0.7
### Added ### Added
...@@ -108,38 +132,38 @@ All notable changes to `jpsreport` will be documented in this file. ...@@ -108,38 +132,38 @@ All notable changes to `jpsreport` will be documented in this file.
- Changed name of some variables in configuration file: - Changed name of some variables in configuration file:
**measurementAreas** ---> **measurement_areas** **measurementAreas** ---> **measurement_areas**
**Length_in_movement_direction** ---> **length_in_movement_direction** **Length_in_movement_direction** ---> **length_in_movement_direction**
**useXComponent** ---> **use_x_component** **useXComponent** ---> **use_x_component**
**useYComponent** ---> **use_y_component** **useYComponent** ---> **use_y_component**
**halfFrameNumberToUse** ---> **frame_step** **halfFrameNumberToUse** ---> **frame_step**
**timeInterval** ---> **frame_interval** **timeInterval** ---> **frame_interval**
**measurementArea** ---> **measurement_area** **measurementArea** ---> **measurement_area**
**outputGraph** ---> **output_graph** **outputGraph** ---> **output_graph**
**individualFDdata** ---> **individual_FD** **individualFDdata** ---> **individual_FD**
**cutByCircle** ---> **cut_by_circle** **cutByCircle** ---> **cut_by_circle**
**getProfile** ---> **profiles** **getProfile** ---> **profiles**
**scale_x** ---> **grid_size_x** **scale_x** ---> **grid_size_x**
**scale_y** ---> **grid_size_y** **scale_y** ---> **grid_size_y**
- Changed the data type of frame rate (fps) from integer to float - Changed the data type of frame rate (fps) from integer to float
- Changed the way for dealing with pedestrian outside geometry. In old version JPSreport stops when some pedestrians are outside geometry but now it continue working by - Changed the way for dealing with pedestrian outside geometry. In old version JPSreport stops when some pedestrians are outside geometry but now it continue working by
removing these pedestrians from the list. removing these pedestrians from the list.
- More than one sub rooms in one geometry can be analysed independently. - More than one sub rooms in one geometry can be analysed independently.
### Fixed ### Fixed
- Fixed bug for dealing with obstacles inside geometry. - Fixed bug for dealing with obstacles inside geometry.
\ No newline at end of file
...@@ -20,6 +20,56 @@ if (Boost_NO_SYSTEM_PATHS) ...@@ -20,6 +20,56 @@ if (Boost_NO_SYSTEM_PATHS)
set(CMAKE_LIBRARY_PATH ${CMAKE_LIBRARY_PATH} ${BOOST_LIBRARY_DIRS}) set(CMAKE_LIBRARY_PATH ${CMAKE_LIBRARY_PATH} ${BOOST_LIBRARY_DIRS})
endif (Boost_NO_SYSTEM_PATHS) endif (Boost_NO_SYSTEM_PATHS)
find_package(Git REQUIRED) # no need for this msg. It comes from cmake.findgit()
find_program(GIT_SCM git DOC "Git version control")
mark_as_advanced(GIT_SCM)
find_file(GITDIR NAMES .git PATHS ${CMAKE_SOURCE_DIR} NO_DEFAULT_PATH)
if (GIT_SCM AND GITDIR)
# the commit's SHA1, and whether the building workspace was dirty or not
# describe --match=NeVeRmAtCh --always --tags --abbrev=40 --dirty
execute_process(COMMAND
"${GIT_EXECUTABLE}" --no-pager describe --tags --always --dirty
WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}"
OUTPUT_VARIABLE GIT_SHA1
ERROR_QUIET OUTPUT_STRIP_TRAILING_WHITESPACE)
# branch
execute_process(
COMMAND "${GIT_EXECUTABLE}" rev-parse --abbrev-ref HEAD
WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}"
OUTPUT_VARIABLE GIT_BRANCH
OUTPUT_STRIP_TRAILING_WHITESPACE
)
# the date of the commit
execute_process(COMMAND
"${GIT_EXECUTABLE}" log -1 --format=%ad --date=local
WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}"
OUTPUT_VARIABLE GIT_DATE
ERROR_QUIET OUTPUT_STRIP_TRAILING_WHITESPACE)
# the subject of the commit
execute_process(COMMAND
"${GIT_EXECUTABLE}" log -1 --format=%s
WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}"
OUTPUT_VARIABLE GIT_COMMIT_SUBJECT
ERROR_QUIET OUTPUT_STRIP_TRAILING_WHITESPACE)
add_definitions("-DGIT_COMMIT_HASH=\"${GIT_SHA1}\"")
add_definitions("-DGIT_COMMIT_DATE=\"${GIT_DATE}\"")
add_definitions("-DGIT_COMMIT_SUBJECT=\"${GIT_COMMIT_SUBJECT}\"")
add_definitions("-DGIT_BRANCH=\"${GIT_BRANCH}\"")
else()
message(STATUS "Not in a git repo")
endif()
#set(EXECUTABLE_OUTPUT_PATH "../") #set(EXECUTABLE_OUTPUT_PATH "../")
#INCLUDE_DIRECTORIES("./") #INCLUDE_DIRECTORIES("./")
# message( STATUS "CMAKE_BINARY_DIR: " ${CMAKE_BINARY_DIR} ) # message( STATUS "CMAKE_BINARY_DIR: " ${CMAKE_BINARY_DIR} )
...@@ -29,12 +79,13 @@ set(CMAKE_TEST_DIR ${CMAKE_SOURCE_DIR}/Utest) ...@@ -29,12 +79,13 @@ set(CMAKE_TEST_DIR ${CMAKE_SOURCE_DIR}/Utest)
set(JPSREPORT_MAJOR_VERSION 0) set(JPSREPORT_MAJOR_VERSION 0)
set(JPSREPORT_MINOR_VERSION 8) set(JPSREPORT_MINOR_VERSION 8)
set(JPSREPORT_PATCH_VERSION 2) set(JPSREPORT_PATCH_VERSION 3)
set(JPSREPORT_VERSION set(JPSREPORT_VERSION
${JPSREPORT_MAJOR_VERSION}.${JPSREPORT_MINOR_VERSION}.${JPSREPORT_PATCH_VERSION}) ${JPSREPORT_MAJOR_VERSION}.${JPSREPORT_MINOR_VERSION}.${JPSREPORT_PATCH_VERSION})
message( STATUS "JPSREPORT_VERSION: " ${JPSREPORT_VERSION} ) message( STATUS "JPSREPORT_VERSION: " ${JPSREPORT_VERSION} )
add_definitions("-DJPSREPORT_VERSION=\"${JPSREPORT_VERSION}\"")
if(NOT CMAKE_BUILD_TYPE) if(NOT CMAKE_BUILD_TYPE)
set (CMAKE_BUILD_TYPE Release) set (CMAKE_BUILD_TYPE Release)
endif(NOT CMAKE_BUILD_TYPE) endif(NOT CMAKE_BUILD_TYPE)
message( STATUS "CMAKE_BUILD_TYPE: " ${CMAKE_BUILD_TYPE} ) message( STATUS "CMAKE_BUILD_TYPE: " ${CMAKE_BUILD_TYPE} )
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_SOURCE_DIR}/bin") set(CMAKE_RUNTIME_OUTPUT_DIRECTORY "${CMAKE_SOURCE_DIR}/bin")
...@@ -74,7 +125,7 @@ endif(NOT DEFINED PROCESSOR_COUNT) ...@@ -74,7 +125,7 @@ endif(NOT DEFINED PROCESSOR_COUNT)
if(PROCESSOR_COUNT) if(PROCESSOR_COUNT)
# add 1 should be magic! http://www.kitware.com/blog/home/post/63 # add 1 should be magic! http://www.kitware.com/blog/home/post/63
#math(EXPR PROCESSOR_COUNT "${PROCESSOR_COUNT} + 1") #math(EXPR PROCESSOR_COUNT "${PROCESSOR_COUNT} + 1")
message( STATUS "PROCESSOR_COUNT " ${PROCESSOR_COUNT}) message( STATUS "PROCESSOR_COUNT " ${PROCESSOR_COUNT})
set(CTEST_BUILD_FLAGS "-j${PROCESSOR_COUNT}") set(CTEST_BUILD_FLAGS "-j${PROCESSOR_COUNT}")
endif(PROCESSOR_COUNT) endif(PROCESSOR_COUNT)
...@@ -102,7 +153,6 @@ if(BUILD_TESTING) ...@@ -102,7 +153,6 @@ if(BUILD_TESTING)
endif(BUILD_TESTING) endif(BUILD_TESTING)
set(source_files set(source_files
getRSS.c
Analysis.cpp Analysis.cpp
IO/OutputHandler.cpp IO/OutputHandler.cpp
general/ArgumentParser.cpp general/ArgumentParser.cpp
...@@ -116,45 +166,45 @@ set(source_files ...@@ -116,45 +166,45 @@ set(source_files
methods/Method_B.cpp methods/Method_B.cpp
methods/Method_C.cpp methods/Method_C.cpp
methods/Method_D.cpp methods/Method_D.cpp
geometry/Building.cpp geometry/Building.cpp
geometry/Line.cpp geometry/Line.cpp
geometry/Point.cpp geometry/Point.cpp
geometry/Transition.cpp geometry/Transition.cpp
geometry/Crossing.cpp geometry/Crossing.cpp
geometry/NavLine.cpp geometry/NavLine.cpp
geometry/Room.cpp geometry/Room.cpp
geometry/Wall.cpp geometry/Wall.cpp
geometry/Hline.cpp geometry/Hline.cpp
geometry/Obstacle.cpp geometry/Obstacle.cpp
geometry/SubRoom.cpp geometry/SubRoom.cpp
geometry/Goal.cpp geometry/Goal.cpp
) )
set ( header_files set ( header_files
Analysis.h Analysis.h
methods/MeasurementArea.h methods/MeasurementArea.h
methods/VoronoiDiagram.h methods/VoronoiDiagram.h
methods/PedData.h methods/PedData.h
methods/Method_A.h methods/Method_A.h
methods/Method_B.h methods/Method_B.h
methods/Method_C.h methods/Method_C.h
methods/Method_D.h methods/Method_D.h
IO/OutputHandler.h IO/OutputHandler.h
general/ArgumentParser.h general/ArgumentParser.h
general/Macros.h general/Macros.h
tinyxml/tinyxml.h tinyxml/tinyxml.h
tinyxml/tinystr.h tinyxml/tinystr.h
geometry/Building.h geometry/Building.h
geometry/Line.h geometry/Line.h
geometry/Point.h geometry/Point.h
geometry/Transition.h geometry/Transition.h
geometry/Crossing.h geometry/Crossing.h
geometry/NavLine.h geometry/NavLine.h
geometry/Room.h geometry/Room.h
geometry/Wall.h geometry/Wall.h
geometry/Hline.h geometry/Hline.h
geometry/Obstacle.h geometry/Obstacle.h
geometry/SubRoom.h geometry/SubRoom.h
geometry/Goal.h geometry/Goal.h
) )
...@@ -205,19 +255,25 @@ message( STATUS "Boost_INCLUDE_DIR: " ${Boost_INCLUDE_DIR} ) ...@@ -205,19 +255,25 @@ message( STATUS "Boost_INCLUDE_DIR: " ${Boost_INCLUDE_DIR} )
message( STATUS "Boost_LIBRARY_DIR: " ${Boost_LIBRARY_DIR} ) message( STATUS "Boost_LIBRARY_DIR: " ${Boost_LIBRARY_DIR} )
include_directories(${Boost_INCLUDE_DIR}) include_directories(${Boost_INCLUDE_DIR})
link_directories(${Boost_LIBRARY_DIR}) #link_directories(${Boost_LIBRARY_DIR})
if (WIN32)
find_library (PSAPI Psapi PATH_SUFFIXES "x64")
message (STATUS "PSAPI: ${PSAPI}")
endif()
add_library ( geometrycore STATIC ${source_files} ) add_library ( geometrycore STATIC ${source_files} )
add_executable( add_executable(
jpsreport main.cpp jpsreport main.cpp
) )
target_link_libraries( jpsreport ${Boost_LIBRARIES} )
target_link_libraries( jpsreport geometrycore )
if(WIN32) if(WIN32)
target_link_libraries (jpsreport wsock32) target_link_libraries (jpsreport wsock32)
target_link_libraries( jpsreport ${PSAPI} )
endif() endif()
target_link_libraries( jpsreport geometrycore )
# ----------------------------- cTest ------------------------------------------ # ----------------------------- cTest ------------------------------------------
if(BUILD_TESTING) if(BUILD_TESTING)
...@@ -228,11 +284,11 @@ if(BUILD_TESTING) ...@@ -228,11 +284,11 @@ if(BUILD_TESTING)
include(CTest) #adding Dart support include(CTest) #adding Dart support
#test if code compiles and runs default setting. Takes about 30 seconds #test if code compiles and runs default setting. Takes about 30 seconds
add_test (jpsreport_compile ${CMAKE_CTEST_COMMAND} add_test (jpsreport_compile ${CMAKE_CTEST_COMMAND}
--build-and-test "${CMAKE_SOURCE_DIR}" "${EXECUTABLE_OUTPUT_PATH}" #"${CMAKE_BINARY_DIR}" --build-and-test "${CMAKE_SOURCE_DIR}" "${EXECUTABLE_OUTPUT_PATH}" #"${CMAKE_BINARY_DIR}"
--build-generator ${CMAKE_GENERATOR} --build-generator ${CMAKE_GENERATOR}
--build-makeprogram ${CMAKE_MAKE_PROGRAM} -j${PROCESSOR_COUNT} --build-makeprogram ${CMAKE_MAKE_PROGRAM} -j${PROCESSOR_COUNT}
--build-two-config --build-two-config
--build-exe-dir ${EXECUTABLE_OUTPUT_PATH} # todo wo soll der exe hin?: ${CMAKE_RUNTIME_OUTPUT_DIRECTORY} --build-exe-dir ${EXECUTABLE_OUTPUT_PATH} # todo wo soll der exe hin?: ${CMAKE_RUNTIME_OUTPUT_DIRECTORY}
--build-project JPSreport --build-project JPSreport
--test-command jpsreport --ini=${CMAKE_TEST_DIR}/files/input_UO_180.xml --test-command jpsreport --ini=${CMAKE_TEST_DIR}/files/input_UO_180.xml
......
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# Getting started with `JPSreport`\n"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"`JPSreport` needs three different files as input: \n",
"- A trajectory file (txt or xml) (see [documentation](http://www.jupedsim.org/jpsreport/2016-11-03-trajectory))\n",
"- A geometry file (see [documentation](http://www.jupedsim.org/jpsreport/2016-11-02-geometry)) \n",
"- and a project file, called inifile (see [documentation](http://www.jupedsim.org/jpsreport/2016-11-01-inifile))\n",
"\n",
"For example in **demos/bottleneck** we can find the following files:"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"Calling `JPSreport` without an inifile yields:"
]
},
{
"cell_type": "code",
"execution_count": 5,
"metadata": {},
"outputs": [
{