Skip to content

Commit

Permalink
test(autoware_universe_utils): make opencv_fast_atan2 test reproducible
Browse files Browse the repository at this point in the history
Signed-off-by: Max SCHMELLER <[email protected]>
  • Loading branch information
mojomex authored and xmfcx committed Feb 4, 2025
1 parent b3c69b4 commit b17d7ee
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,8 @@ float normalize_angle(double angle)

TEST(trigonometry, opencv_fast_atan2)
{
std::random_device rd;
std::mt19937 gen(rd());
// Default initialization ensures a constant seed needed for reproducible tests
std::mt19937 gen{};

// Generate random x and y between -10.0 and 10.0 as float
std::uniform_real_distribution<float> dis(-10.0f, 10.0f);
Expand Down

0 comments on commit b17d7ee

Please sign in to comment.