class_docstr: Differential evolution.
  
  Default pop size equal to 30
  We return the mean of the individuals with fitness better than median, which might be stupid sometimes.
  CR =.5, F1=.8, F2=.8, curr-to-best.
  Initial population: pure random.
class_docstr_tok: ["Differential","evolution",".","Default","pop","size","equal","to","30","We","return","the","mean","of","the","individuals","with","fitness","better","than","median",",","which","might","be","stupid","sometimes",".","CR","=.5",",","F1=.8",",","F2=.8",",","curr-to-best",".","Initial","population",":","pure","random","."]
code: def recommend(
      self,
  ) -> (
      p.Parameter
  ):  # This is NOT the naive version. We deal with noise.
      sample_size = int(
          (self.dimension * (self.dimension - 1)) / 2
          + 2 * self.dimension
          + 1
      )
      if self._config.high_speed and len(self.archive) >= sample_size:
          try:
              meta_data = metamodel.learn_on_k_best(
                  self.archive, sample_size
              )
              return self.parametrization.spawn_child().set_standardized_data(
                  meta_data
              )
          except (
              metamodel.MetaModelFailure
          ):  # The optimum is at infinity. Shit happens.
              pass  # MetaModel failures are something which happens, no worries.
      if self._config.recommendation != "noisy":
          return self.current_bests[
              self._config.recommendation
          ].parameter
      med_fitness = np.median(
          [
              p.loss
              for p in self.population.values()
              if p.loss is not None
          ]
      )
      good_guys = [
          p
          for p in self.population.values()
          if p.loss is not None and p.loss < med_fitness
      ]
      if not good_guys:
          return self.current_bests["pessimistic"].parameter
      data: tp.Any = sum(
          [
              g.get_standardized_data(reference=self.parametrization)
              for g in good_guys
          ]
      ) / len(good_guys)
      out = self.parametrization.spawn_child()
      with p.helpers.deterministic_sampling(out):
          out.set_standardized_data(data)
      return out
  
imports: import warnings
  import numpy
  import nevergrad.common.typing
  from nevergrad.parametrization import parameter
  from .None import metamodel
  from .None import base
  from .None import oneshot
label_desc: Use image node_id 3 for calling the _DE obj's underlying member method code with example usage: obj.recommend() and returns: out, self, self, self