Reinforcement learning
Budget: $30 – $250 USD
I will give the starter code. Need to be connected to coppelia sim to check the result from code.
The aim of this project is to develop a reinforcement learning agent that aims at the target container and pours all the objects into it without spillage. You are provided a scene with two cups and two cubes. If you run the code, the cup should start rotating at a velocity randomly chosen from a predefined set. Use the provided functions to move the pouring cup horizontally while rotating it.
Action Space: The source cup can be moved along the X-axis by selecting an action from a predefined set [-2, - 1, 0, 1, 2]. You don’t have to move the cup in any other axis. In the first part of this project, you selected an action randomly from this set.
Now, you have to use Q-Learning to choose an action at any timestamp.
State Space: The state space involves: - The position of two cubes - The position of source cup - The rotation speed of source cup
Your task is to modify the provided Python code to implement the Q-Learning algorithm including: - Initialize Q-table by all zeros. It is a matrix that has the number of states as rows and number of actions as columns, i.e. a states x actions matrix. - Train the Q-learning model and update the Q-table. - Once the model is trained, use the Q-table to decide which action to take. For any state, choose the action with the highest Q value. - Other necessary steps.
Submit your training code - Submit a video that shows cubes are falling to the target after you run your code - Submit a text file containing the reward of each episode in the training - Submit your test script of using the learned Q-table. If you Q-table is saved in another file, include that file - Submit a .txt file with the following result: o How many times all the cubes fell successfully to the target in 10 trials if you choose action randomly? o How many times all the cubes fell successfully to the target in 10 trials if you choose action based on Q-learning?
The aim of this project is to develop a reinforcement learning agent that aims at the target container and pours all the objects into it without spillage. You are provided a scene with two cups and two cubes. If you run the code, the cup should start rotating at a velocity randomly chosen from a predefined set. Use the provided functions to move the pouring cup horizontally while rotating it.
Action Space: The source cup can be moved along the X-axis by selecting an action from a predefined set [-2, - 1, 0, 1, 2]. You don’t have to move the cup in any other axis. In the first part of this project, you selected an action randomly from this set.
Now, you have to use Q-Learning to choose an action at any timestamp.
State Space: The state space involves: - The position of two cubes - The position of source cup - The rotation speed of source cup
Your task is to modify the provided Python code to implement the Q-Learning algorithm including: - Initialize Q-table by all zeros. It is a matrix that has the number of states as rows and number of actions as columns, i.e. a states x actions matrix. - Train the Q-learning model and update the Q-table. - Once the model is trained, use the Q-table to decide which action to take. For any state, choose the action with the highest Q value. - Other necessary steps.
Submit your training code - Submit a video that shows cubes are falling to the target after you run your code - Submit a text file containing the reward of each episode in the training - Submit your test script of using the learned Q-table. If you Q-table is saved in another file, include that file - Submit a .txt file with the following result: o How many times all the cubes fell successfully to the target in 10 trials if you choose action randomly? o How many times all the cubes fell successfully to the target in 10 trials if you choose action based on Q-learning?