class_docstr: A Space class for agents, variables and methods
  related to the search space.
class_docstr_tok: ["A","Space","class","for","agents",",","variables","and","methods","related","to","the","search","space","."]
docstr: Initialization method.
  
  Args:
      n_agents: Number of agents.
      n_variables: Number of decision variables.
      n_dimensions: Dimension of search space.
      lower_bound: Minimum possible values.
      upper_bound: Maximum possible values.
      mapping: String-based identifiers for mapping variables' names.
docstr_tok: ["Initialization","method",".","Args",":","n_agents",":","Number","of","agents",".","n_variables",":","Number","of","decision","variables",".","n_dimensions",":","Dimension","of","search","space",".","lower_bound",":","Minimum","possible","values",".","upper_bound",":","Maximum","possible","values",".","mapping",":","String-based","identifiers","for","mapping","variables","'","names","."]
code: def __init__(
      self,
      n_agents: int = 1,
      n_variables: int = 1,
      n_dimensions: int = 1,
      lower_bound: Optional[
          Union[float, List, Tuple, np.ndarray]
      ] = 0.0,
      upper_bound: Optional[
          Union[float, List, Tuple, np.ndarray]
      ] = 1.0,
      mapping: Optional[List[str]] = None,
  ) -> None:
      """Initialization method.
  
      Args:
          n_agents: Number of agents.
          n_variables: Number of decision variables.
          n_dimensions: Dimension of search space.
          lower_bound: Minimum possible values.
          upper_bound: Maximum possible values.
          mapping: String-based identifiers for mapping variables' names.
  
      """
  
      self.n_agents = n_agents
      self.n_variables = n_variables
      self.n_dimensions = n_dimensions
  
      self.lb = np.asarray(lower_bound)
      self.ub = np.asarray(upper_bound)
  
      self.mapping = mapping
  
      self.agents = []
      self.best_agent = Agent(
          n_variables, n_dimensions, lower_bound, upper_bound, mapping
      )
  
      self.built = False
  
imports: from typing import List, Optional, Tuple, Union
  import numpy
  import opytimizer.utils.exception
  from opytimizer.core import Agent
  from opytimizer.utils import logging
label_desc: Use image node_id 1 to create a new Space object  with example: obj = Space(n_agents, n_variables, n_dimensions, lower_bound, upper_bound, mapping)