class_docstr: Test suite for the HEBO algorithm.
class_docstr_tok: ["Test","suite","for","the","HEBO","algorithm","."]
docstr: Test that the seeding gives reproducible results.
docstr_tok: ["Test","that","the","seeding","gives","reproducible","results","."]
code: def test_seed_rng_init(self):
      """Test that the seeding gives reproducible results."""
      algo = self.create_algo(seed=1)
  
      trials = algo.suggest(1)
      same_trials = algo.suggest(1)
      assert trials is not None
      assert same_trials is not None
      assert same_trials[0].id != trials[0].id
  
      new_algo = self.create_algo(seed=2)
      self.force_observe(algo.n_observed, new_algo)
      # NOTE: Removing this check from the base test, since the values generated in the random
      # search phase for HEBO are actually pretty consistent across seeds. This is due to them
      # using a `torch.quasirandom.SobolEngine`, which seems to "map out" the space, rather than
      # take random samples from it.
      # assert new_algo.suggest(1)[0].id != trials[0].id
  
      new_algo = self.create_algo(seed=1)
      self.force_observe(algo.n_observed, new_algo)
      same_trials = new_algo.suggest(1)
      assert same_trials is not None
      assert same_trials[0].id == trials[0].id
  
file_path: orion/tests/unittests/algo/long/hebo/test_hebo.py
imports: from __future__ import annotations
  import dataclasses
  import typing
  from typing import ClassVar
  import pytest
  from orion.algo.hebo.hebo_algo import HEBO, EvolutionStrategyName, ModelName, import_optional, properly_seeded_models
  from orion.testing.algo import BaseAlgoTests, TestPhase, first_phase_only
  from hebo.models.model_factory import model_dict
  from pymoo.factory import get_algorithm_options
label_desc: Use image node_id 1 for calling the TestHEBO obj's underlying member method code with example usage: obj.test_seed_rng_init() without return types