def METHOD_NAME(self):
    """
    :return:
    :rtype:
    """
    np.random.seed(42)
    n_particle = 100
    n_iterations = 100
    def ln_probability(x):
        return -np.array(x) ** 2
    pso = ParticleSwarmOptimizer(
        func=ln_probability, low=[-10], high=[10], particle_count=n_particle
    )
    init_pos = np.array([1])
    pso.global_best.position = init_pos
    pso.global_best.velocity = [0] * len(init_pos)
    pso.global_best.fitness = ln_probability(init_pos)
    x2_list = []
    vel_list = []
    pos_list = []
    time_start = time.time()
    if pso.is_master():
        print("Computing the PSO...")
    num_iter = 0
    for swarm in pso.sample(n_iterations):
        x2_list.append(pso.global_best.fitness * 2)
        vel_list.append(pso.global_best.velocity)
        pos_list.append(pso.global_best.position)
        num_iter += 1
        if pso.is_master():
            if num_iter % 10 == 0:
                print(num_iter)
    result = pso.global_best.position
    time_end = time.time()
    print(time_end - time_start)
    print(result)
    npt.assert_almost_equal(result[0], 0, decimal=6)