Autonomy Software C++ 24.5.1
Welcome to the Autonomy Software repository of the Mars Rover Design Team (MRDT) at Missouri University of Science and Technology (Missouri S&T)! API reference contains the source code and other resources for the development of the autonomy software for our Mars rover. The Autonomy Software project aims to compete in the University Rover Challenge (URC) by demonstrating advanced autonomous capabilities and robust navigation algorithms.
Loading...
Searching...
No Matches
objectdetectutils::Object Struct Reference

Represents a single detected object. Combines attributes from TorchObject and TensorflowObject structs. More...

#include <ObjectDetectionUtility.hpp>

Collaboration diagram for objectdetectutils::Object:

Public Member Functions

bool operator== (const Object &stOther) const
 Overridden operator equals for Object struct.
 
bool operator!= (const Object &stOther) const
 Overridden operator equals for Object struct.
 
Objectoperator= (const Object &stOther)
 Overload the assignment operator for the Object struct to perform a deep copy.
 

Public Attributes

std::shared_ptr< cv::Rect2dpBoundingBox = std::make_shared<cv::Rect2d>()
 
double dConfidence = 0.0
 
double dStraightLineDistance = 0.0
 
double dYawAngle = 0.0
 
std::string szClassName = ""
 
std::chrono::system_clock::time_point tmCreation = std::chrono::system_clock::now()
 
ObjectDetectionMethod eDetectionMethod = ObjectDetectionMethod::eUnknown
 
ObjectDetectionType eDetectionType = ObjectDetectionType::eUnknown
 
cv::Size cvImageResolution = cv::Size(0, 0)
 
double dHorizontalFOV = 0.0
 
geoops::Waypoint stGeolocatedPosition = geoops::Waypoint()
 

Detailed Description

Represents a single detected object. Combines attributes from TorchObject and TensorflowObject structs.

Author
clayjay3 (clayt.nosp@m.onra.nosp@m.ycowe.nosp@m.n@gm.nosp@m.ail.c.nosp@m.om)
Date
2025-05-09

Member Function Documentation

◆ operator==()

bool objectdetectutils::Object::operator== ( const Object stOther) const
inline

Overridden operator equals for Object struct.

Parameters
stOther- The other Object struct we are comparing to.
Returns
true - The two Objects are equal.
false - The two Objects are not equal.
Author
clayjay3 (clayt.nosp@m.onra.nosp@m.ycowe.nosp@m.n@gm.nosp@m.ail.c.nosp@m.om)
Date
2025-05-05
100 {
101 return *pBoundingBox == *stOther.pBoundingBox && dConfidence == stOther.dConfidence && dStraightLineDistance == stOther.dStraightLineDistance &&
102 dYawAngle == stOther.dYawAngle && szClassName == stOther.szClassName && tmCreation == stOther.tmCreation &&
103 eDetectionMethod == stOther.eDetectionMethod && eDetectionType == stOther.eDetectionType && cvImageResolution == stOther.cvImageResolution &&
104 dHorizontalFOV == stOther.dHorizontalFOV && stGeolocatedPosition == stOther.stGeolocatedPosition;
105 }

◆ operator!=()

bool objectdetectutils::Object::operator!= ( const Object stOther) const
inline

Overridden operator equals for Object struct.

Parameters
stOther- The other Object struct we are comparing to.
Returns
true - The two Objects are not equal.
false - The two Objects are equal.
Author
clayjay3 (clayt.nosp@m.onra.nosp@m.ycowe.nosp@m.n@gm.nosp@m.ail.c.nosp@m.om)
Date
2025-05-05
117{ return !(*this == stOther); }

◆ operator=()

Object & objectdetectutils::Object::operator= ( const Object stOther)
inline

Overload the assignment operator for the Object struct to perform a deep copy.

Parameters
stOther- The other Object struct to copy from.
Returns
Object& - The current Object struct.
Author
clayjay3 (clayt.nosp@m.onra.nosp@m.ycowe.nosp@m.n@gm.nosp@m.ail.c.nosp@m.om)
Date
2025-05-05
129 {
130 // Check if the other Object is not the same as this one.
131 if (this != &stOther)
132 {
133 // Shallow copy the bounding box.
134 pBoundingBox = stOther.pBoundingBox;
135
136 // Copy other member variables.
137 dConfidence = stOther.dConfidence;
138 dStraightLineDistance = stOther.dStraightLineDistance;
139 dYawAngle = stOther.dYawAngle;
140 szClassName = stOther.szClassName;
141 tmCreation = stOther.tmCreation;
142 eDetectionMethod = stOther.eDetectionMethod;
143 eDetectionType = stOther.eDetectionType;
144 cvImageResolution = stOther.cvImageResolution;
145 dHorizontalFOV = stOther.dHorizontalFOV;
146 stGeolocatedPosition = stOther.stGeolocatedPosition;
147 }
148 return *this;
149 }

The documentation for this struct was generated from the following file: