floating point literal has suffix 'f', which is not uppercase
78 // Mutators.
79 /////////////////////////////////////////
80
81 void EnableTensorflowDetection(const float fMinObjectConfidence = 0.4f, const float fNMSThreshold = 0.6f); 82 void DisableTensorflowDetection();
83 void SetDetectorFPS(const int nRecordingFPS);
84 void SetEnableRecordingFlag(const bool bEnableRecordingFlag);
floating point literal has suffix 'f', which is not uppercase
78 // Mutators.
79 /////////////////////////////////////////
80
81 void EnableTensorflowDetection(const float fMinObjectConfidence = 0.4f, const float fNMSThreshold = 0.6f); 82 void DisableTensorflowDetection();
83 void SetDetectorFPS(const int nRecordingFPS);
84 void SetEnableRecordingFlag(const bool bEnableRecordingFlag);
floating point literal has suffix 'f', which is not uppercase
122
123 // Remap -1.0 - 1.0 range to drive power range defined in constants. This is so that the driveboard/rovecomm can understand our input.
124 float fDriveBoardLeftPower = numops::MapRange(float(dLeftSpeed), -1.0f, 1.0f, m_fMinDriveEffort, m_fMaxDriveEffort);
125 float fDriveBoardRightPower = numops::MapRange(float(dRightSpeed), -1.0f, 1.0f, m_fMinDriveEffort, m_fMaxDriveEffort);126 // Limit the power to max and min effort defined in constants.
127 fDriveBoardLeftPower = std::clamp(float(fDriveBoardLeftPower), constants::DRIVE_MIN_POWER, constants::DRIVE_MAX_POWER);
128 fDriveBoardRightPower = std::clamp(float(fDriveBoardRightPower), constants::DRIVE_MIN_POWER, constants::DRIVE_MAX_POWER);
floating point literal has suffix 'f', which is not uppercase
122
123 // Remap -1.0 - 1.0 range to drive power range defined in constants. This is so that the driveboard/rovecomm can understand our input.
124 float fDriveBoardLeftPower = numops::MapRange(float(dLeftSpeed), -1.0f, 1.0f, m_fMinDriveEffort, m_fMaxDriveEffort);
125 float fDriveBoardRightPower = numops::MapRange(float(dRightSpeed), -1.0f, 1.0f, m_fMinDriveEffort, m_fMaxDriveEffort);126 // Limit the power to max and min effort defined in constants.
127 fDriveBoardLeftPower = std::clamp(float(fDriveBoardLeftPower), constants::DRIVE_MIN_POWER, constants::DRIVE_MAX_POWER);
128 fDriveBoardRightPower = std::clamp(float(fDriveBoardRightPower), constants::DRIVE_MIN_POWER, constants::DRIVE_MAX_POWER);
floating point literal has suffix 'f', which is not uppercase
121 double dRightSpeed = std::clamp(stDrivePowers.dRightDrivePower, -1.0, 1.0);
122
123 // Remap -1.0 - 1.0 range to drive power range defined in constants. This is so that the driveboard/rovecomm can understand our input.
124 float fDriveBoardLeftPower = numops::MapRange(float(dLeftSpeed), -1.0f, 1.0f, m_fMinDriveEffort, m_fMaxDriveEffort);125 float fDriveBoardRightPower = numops::MapRange(float(dRightSpeed), -1.0f, 1.0f, m_fMinDriveEffort, m_fMaxDriveEffort);
126 // Limit the power to max and min effort defined in constants.
127 fDriveBoardLeftPower = std::clamp(float(fDriveBoardLeftPower), constants::DRIVE_MIN_POWER, constants::DRIVE_MAX_POWER);
floating point literal has suffix 'f', which is not uppercase
121 double dRightSpeed = std::clamp(stDrivePowers.dRightDrivePower, -1.0, 1.0);
122
123 // Remap -1.0 - 1.0 range to drive power range defined in constants. This is so that the driveboard/rovecomm can understand our input.
124 float fDriveBoardLeftPower = numops::MapRange(float(dLeftSpeed), -1.0f, 1.0f, m_fMinDriveEffort, m_fMaxDriveEffort);125 float fDriveBoardRightPower = numops::MapRange(float(dRightSpeed), -1.0f, 1.0f, m_fMinDriveEffort, m_fMaxDriveEffort);
126 // Limit the power to max and min effort defined in constants.
127 fDriveBoardLeftPower = std::clamp(float(fDriveBoardLeftPower), constants::DRIVE_MIN_POWER, constants::DRIVE_MAX_POWER);
floating point literal has suffix 'f', which is not uppercase
274 const bool TAGDETECT_RIGHTCAM_ENABLE_DNN = false; // Whether or not to use DNN detection on top of ArUco.
275 const std::string TAGDETECT_RIGHTCAM_MODEL_PATH = "../data/models/yolo_models/tag/v5n_x320_200epochs/best_edgetpu.tflite"; // The model path to use for detection.
276 const float TAGDETECT_RIGHTCAM_DNN_CONFIDENCE = 0.4f; // The minimum confidence to consider a viable AR tag detection.
277 const float TAGDETECT_RIGHTCAM_DNN_NMS_THRESH = 0.4f; // The threshold for non-max suppression filtering.278
279 ///////////////////////////////////////////////////////////////////////////
280 //// Object Detection Handler Adjustments.
floating point literal has suffix 'f', which is not uppercase
273 const int TAGDETECT_RIGHTCAM_MAX_FPS = 30; // The max iterations per second of the tag detector.
274 const bool TAGDETECT_RIGHTCAM_ENABLE_DNN = false; // Whether or not to use DNN detection on top of ArUco.
275 const std::string TAGDETECT_RIGHTCAM_MODEL_PATH = "../data/models/yolo_models/tag/v5n_x320_200epochs/best_edgetpu.tflite"; // The model path to use for detection.
276 const float TAGDETECT_RIGHTCAM_DNN_CONFIDENCE = 0.4f; // The minimum confidence to consider a viable AR tag detection.277 const float TAGDETECT_RIGHTCAM_DNN_NMS_THRESH = 0.4f; // The threshold for non-max suppression filtering.
278
279 ///////////////////////////////////////////////////////////////////////////
floating point literal has suffix 'f', which is not uppercase
261 const bool TAGDETECT_LEFTCAM_ENABLE_DNN = false; // Whether or not to use DNN detection on top of ArUco.
262 const std::string TAGDETECT_LEFTCAM_MODEL_PATH = "../data/models/yolo_models/tag/v5n_x320_200epochs/best_edgetpu.tflite"; // The model path to use for detection.
263 const float TAGDETECT_LEFTCAM_DNN_CONFIDENCE = 0.4f; // The minimum confidence to consider a viable AR tag detection.
264 const float TAGDETECT_LEFTCAM_DNN_NMS_THRESH = 0.4f; // The threshold for non-max suppression filtering.265
266 // Right ZED Camera.
267 const int TAGDETECT_RIGHTCAM_DATA_RETRIEVAL_THREADS = 2; // The number of threads allocated to the threadpool for performing data copies to other threads.
floating point literal has suffix 'f', which is not uppercase
260 const int TAGDETECT_LEFTCAM_MAX_FPS = 30; // The max iterations per second of the tag detector.
261 const bool TAGDETECT_LEFTCAM_ENABLE_DNN = false; // Whether or not to use DNN detection on top of ArUco.
262 const std::string TAGDETECT_LEFTCAM_MODEL_PATH = "../data/models/yolo_models/tag/v5n_x320_200epochs/best_edgetpu.tflite"; // The model path to use for detection.
263 const float TAGDETECT_LEFTCAM_DNN_CONFIDENCE = 0.4f; // The minimum confidence to consider a viable AR tag detection.264 const float TAGDETECT_LEFTCAM_DNN_NMS_THRESH = 0.4f; // The threshold for non-max suppression filtering.
265
266 // Right ZED Camera.
floating point literal has suffix 'f', which is not uppercase
248 const bool TAGDETECT_MAINCAM_ENABLE_DNN = true; // Whether or not to use DNN detection on top of ArUco.
249 const std::string TAGDETECT_MAINCAM_MODEL_PATH = "../data/models/yolo_models/tag/v5n_x320_200epochs/best_edgetpu.tflite"; // The model path to use for detection.
250 const float TAGDETECT_MAINCAM_DNN_CONFIDENCE = 0.4f; // The minimum confidence to consider a viable AR tag detection.
251 const float TAGDETECT_MAINCAM_DNN_NMS_THRESH = 0.4f; // The threshold for non-max suppression filtering.252
253 // Left ZED Camera.
254 const int TAGDETECT_LEFTCAM_DATA_RETRIEVAL_THREADS = 2; // The number of threads allocated to the threadpool for performing data copies to other threads.
floating point literal has suffix 'f', which is not uppercase
247 const int TAGDETECT_MAINCAM_MAX_FPS = 30; // The max iterations per second of the tag detector.
248 const bool TAGDETECT_MAINCAM_ENABLE_DNN = true; // Whether or not to use DNN detection on top of ArUco.
249 const std::string TAGDETECT_MAINCAM_MODEL_PATH = "../data/models/yolo_models/tag/v5n_x320_200epochs/best_edgetpu.tflite"; // The model path to use for detection.
250 const float TAGDETECT_MAINCAM_DNN_CONFIDENCE = 0.4f; // The minimum confidence to consider a viable AR tag detection.251 const float TAGDETECT_MAINCAM_DNN_NMS_THRESH = 0.4f; // The threshold for non-max suppression filtering.
252
253 // Left ZED Camera.
floating point literal has suffix 'f', which is not uppercase
223
224 // OpenCV ArUco detection config.
225 const cv::aruco::PredefinedDictionaryType ARUCO_DICTIONARY = cv::aruco::DICT_4X4_50; // The predefined ArUco dictionary to use for detections.
226 const float ARUCO_TAG_SIDE_LENGTH = 0.015f; // Size of the white borders around the tag.227 const int ARUCO_VALIDATION_THRESHOLD = 5; // How many times does the tag need to be detected(hit) before being validated as an actual aruco tag.
228 const int ARUCO_UNVALIDATED_TAG_FORGET_THRESHOLD = 5; // How many times can an unvalidated tag be missing from frame before being forgotten.
229 const int ARUCO_VALIDATED_TAG_FORGET_THRESHOLD = 10; // How many times can a validated tag be missing from frame before being forgotten.
floating point literal has suffix 'f', which is not uppercase
145 // ZedCam Spatial Mapping Config.
146 const sl::SpatialMappingParameters::SPATIAL_MAP_TYPE ZED_MAPPING_TYPE = sl::SpatialMappingParameters::SPATIAL_MAP_TYPE::MESH; // Mesh or point cloud output.
147 const float ZED_MAPPING_RANGE_METER = 20.0; // The max range in meters that the ZED cameras should use for mapping. 0 = auto.
148 const float ZED_MAPPING_RESOLUTION_METER = 0.03f; // The approx goal precision for spatial mapping in METERS. Higher = Faster.149 const int ZED_MAPPING_MAX_MEMORY = 4096; // The max amount of CPU RAM (MB) that can be allocated for spatial mapping.
150 const bool ZED_MAPPING_USE_CHUNK_ONLY = true; // Only update chunks that have probably changed or have new data. Faster, less accurate.
151 const int ZED_MAPPING_STABILITY_COUNTER = 3; // Number of times that a point should be seen before adding to mesh.
Description
Found visually ambiguous integer literal constant.
The lowercase letter 'l' (ell) can easily be confused with the digit '1' (one) when indicating that an integer literal constant is a long value. This can lead to confusion and errors in the code.
To avoid this confusion, it is recommended to use uppercase 'L' when indicating that an integer literal constant is a long value. Similarly, use uppercase 'LL' instead of lowercase 'll' when indicating that an integer literal constant is a long long value.
Bad Practice
long long int number = 1234567890ll;
long int length = 1l;
Recommended
long long int number = 1234567890LL;
long int length = 1L;