cost_function_swarm_from_particle

nrv.optim.cost_function_swarm_from_particle(cost_function_part, **kwargs)[source]

Generate a cost function for a swarm from a cost function for a particle

Parameters:
  • cost_function_part (func) – cost function return a cost (float) from a particle (1-dimensional array)

  • verbose (tupple) – if True, print a progress bar for updated whenby default True

Returns:

part – vector of values of the part in the len_part dimension

Return type:

np.ndarray