Giter VIP home page Giter VIP logo

mcfadd / job_shop_schedule_problem Goto Github PK

View Code? Open in Web Editor NEW
82.0 3.0 24.0 3.51 MB

Parallel Tabu Search and Genetic Algorithm for the Job Shop Schedule Problem with Sequence Dependent Set Up Times

License: ISC License

Python 97.81% HTML 2.19%
job-scheduler job-shop-scheduling-problem job-shop-schedulling tabu-search genetic-algorithm np-hard combinatorics combinatorial-optimization python cython

job_shop_schedule_problem's People

Contributors

avaldez96 avatar mcfadd avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

job_shop_schedule_problem's Issues

TODO List

This issue is for recording a general TODO list of tasks.

Todo

  • Flow diagram describing the steps of our program.
  • Create solution class in data_set.py
  • Create feasible_solution_factory.py for generating feasible solutions.
  • Finish tabu_search.
  • Create another instance of the problem (i.e. jobTasks.csv, sequenceDependencyMatrix.csv, machineRunSpeed.csv) that is slightly bigger than the one currently in the data
  • Create a function that generates schedules with start/end times for the job-tasks on each machines given an operation list. (see code TODO comment in Solution class)
  • Research how to run multiple TS processes in parallel (i.e. multi-programming) and collect their results when they finish. (see multi-programming in python)
  • Research how/if we can use Cython to speed up runtime (i.e. # iterations of TS performed in a certain duration)

Ask for help

I want to use it to solve the aircraft scheduling problem problems on the basis of your program, so I must have a good understanding of your case. Can you recommend some articles?

Understand the input data

Could you explain the "pieces" parameter in class "Task"? Is this like the product quantities of a task? What it is used for in the algorithm?

JSSP.solution._makespan

there are some problem with packets versions
i upgraded them and changed setup.py requirements but when i start the example script is says that JSSP.solution._makespan cant be found

Benchmarks

This issue is for recording benchmark stuff such as average number of iterations tabu search performs in a certain duration. The benchmarks are obtained from benchmark.py.

Error running parallel tabu search on Windows

After building and installing JSSP-0.1.0.win-amd64.zip (Windows build), then running TS_Example.ipynb, the following error appeared:

---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-2-8458fe138112> in <module>
     34                                    benchmark=benchmark,
     35                                    verbose=verbose,
---> 36                                    progress_bar=progress_bar
     37                                   )
     38 

~\Anaconda3\envs\JSSP_env\lib\site-packages\JSSP\solver.py in tabu_search_time(self, runtime, num_solutions_per_process, num_processes, tabu_list_size, neighborhood_size, neighborhood_wait, probability_change_machine, reset_threshold, initial_solutions, benchmark, verbose, progress_bar)
     70                                  probability_change_machine=probability_change_machine,
     71                                  reset_threshold=reset_threshold, initial_solutions=initial_solutions,
---> 72                                  benchmark=benchmark, verbose=verbose, progress_bar=progress_bar)
     73 
     74     def tabu_search_iter(self, iterations, num_solutions_per_process=1, num_processes=4, tabu_list_size=50,

~\Anaconda3\envs\JSSP_env\lib\site-packages\JSSP\solver.py in _tabu_search(self, stopping_condition, time_condition, num_solutions_per_process, num_processes, tabu_list_size, neighborhood_size, neighborhood_wait, probability_change_machine, reset_threshold, initial_solutions, benchmark, verbose, progress_bar)
    186         # start child processes
    187         for p in processes:
--> 188             p.start()
    189             if verbose:
    190                 print(f"child TS process started. pid = {p.pid}")

~\Anaconda3\envs\JSSP_env\lib\multiprocessing\process.py in start(self)
    103                'daemonic processes are not allowed to have children'
    104         _cleanup()
--> 105         self._popen = self._Popen(self)
    106         self._sentinel = self._popen.sentinel
    107         # Avoid a refcycle if the target function holds an indirect

~\Anaconda3\envs\JSSP_env\lib\multiprocessing\context.py in _Popen(process_obj)
    221     @staticmethod
    222     def _Popen(process_obj):
--> 223         return _default_context.get_context().Process._Popen(process_obj)
    224 
    225 class DefaultContext(BaseContext):

~\Anaconda3\envs\JSSP_env\lib\multiprocessing\context.py in _Popen(process_obj)
    320         def _Popen(process_obj):
    321             from .popen_spawn_win32 import Popen
--> 322             return Popen(process_obj)
    323 
    324     class SpawnContext(BaseContext):

~\Anaconda3\envs\JSSP_env\lib\multiprocessing\popen_spawn_win32.py in __init__(self, process_obj)
     63             try:
     64                 reduction.dump(prep_data, to_child)
---> 65                 reduction.dump(process_obj, to_child)
     66             finally:
     67                 set_spawning_popen(None)

~\Anaconda3\envs\JSSP_env\lib\multiprocessing\reduction.py in dump(obj, file, protocol)
     58 def dump(obj, file, protocol=None):
     59     '''Replacement for pickle.dump() using ForkingPickler.'''
---> 60     ForkingPickler(file, protocol).dump(obj)
     61 
     62 #

~\Anaconda3\envs\JSSP_env\lib\site-packages\JSSP\solution\makespan.cp36-win_amd64.pyd in View.MemoryView._memoryviewslice.__reduce_cython__()

TypeError: no default __reduce__ due to non-trivial __cinit__

The problem has to do with pickling cython memory views. When python.multiprocessing.Process starts (i.e. is spawned), the memory views in makespan.cp36-win_amd64.pyd cannot be pickled.

Possible solutions

create a __reduce__ function that converts the memory views to a numpy arrays as described in this stackoverflow thread

Helpful Resources

errors

It gives many errors during the installation phase of the package. Python-dev is also not working.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.