Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
JPSreport
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
JuPedSim
JPSreport
Commits
f6bb29e8
Verified
Commit
f6bb29e8
authored
6 years ago
by
Mohcine Chraibi
Browse files
Options
Downloads
Patches
Plain Diff
init method I
parent
bfc4ed47
Branches
Branches containing commit
No related tags found
2 merge requests
!15
Resolve "Method D | IndividualFD file use wrong PersID"
,
!14
Resolve "Method I | new measurement method"
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
Analysis.cpp
+14
-2
14 additions, 2 deletions
Analysis.cpp
general/ArgumentParser.cpp
+42
-17
42 additions, 17 deletions
general/ArgumentParser.cpp
general/ArgumentParser.h
+2
-0
2 additions, 0 deletions
general/ArgumentParser.h
with
58 additions
and
19 deletions
Analysis.cpp
+
14
−
2
View file @
f6bb29e8
...
@@ -162,6 +162,18 @@ void Analysis::InitArgs(ArgumentParser* args)
...
@@ -162,6 +162,18 @@ void Analysis::InitArgs(ArgumentParser* args)
_IndividualFDFlags
=
args
->
GetIndividualFDFlags
();
_IndividualFDFlags
=
args
->
GetIndividualFDFlags
();
_plotTimeseriesD
=
args
->
GetIsPlotTimeSeriesD
();
_plotTimeseriesD
=
args
->
GetIsPlotTimeSeriesD
();
}
}
if
(
args
->
GetIsMethodI
())
{
_DoesUseMethodI
=
true
;
vector
<
int
>
Measurement_Area_IDs
=
args
->
GetAreaIDforMethodI
();
for
(
unsigned
int
i
=
0
;
i
<
Measurement_Area_IDs
.
size
();
i
++
)
{
_areaForMethod_I
.
push_back
(
dynamic_cast
<
MeasurementArea_B
*>
(
args
->
GetMeasurementArea
(
Measurement_Area_IDs
[
i
])));
}
_StartFramesMethodI
=
args
->
GetStartFramesMethodI
();
_StopFramesMethodI
=
args
->
GetStopFramesMethodI
();
_IndividualFDFlags
=
args
->
GetIndividualFDFlags
();
_plotTimeseriesI
=
args
->
GetIsPlotTimeSeriesI
();
}
_deltaF
=
args
->
GetDelatT_Vins
();
_deltaF
=
args
->
GetDelatT_Vins
();
_cutByCircle
=
args
->
GetIsCutByCircle
();
_cutByCircle
=
args
->
GetIsCutByCircle
();
...
...
This diff is collapsed.
Click to expand it.
general/ArgumentParser.cpp
+
42
−
17
View file @
f6bb29e8
...
@@ -483,23 +483,6 @@ bool ArgumentParser::ParseIniFile(const string& inifile)
...
@@ -483,23 +483,6 @@ bool ArgumentParser::ParseIniFile(const string& inifile)
{
{
areaB
->
_zPos
=
10000001.0
;
areaB
->
_zPos
=
10000001.0
;
}
}
// get bounding box
// loading geometry is done in analysis.cpp
// so this is done twice, which is not nice.
// For big geometries it could be slow.
Building
*
building
=
new
Building
();
building
->
LoadGeometry
(
GetGeometryFilename
().
string
());
building
->
InitGeometry
();
building
->
AddSurroundingRoom
();
// this is a big reactagle
// slightly bigger than the
// geometry boundaries
double
geo_minX
=
building
->
_xMin
;
double
geo_minY
=
building
->
_yMin
;
double
geo_maxX
=
building
->
_xMax
;
double
geo_maxY
=
building
->
_yMax
;
Log
->
Write
(
"INFO:
\t
Bounding box:
\n
\t\t
minX = %.2f
\n
\t\t
maxX = %.2f
\n
\t\t
minY = %.2f
\n\t\t
maxY = %.2f"
,
geo_minX
,
geo_maxX
,
geo_minY
,
geo_maxY
);
std
::
map
<
int
,
polygon_2d
>
geoPoly
;
std
::
map
<
int
,
polygon_2d
>
geoPoly
;
polygon_2d
poly
;
polygon_2d
poly
;
Log
->
Write
(
"INFO:
\t
Measure area id <%d> with type <%s>"
,
areaB
->
_id
,
areaB
->
_type
.
c_str
());
Log
->
Write
(
"INFO:
\t
Measure area id <%d> with type <%s>"
,
areaB
->
_id
,
areaB
->
_type
.
c_str
());
...
@@ -517,6 +500,24 @@ bool ArgumentParser::ParseIniFile(const string& inifile)
...
@@ -517,6 +500,24 @@ bool ArgumentParser::ParseIniFile(const string& inifile)
if
(
num_verteces
==
0
)
// big bounding box
if
(
num_verteces
==
0
)
// big bounding box
{
{
Log
->
Write
(
"
\t
WARNING: NO measure area points given (%d). default BB!!"
,
num_verteces
);
Log
->
Write
(
"
\t
WARNING: NO measure area points given (%d). default BB!!"
,
num_verteces
);
// get bounding box
// loading geometry is done in analysis.cpp
// so this is done twice, which is not nice.
// For big geometries it could be slow.
Building
*
building
=
new
Building
();
building
->
LoadGeometry
(
GetGeometryFilename
().
string
());
building
->
InitGeometry
();
building
->
AddSurroundingRoom
();
// this is a big reactagle
// slightly bigger than the
// geometry boundaries
double
geo_minX
=
building
->
_xMin
;
double
geo_minY
=
building
->
_yMin
;
double
geo_maxX
=
building
->
_xMax
;
double
geo_maxY
=
building
->
_yMax
;
Log
->
Write
(
"INFO:
\t
Bounding box:
\n
\t\t
minX = %.2f
\n
\t\t
maxX = %.2f
\n
\t\t
minY = %.2f
\n\t\t
maxY = %.2f"
,
geo_minX
,
geo_maxX
,
geo_minY
,
geo_maxY
);
//1
//1
double
box_px
=
geo_minX
*
M2CM
;
double
box_px
=
geo_minX
*
M2CM
;
double
box_py
=
geo_minY
*
M2CM
;
double
box_py
=
geo_minY
*
M2CM
;
...
@@ -1182,6 +1183,10 @@ bool ArgumentParser::GetIsMethodD() const
...
@@ -1182,6 +1183,10 @@ bool ArgumentParser::GetIsMethodD() const
{
{
return
_isMethodD
;
return
_isMethodD
;
}
}
bool
ArgumentParser
::
GetIsMethodI
()
const
{
return
_isMethodI
;
}
bool
ArgumentParser
::
GetIsCutByCircle
()
const
bool
ArgumentParser
::
GetIsCutByCircle
()
const
{
{
...
@@ -1227,6 +1232,11 @@ vector<bool> ArgumentParser::GetIsPlotTimeSeriesD() const
...
@@ -1227,6 +1232,11 @@ vector<bool> ArgumentParser::GetIsPlotTimeSeriesD() const
return
_isPlotTimeSeriesD
;
return
_isPlotTimeSeriesD
;
}
}
vector
<
bool
>
ArgumentParser
::
GetIsPlotTimeSeriesI
()
const
{
return
_isPlotTimeSeriesI
;
}
bool
ArgumentParser
::
GetIsOneDimensional
()
const
bool
ArgumentParser
::
GetIsOneDimensional
()
const
{
{
return
_isOneDimensional
;
return
_isOneDimensional
;
...
@@ -1278,16 +1288,31 @@ vector<int> ArgumentParser::GetAreaIDforMethodD() const
...
@@ -1278,16 +1288,31 @@ vector<int> ArgumentParser::GetAreaIDforMethodD() const
return
_areaIDforMethodD
;
return
_areaIDforMethodD
;
}
}
vector
<
int
>
ArgumentParser
::
GetAreaIDforMethodI
()
const
{
return
_areaIDforMethodI
;
}
vector
<
int
>
ArgumentParser
::
GetStartFramesMethodD
()
const
vector
<
int
>
ArgumentParser
::
GetStartFramesMethodD
()
const
{
{
return
_start_frames_MethodD
;
return
_start_frames_MethodD
;
}
}
vector
<
int
>
ArgumentParser
::
GetStartFramesMethodI
()
const
{
return
_start_frames_MethodI
;
}
vector
<
int
>
ArgumentParser
::
GetStopFramesMethodD
()
const
vector
<
int
>
ArgumentParser
::
GetStopFramesMethodD
()
const
{
{
return
_stop_frames_MethodD
;
return
_stop_frames_MethodD
;
}
}
vector
<
int
>
ArgumentParser
::
GetStopFramesMethodI
()
const
{
return
_stop_frames_MethodI
;
}
vector
<
bool
>
ArgumentParser
::
GetIndividualFDFlags
()
const
vector
<
bool
>
ArgumentParser
::
GetIndividualFDFlags
()
const
{
{
return
_individual_FD_flags
;
return
_individual_FD_flags
;
...
...
This diff is collapsed.
Click to expand it.
general/ArgumentParser.h
+
2
−
0
View file @
f6bb29e8
...
@@ -136,10 +136,12 @@ public:
...
@@ -136,10 +136,12 @@ public:
bool
GetIsMethodB
()
const
;
bool
GetIsMethodB
()
const
;
bool
GetIsMethodC
()
const
;
bool
GetIsMethodC
()
const
;
bool
GetIsMethodD
()
const
;
bool
GetIsMethodD
()
const
;
bool
GetIsMethodI
()
const
;
std
::
vector
<
int
>
GetAreaIDforMethodA
()
const
;
std
::
vector
<
int
>
GetAreaIDforMethodA
()
const
;
std
::
vector
<
int
>
GetAreaIDforMethodB
()
const
;
std
::
vector
<
int
>
GetAreaIDforMethodB
()
const
;
std
::
vector
<
int
>
GetAreaIDforMethodC
()
const
;
std
::
vector
<
int
>
GetAreaIDforMethodC
()
const
;
std
::
vector
<
int
>
GetAreaIDforMethodD
()
const
;
std
::
vector
<
int
>
GetAreaIDforMethodD
()
const
;
std
::
vector
<
int
>
GetAreaIDforMethodI
()
const
;
std
::
vector
<
int
>
GetStartFramesMethodD
()
const
;
std
::
vector
<
int
>
GetStartFramesMethodD
()
const
;
std
::
vector
<
int
>
GetStopFramesMethodD
()
const
;
std
::
vector
<
int
>
GetStopFramesMethodD
()
const
;
std
::
vector
<
int
>
GetStartFramesMethodI
()
const
;
std
::
vector
<
int
>
GetStartFramesMethodI
()
const
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment