code: def test_sghs_compile():
      search_space = search.SearchSpace(
          n_agents=2,
          n_variables=2,
          lower_bound=[0, 0],
          upper_bound=[10, 10],
      )
  
      new_sghs = hs.SGHS()
      new_sghs.compile(search_space)
  
      try:
          new_sghs.lp = "a"
      except:
          new_sghs.lp = 1
  
      assert new_sghs.lp == 1
  
      try:
          new_sghs.lp = -1
      except:
          new_sghs.lp = 1
  
      assert new_sghs.lp == 1
  
      try:
          new_sghs.HMCR_history = "a"
      except:
          new_sghs.HMCR_history = []
  
      assert new_sghs.HMCR_history == []
  
      try:
          new_sghs.PAR_history = "a"
      except:
          new_sghs.PAR_history = []
  
      assert new_sghs.PAR_history == []
  
imports: import numpy
  from opytimizer.core import function
  from opytimizer.optimizers.evolutionary import hs
  from opytimizer.spaces import search
  from opytimizer.utils import constant
label_desc: Use image node_id 11 for calling a global function with example usage: test_sghs_compile() without return types