optimization with metaheuristics in python