JSSP.tabu_search.ts module

class JSSP.tabu_search.ts.TabuSearchAgent(stopping_condition, time_condition, initial_solution, num_solutions_to_find=1, tabu_list_size=50, neighborhood_size=300, neighborhood_wait=0.1, probability_change_machine=0.8, reset_threshold=100, benchmark=False)

Bases: object

Tabu search optimization agent.

Parameters:
  • stopping_condition (float) – either the duration in seconds or the number of iterations to search
  • time_condition (bool) – if true TS is ran for stopping_condition number of seconds else it is ran for stopping_condition number of iterations
  • initial_solution (Solution) – initial solution to start the tabu search from
  • num_solutions_to_find (int) – number of best solutions to find
  • tabu_list_size (int) – size of the Tabu list
  • neighborhood_size (int) – size of neighborhoods to generate during each iteration
  • neighborhood_wait (float) – maximum time (in seconds) to wait while generating a neighborhood
  • probability_change_machine (float) – probability of changing a chosen operations machine, must be in range [0, 1]
  • reset_threshold (int) – number of iterations to potentially force a worse move after if the best solution is not improved
  • benchmark (bool) – if true benchmark data is gathered
start(multi_process_queue=None)

Starts the search for this TabuSearchAgent.

If the multi_process_queue parameter is not None, this function attempts to push this TabuSearchAgent to the multi processing queue.

Parameters:multi_process_queue (multiprocessing.Queue) – queue to put this TabuSearchAgent into
Return type:Solution
Returns:best Solution found