prosysscience / RL-Job-Shop-Scheduling

Reinforcement learning approach for job shop scheduling
234 stars 73 forks source link

Running of Code to create GIF #27

Open karthik7194 opened 2 years ago

karthik7194 commented 2 years ago

Hi, Thanks for your Awesome work. Very interesting Can you please explain in short how do you run this entire program? I am quite new to Reinforcement learning. I can see there are 2 set of files: One Specifically for the environment and the other for the RL algorithm. I use Ubuntu 18.04 so I feel there will not be any additional requirements to be installed. Waiting to hear from you.

smita-09 commented 2 years ago

Hello Karthik! Did you figure out how to run it? I ran it but I am getting errors about registering the environment. About your question about how to run: You just need to runpython3 main.py inside JSS folder. About environment, since a package is already mentioned in the requirements.txt to install for the environment so there is nothing you need to do for that.

ingambe commented 2 years ago

Hi @karthik7194,

First of all, sorry for the late answer :(

This project is a simple training approach using PPO to train an agent on the Job-Shop Scheduling Environment we have developed. If you run the main file while having previously set up the configuration dictionary correctly (i.e., the path to the file containing the instance you want to solve and other hyperparameters). It will train an agent to solve the given instance and report the best solution found using Weights and Biases.

The GIF generation in itself is nothing very specific to RL. The full code to generate a GIF is available here: https://github.com/prosysscience/JSSEnv/blob/master/tests/test_rendering.py

You can replace the file with your given instance, provide the agent's solution, and generate a GIF.

I hope it helps :)