class_docstr: A BWO class, inherited from Optimizer.
  
  This is the designed class to define BWO-related
  variables and methods.
  
  References:
      V. Hayyolalam and A. Kazem.
      Black Widow Optimization Algorithm: A novel meta-heuristic approach
      for solving engineering optimization problems.
      Engineering Applications of Artificial Intelligence (2020).
class_docstr_tok: ["A","BWO","class",",","inherited","from","Optimizer",".","This","is","the","designed","class","to","define","BWO-related","variables","and","methods",".","References",":","V.","Hayyolalam","and","A.","Kazem",".","Black","Widow","Optimization","Algorithm",":","A","novel","meta-heuristic","approach","for","solving","engineering","optimization","problems",".","Engineering","Applications","of","Artificial","Intelligence","(","2020",")","."]
docstr: Procreates a pair of parents into offsprings (eq. 1).
  
  Args:
      x1: Father to produce the offsprings.
      x2: Mother to produce the offsprings.
  
  Returns:
      (Tuple[Agent, Agent]): Two generated offsprings based on parents.
docstr_tok: ["Procreates","a","pair","of","parents","into","offsprings","(","eq",".","1",")",".","Args",":","x1",":","Father","to","produce","the","offsprings",".","x2",":","Mother","to","produce","the","offsprings",".","Returns",":","(","Tuple","[","Agent",",","Agent","]",")",":","Two","generated","offsprings","based","on","parents","."]
code: def _procreating(self, x1: Agent, x2: Agent) -> Tuple[Agent, Agent]:
      """Procreates a pair of parents into offsprings (eq. 1).
  
      Args:
          x1: Father to produce the offsprings.
          x2: Mother to produce the offsprings.
  
      Returns:
          (Tuple[Agent, Agent]): Two generated offsprings based on parents.
  
      """
  
      y1, y2 = copy.deepcopy(x1), copy.deepcopy(x2)
  
      alpha = r.generate_uniform_random_number()
      y1.position = alpha * x1.position + (1 - alpha) * x2.position
      y2.position = alpha * x2.position + (1 - alpha) * x1.position
  
      return y1, y2
  
imports: import copy
  from typing import Any, Dict, Optional, Tuple
  import opytimizer.math.random
  import opytimizer.utils.exception
  from opytimizer.core import Optimizer
  from opytimizer.core.agent import Agent
  from opytimizer.core.function import Function
  from opytimizer.core.space import Space
  from opytimizer.utils import logging
label_desc: Use image node_id 8 for calling the BWO obj's underlying member method code with example usage: obj._procreating(x1, x2) and returns: y1,  y2