Commit 5c8800d5 authored by Reinhard Biegel's avatar Reinhard Biegel Committed by Dmitri Fix

Merge branch 'intech' into servant

Change-Id: Iff8b3f8e366e28d3a2a4898363462ef68a2255ca
parents 7dca356b af37a0a1
......@@ -37,14 +37,25 @@
<parameters/>
</component>
<component>
<id>SensorFusion</id>
<id>SensorAggregation</id>
<schedule>
<priority>351</priority>
<offset>0</offset>
<cycle>100</cycle>
<response>0</response>
</schedule>
<library>SensorAggregation_OSI</library>
<parameters/>
</component>
<component>
<id>SensorFusionErrorless</id>
<schedule>
<priority>350</priority>
<offset>0</offset>
<cycle>100</cycle>
<response>0</response>
</schedule>
<library>SensorFusion_OSI</library>
<library>SensorFusionErrorless_OSI</library>
<parameters/>
</component>
<component>
......@@ -550,17 +561,6 @@
<input>2</input>
</target>
</connection>
<connection>
<id>9190</id>
<source>
<component>SensorFusion</component>
<output>0</output>
</source>
<target>
<component>AEB</component>
<input>0</input>
</target>
</connection>
<connection>
<id>9292</id>
<source>
......@@ -588,6 +588,28 @@
<input>100</input>
</target>
</connection>
<connection>
<id>9390</id>
<source>
<component>SensorAggregation</component>
<output>0</output>
</source>
<target>
<component>SensorFusionErrorless</component>
<input>0</input>
</target>
</connection>
<connection>
<id>9490</id>
<source>
<component>SensorFusionErrorless</component>
<output>0</output>
</source>
<target>
<component>AEB</component>
<input>0</input>
</target>
</connection>
<connection>
<id>9581</id>
<source>
......@@ -618,7 +640,7 @@
<output>0</output>
</source>
<target>
<component>SensorFusion</component>
<component>SensorAggregation</component>
<input>0</input>
</target>
</connection>
......
<masterConfig>
<logLevel>0</logLevel>
<logFileMaster>OpenPassMaster.log</logFileMaster>
<slave>OpenPassSlave</slave>
<slave>OpenPassSlave.exe</slave>
<libraries>lib</libraries>
<slaveConfigs>
<slaveConfig>
......
......@@ -37,14 +37,25 @@
<parameters/>
</component>
<component>
<id>SensorFusion</id>
<id>SensorAggregation</id>
<schedule>
<priority>351</priority>
<offset>0</offset>
<cycle>100</cycle>
<response>0</response>
</schedule>
<library>SensorAggregation_OSI</library>
<parameters/>
</component>
<component>
<id>SensorFusionErrorless</id>
<schedule>
<priority>350</priority>
<offset>0</offset>
<cycle>100</cycle>
<response>0</response>
</schedule>
<library>SensorFusion_OSI</library>
<library>SensorFusionErrorless_OSI</library>
<parameters/>
</component>
<component>
......@@ -550,17 +561,6 @@
<input>2</input>
</target>
</connection>
<connection>
<id>9190</id>
<source>
<component>SensorFusion</component>
<output>0</output>
</source>
<target>
<component>AEB</component>
<input>0</input>
</target>
</connection>
<connection>
<id>9292</id>
<source>
......@@ -588,6 +588,28 @@
<input>100</input>
</target>
</connection>
<connection>
<id>9390</id>
<source>
<component>SensorAggregation</component>
<output>0</output>
</source>
<target>
<component>SensorFusionErrorless</component>
<input>0</input>
</target>
</connection>
<connection>
<id>9490</id>
<source>
<component>SensorFusionErrorless</component>
<output>0</output>
</source>
<target>
<component>AEB</component>
<input>0</input>
</target>
</connection>
<connection>
<id>9581</id>
<source>
......@@ -618,7 +640,7 @@
<output>0</output>
</source>
<target>
<component>SensorFusion</component>
<component>SensorAggregation</component>
<input>0</input>
</target>
</connection>
......
<masterConfig>
<logLevel>0</logLevel>
<logFileMaster>OpenPassMaster.log</logFileMaster>
<slave>OpenPassSlave</slave>
<slave>OpenPassSlave.exe</slave>
<libraries>lib</libraries>
<slaveConfigs>
<slaveConfig>
......
......@@ -37,14 +37,25 @@
<parameters/>
</component>
<component>
<id>SensorFusion</id>
<id>SensorAggregation</id>
<schedule>
<priority>351</priority>
<offset>0</offset>
<cycle>100</cycle>
<response>0</response>
</schedule>
<library>SensorAggregation_OSI</library>
<parameters/>
</component>
<component>
<id>SensorFusionErrorless</id>
<schedule>
<priority>350</priority>
<offset>0</offset>
<cycle>100</cycle>
<response>0</response>
</schedule>
<library>SensorFusion_OSI</library>
<library>SensorFusionErrorless_OSI</library>
<parameters/>
</component>
<component>
......@@ -110,7 +121,7 @@
</parameters>
</component>
<component>
<id>PrioritizerLateralVehicleComponents</id>
<id>PrioritizerSteeringVehicleComponents</id>
<schedule>
<priority>150</priority>
<offset>0</offset>
......@@ -154,17 +165,6 @@
<library>Algorithm_Longitudinal</library>
<parameters/>
</component>
<component>
<id>Algorithm_LateralVehicleComponents</id>
<schedule>
<priority>100</priority>
<offset>0</offset>
<cycle>100</cycle>
<response>0</response>
</schedule>
<library>Algorithm_Lateral</library>
<parameters/>
</component>
<component>
<id>Algorithm_LateralAfdm</id>
<schedule>
......@@ -417,17 +417,6 @@
<input>1</input>
</target>
</connection>
<connection>
<id>1412</id>
<source>
<component>Algorithm_LateralVehicleComponents</component>
<output>0</output>
</source>
<target>
<component>PrioritizerSteering</component>
<input>0</input>
</target>
</connection>
<connection>
<id>1512</id>
<source>
......@@ -494,11 +483,11 @@
<connection>
<id>2414</id>
<source>
<component>PrioritizerLateralVehicleComponents</component>
<component>PrioritizerSteeringVehicleComponents</component>
<output>0</output>
</source>
<target>
<component>Algorithm_LateralVehicleComponents</component>
<component>PrioritizerSteering</component>
<input>0</input>
</target>
<target>
......@@ -572,17 +561,6 @@
<input>2</input>
</target>
</connection>
<connection>
<id>9190</id>
<source>
<component>SensorFusion</component>
<output>0</output>
</source>
<target>
<component>AEB</component>
<input>0</input>
</target>
</connection>
<connection>
<id>9292</id>
<source>
......@@ -606,12 +584,30 @@
<input>100</input>
</target>
<target>
<component>Algorithm_LateralVehicleComponents</component>
<component>Dynamics_RegularDriving</component>
<input>100</input>
</target>
</connection>
<connection>
<id>9390</id>
<source>
<component>SensorAggregation</component>
<output>0</output>
</source>
<target>
<component>Dynamics_RegularDriving</component>
<input>100</input>
<component>SensorFusionErrorless</component>
<input>0</input>
</target>
</connection>
<connection>
<id>9490</id>
<source>
<component>SensorFusionErrorless</component>
<output>0</output>
</source>
<target>
<component>AEB</component>
<input>0</input>
</target>
</connection>
<connection>
......@@ -636,10 +632,6 @@
<component>Algorithm_LateralAfdm</component>
<input>101</input>
</target>
<target>
<component>Algorithm_LateralVehicleComponents</component>
<input>101</input>
</target>
</connection>
<connection>
<id>9900</id>
......@@ -648,7 +640,7 @@
<output>0</output>
</source>
<target>
<component>SensorFusion</component>
<component>SensorAggregation</component>
<input>0</input>
</target>
</connection>
......
<masterConfig>
<logLevel>0</logLevel>
<logFileMaster>OpenPassMaster.log</logFileMaster>
<slave>OpenPassSlave</slave>
<slave>OpenPassSlave.exe</slave>
<libraries>lib</libraries>
<slaveConfigs>
<slaveConfig>
......
......@@ -17,7 +17,7 @@
<component>
<id>Sensor_Driver</id>
<schedule>
<priority>490</priority>
<priority>390</priority>
<offset>0</offset>
<cycle>100</cycle>
<response>0</response>
......@@ -37,14 +37,25 @@
<parameters/>
</component>
<component>
<id>SensorFusion</id>
<id>SensorAggregation</id>
<schedule>
<priority>351</priority>
<offset>0</offset>
<cycle>100</cycle>
<response>0</response>
</schedule>
<library>SensorAggregation_OSI</library>
<parameters/>
</component>
<component>
<id>SensorFusionErrorless</id>
<schedule>
<priority>350</priority>
<offset>0</offset>
<cycle>100</cycle>
<response>0</response>
</schedule>
<library>SensorFusion_OSI</library>
<library>SensorFusionErrorless_OSI</library>
<parameters/>
</component>
<component>
......@@ -61,7 +72,7 @@
<component>
<id>ComponentController</id>
<schedule>
<priority>1</priority>
<priority>200</priority>
<offset>0</offset>
<cycle>100</cycle>
<response>0</response>
......@@ -69,6 +80,17 @@
<library>ComponentController</library>
<parameters/>
</component>
<component>
<id>OpenScenarioActions</id>
<schedule>
<priority>400</priority>
<offset>0</offset>
<cycle>100</cycle>
<response>0</response>
</schedule>
<library>OpenScenarioActions</library>
<parameters/>
</component>
<component>
<id>AEB</id>
<schedule>
......@@ -340,17 +362,6 @@
<input>2</input>
</target>
</connection>
<connection>
<id>283</id>
<source>
<component>Dynamics_TrajectoryFollower</component>
<output>83</output>
</source>
<target>
<component>ComponentController</component>
<input>100</input>
</target>
</connection>
<connection>
<id>301</id>
<source>
......@@ -540,14 +551,14 @@
</target>
</connection>
<connection>
<id>9190</id>
<id>8471</id>
<source>
<component>SensorFusion</component>
<component>OpenScenarioActions</component>
<output>0</output>
</source>
<target>
<component>AEB</component>
<input>0</input>
<component>Dynamics_TrajectoryFollower</component>
<input>2</input>
</target>
</connection>
<connection>
......@@ -577,6 +588,28 @@
<input>100</input>
</target>
</connection>
<connection>
<id>9390</id>
<source>
<component>SensorAggregation</component>
<output>0</output>
</source>
<target>
<component>SensorFusionErrorless</component>
<input>0</input>
</target>
</connection>
<connection>
<id>9490</id>
<source>
<component>SensorFusionErrorless</component>
<output>0</output>
</source>
<target>
<component>AEB</component>
<input>0</input>
</target>
</connection>
<connection>
<id>9581</id>
<source>
......@@ -607,7 +640,7 @@
<output>0</output>
</source>
<target>
<component>SensorFusion</component>
<component>SensorAggregation</component>
<input>0</input>
</target>
</connection>
......
......@@ -97,6 +97,9 @@ The table below can be used as orientation when a new module is introduced.
|---|-----------|-----------|-----------|-----------|
| ParametersAgentModules| ParametersAgent| 500 | Parameters | Sets all init-data and is updated cyclically |
| OpenScenarioActions | OpenScenarioActions | 400 | ADAS | Reads events from OpenScenario Actions and forwards them to other components |
| SensorObjectDetector | Sensor_OSI | 398 | Sensor | Gets instantiated multiple time (one time per sensor) |
| SensorAggregation | SensorAggregation_OSI | 351 | Sensor | - |
| SensorFusionErrorless | SensorFusionErrorless_OSI | 350 | Sensor | - |
| AlgorithmAgentFollowingDriverModel | AlgorithmAgentFollowingDriverModel | 310 | DriverModels | - |
| AEB | AlgorithmAutonomousEmergencyBraking | 250 | ADAS | - |
| ComponentController | ComponentController | 200 | ADAS | Manages vehicle component states with regard to other vehicle component states and conditions and in response to events. |
......@@ -179,6 +182,8 @@ With corresponding defined indices :
| ComponentController | Special | 83 |
| OpenScenarioActions | Special | 84 |
| Parameter_Vehicle | Sensor | 92 |
| SensorAggregation | Sensor | 93 |
| SensorFusion | Sensor | 94 |
| Sensor_Driver | Sensor | 95 |
**Ids for Signals (last two digits)**
......@@ -206,6 +211,7 @@ With corresponding defined indices :
| SecondaryDriverTasks | Algorithm | 19 |
| Trajectory | OpenScenarioActions | 71 |
| SensorDriver | Sensor | 81 |
| SensorData | Sensor | 90 |
| ParametersVehicle | Parameters | 92 |
\subsubsection io_input_systemconfigblueprint_paramters Parameters
......
......@@ -188,7 +188,7 @@ Although OpenSCENARIO also states other ways for defining a position, we current
Unlike OpenSCENARIO we also allow some of these values to be stochastic.
This is marked by adding a subtag <Stochastics value="valuetype" stdDeviation="value" lowerBound="value" upperBound="value"/> to the <LanePosition> or <SpeedAction> tag.
The stochastics tag is intended to be used as NormalDistribution, but it is up to each module using it to define the actual usage.
The valuetype can either be s, offset, velocity or rate.
The valuetype can either be s, offset (if inside LanePosition), velocity or rate (if inside SpeedAction).
The value defined as attribute of the LanePosition/SpeedActionDynamics/AbsoluteTargetSpeed tag is then taken as mean value.
The VisibilityAction is optional.
If VisibilityAction is not defined the agent will be spawned.
......@@ -215,6 +215,7 @@ Example
<SpeedActionTarget>
<AbsoluteTargetSpeed value="10.0" />
</SpeedActionTarget>
<Stochastics value="velocity" stdDeviation="2.0" lowerBound="5.0" upperBound="15.0"/>
</SpeedAction>
</LongitudinalAction>
</PrivateAction>
......
......@@ -117,6 +117,56 @@ static double CalculateMomentInertiaYaw(double mass, double length, double width
return std::make_optional<Common::Vector2d>(intersectionPointX, intersectionPointY);
}
//! Calculates the net distance of the x and y coordinates of two bounding boxes
//!
//! \param ownBoundingBox first bounding box
//! \param otherBoundingBox second bounding box
//! \return net distance x, net distance y
[[maybe_unused]] static std::pair<double, double> GetCartesianNetDistance(polygon_t ownBoundingBox, polygon_t otherBoundingBox)
{
double ownMaxX{std::numeric_limits<double>::lowest()};
double ownMinX{std::numeric_limits<double>::max()};
double ownMaxY{std::numeric_limits<double>::lowest()};
double ownMinY{std::numeric_limits<double>::max()};
for (const auto& point : ownBoundingBox.outer())
{
ownMaxX = std::max(ownMaxX, bg::get<0>(point));
ownMinX = std::min(ownMinX, bg::get<0>(point));
ownMaxY = std::max(ownMaxY, bg::get<1>(point));
ownMinY = std::min(ownMinY, bg::get<1>(point));
}
double otherMaxX{std::numeric_limits<double>::lowest()};
double otherMinX{std::numeric_limits<double>::max()};
double otherMaxY{std::numeric_limits<double>::lowest()};
double otherMinY{std::numeric_limits<double>::max()};
for (const auto& point : otherBoundingBox.outer())
{
otherMaxX = std::max(otherMaxX, bg::get<0>(point));
otherMinX = std::min(otherMinX, bg::get<0>(point));
otherMaxY = std::max(otherMaxY, bg::get<1>(point));
otherMinY = std::min(otherMinY, bg::get<1>(point));
}
double netX{0.0};
if (ownMaxX < otherMinX)
{
netX = otherMinX - ownMaxX;
}
if (ownMinX > otherMaxX)
{
netX = otherMaxX - ownMinX;
}
double netY{0.0};
if (ownMaxY < otherMinY)
{
netY = otherMinY - ownMaxY;
}
if (ownMinY > otherMaxY)
{
netY = otherMaxY - ownMinY;
}
return {netX, netY};