WSF
WsfSA_GroupManager Class Reference

#include <WsfSA_GroupManager.hpp>

Public Types

enum  GroupingAlgorithm {
  SIMPLE_POSITIONAL = 0 , SIMPLE_ANGULAR = 1 , K_MEANS = 2 , HIERARCHICAL_TREE_AVERAGE = 3 ,
  HIERARCHICAL_TREE_COMPLETE = 4 , HIERARCHICAL_TREE_SINGLE = 5
}
enum  ScoringAlgorithm { SCORE_2D = 0 , SCORE_3D = 1 , SCORE_VEL = 2 , SCORE_ANG = 3 }
enum  GroupingValidity { VALID , INVALID , INCONCLUSIVE }

Public Member Functions

virtual ~WsfSA_GroupManager ()=default
void InitializeData (WsfPlatform *aPlatform, double aMaxGroupingDistanceCentroid, double aMaxGroupingDistanceNeighbor, double aMaxGroupingHeadingDifference, double aMaxGroupingSpeedDifference, double aMaxGroupingAngle, double aMinGroupRadius, bool aUseCentroidGrouping, bool aUseNeighborGrouping, bool aUseHeadingGrouping, bool aUseSpeedGrouping, bool aUseTypeGrouping)
void UpdateAndAssessGroups (double aSimtime, const WsfPlatform *aPlatform, std::list< WsfSA_Group * > &aCurrentlyPerceivedGroups, const std::vector< WsfSA_EntityPerception * > &aPerceivedBogies, const std::vector< WsfSA_EntityPerception * > &aPerceivedBandits, bool aIgnoreBogies)
void SetGroupingAlgorithms (GroupingAlgorithm aGroupingAlgorithm, ScoringAlgorithm aScoringAlgorithm)
std::string GenerateNewGroupName ()
 Generates a unique group name.
bool AttemptToJoinBestGroup (WsfSA_EntityPerception *aEntity, const std::list< WsfSA_Group * > &aCurrentlyPerceivedGroups)
 Attempt to make aEntity join one of the groups in aCurrentlyPerceivedGroups.
void FormDegenerateGroups (std::list< WsfSA_EntityPerception * > &aAvailableList, std::list< WsfSA_Group * > &aCurrentlyPerceivedGroups)
 Form degenerate groups for each entity in aAvailableList which doesn't have a parent group.
void FormDegenerateGroup (WsfSA_EntityPerception *aEntity, std::list< WsfSA_Group * > &aCurrentlyPerceivedGroups)
 Form a degenerate group for aEntity.

Member Enumeration Documentation

◆ GroupingAlgorithm

Enumerator
SIMPLE_POSITIONAL 
SIMPLE_ANGULAR 
K_MEANS 
HIERARCHICAL_TREE_AVERAGE 
HIERARCHICAL_TREE_COMPLETE 
HIERARCHICAL_TREE_SINGLE 

◆ GroupingValidity

Enumerator
VALID 
INVALID 
INCONCLUSIVE 

◆ ScoringAlgorithm

Enumerator
SCORE_2D 
SCORE_3D 
SCORE_VEL 
SCORE_ANG 

Constructor & Destructor Documentation

◆ ~WsfSA_GroupManager()

virtual WsfSA_GroupManager::~WsfSA_GroupManager ( )
virtualdefault

Member Function Documentation

◆ AttemptToJoinBestGroup()

bool WsfSA_GroupManager::AttemptToJoinBestGroup ( WsfSA_EntityPerception * aEntity,
const std::list< WsfSA_Group * > & aCurrentlyPerceivedGroups )

Attempt to make aEntity join one of the groups in aCurrentlyPerceivedGroups.

aEntity may not join any group if it isn't considered "close enough" to any of them.

Parameters
aEntityThe entity wich may be joining a group.
aCurrentlyPerceivedGroupsThe list of groups which the entity may join.
Returns
True if the entity joined a group, false otherwise.

References WsfSA_Group::AddElement(), WsfSA_GroupUtils::DistanceFromCentroid(), WsfSA_Group::GetElementProtection(), and WsfSA_GroupUtils::RecalculateGroupCentroid().

◆ FormDegenerateGroup()

void WsfSA_GroupManager::FormDegenerateGroup ( WsfSA_EntityPerception * aEntity,
std::list< WsfSA_Group * > & aCurrentlyPerceivedGroups )

Form a degenerate group for aEntity.

If aEntity already has a parent group, it is skipped.

Parameters
aEntityThe entity for which to form a degenerate group.
aCurrentlyPerceivedGroupsThe list of currenty perceived groups.

References WsfSA_Group::AddElement(), GenerateNewGroupName(), WsfSA_EntityPerception::GetParentGroup(), WsfSA_GroupUtils::RecalculateGroupCentroid(), WsfSA_Group::SetPerceivedName(), WsfSA_Group::SetRadiusCurrent_nm(), and WsfSA_Group::SetRadiusMinimum_nm().

Referenced by FormDegenerateGroups().

◆ FormDegenerateGroups()

void WsfSA_GroupManager::FormDegenerateGroups ( std::list< WsfSA_EntityPerception * > & aAvailableList,
std::list< WsfSA_Group * > & aCurrentlyPerceivedGroups )

Form degenerate groups for each entity in aAvailableList which doesn't have a parent group.

If an entity in aAvailableList already has a parent group, it is skipped.

Parameters
aAvailableListA list of entities for which to form a degenerate group.
aCurrentlyPerceivedGroupsThe list of currenty perceived groups.

References FormDegenerateGroup().

◆ GenerateNewGroupName()

std::string WsfSA_GroupManager::GenerateNewGroupName ( )

Generates a unique group name.

Returns
A unique group name.

Referenced by FormDegenerateGroup().

◆ InitializeData()

void WsfSA_GroupManager::InitializeData ( WsfPlatform * aPlatform,
double aMaxGroupingDistanceCentroid,
double aMaxGroupingDistanceNeighbor,
double aMaxGroupingHeadingDifference,
double aMaxGroupingSpeedDifference,
double aMaxGroupingAngle,
double aMinGroupRadius,
bool aUseCentroidGrouping,
bool aUseNeighborGrouping,
bool aUseHeadingGrouping,
bool aUseSpeedGrouping,
bool aUseTypeGrouping )

Referenced by ~WsfSA_GroupManager().

◆ SetGroupingAlgorithms()

void WsfSA_GroupManager::SetGroupingAlgorithms ( GroupingAlgorithm aGroupingAlgorithm,
ScoringAlgorithm aScoringAlgorithm )

◆ UpdateAndAssessGroups()

void WsfSA_GroupManager::UpdateAndAssessGroups ( double aSimtime,
const WsfPlatform * aPlatform,
std::list< WsfSA_Group * > & aCurrentlyPerceivedGroups,
const std::vector< WsfSA_EntityPerception * > & aPerceivedBogies,
const std::vector< WsfSA_EntityPerception * > & aPerceivedBandits,
bool aIgnoreBogies )

The documentation for this class was generated from the following files:
Copyrights Multiple, All Rights Reserved