class_docstr: A PPA class, inherited from Optimizer.
  
  This is the designed class to define PPA-related
  variables and methods.
  
  References:
      A. Mohamed et al. Parasitism – Predation algorithm (PPA): A novel approach for feature selection.
      Ain Shams Engineering Journal (2020).
class_docstr_tok: ["A","PPA","class",",","inherited","from","Optimizer",".","This","is","the","designed","class","to","define","PPA-related","variables","and","methods",".","References",":","A.","Mohamed","et","al",".","Parasitism","\u2013","Predation","algorithm","(","PPA",")",":","A","novel","approach","for","feature","selection",".","Ain","Shams","Engineering","Journal","(","2020",")","."]
docstr: Performs the parasitism phase using the current number of cuckoos.
  
  Args:
      space: Space containing agents and update-related information.
      n_crows: Number of crows.
      n_cuckoos: Number of cuckoos.
      iteration: Current iteration.
      n_iterations: Maximum number of iterations.
docstr_tok: ["Performs","the","parasitism","phase","using","the","current","number","of","cuckoos",".","Args",":","space",":","Space","containing","agents","and","update-related","information",".","n_crows",":","Number","of","crows",".","n_cuckoos",":","Number","of","cuckoos",".","iteration",":","Current","iteration",".","n_iterations",":","Maximum","number","of","iterations","."]
code: def _parasitism_phase(
      self,
      space: Space,
      n_crows: int,
      n_cuckoos: int,
      iteration: int,
      n_iterations: int,
  ):
      """Performs the parasitism phase using the current number of cuckoos.
  
      Args:
          space: Space containing agents and update-related information.
          n_crows: Number of crows.
          n_cuckoos: Number of cuckoos.
          iteration: Current iteration.
          n_iterations: Maximum number of iterations.
  
      """
  
      cuckoos = space.agents[n_crows : n_crows + n_cuckoos]
      fitness = [cuckoo.fit for cuckoo in cuckoos]
  
      p = iteration / n_iterations
  
      for cuckoo in cuckoos:
          s = g.tournament_selection(fitness, 1)[0]
  
          i = r.generate_integer_random_number(high=space.n_agents)
          j = r.generate_integer_random_number(
              high=space.n_agents, exclude_value=i
          )
  
          # Creates a bernoulli distribution to preserve or not variables (eq. 12)
          k = d.generate_bernoulli_distribution(
              1 - p, cuckoo.n_variables
          )
          k = np.expand_dims(k, -1)
  
          # Calculates the gaussian-based step distribution (eq. 11)
          rand = r.generate_uniform_random_number()
          S_g = (
              space.agents[i].position - space.agents[j].position
          ) * rand
  
          # Updates the cuckoo's position and clips its limits (eq. 10)
          cuckoo.position = space.agents[s].position + S_g * k
          cuckoo.clip_by_bound()
  
imports: from typing import Any, Dict, Optional, Tuple
  import numpy
  import opytimizer.math.distribution
  import opytimizer.math.general
  import opytimizer.math.random
  import opytimizer.utils.exception
  from opytimizer.core import Optimizer
  from opytimizer.core.space import Space
  from opytimizer.utils import logging
label_desc: Use image node_id 7 for calling the PPA obj's underlying member method code with example usage: obj._parasitism_phase(space, n_crows, n_cuckoos, iteration, n_iterations) without return types