Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.
  2. Join us on Thursday, June 8, for a Q&A with Unity's Content Pipeline group here on the forum, and on the Unity Discord, and discuss topics around Content Build, Import Workflows, Asset Database, and Addressables!
    Dismiss Notice

Multi-task Reinforcement Learning in ML-Agents

Discussion in 'ML-Agents' started by omarsinno, Nov 13, 2020.

  1. omarsinno

    omarsinno

    Joined:
    Jun 10, 2020
    Posts:
    7
    For my final year project, I’m working on an implementation of multitasking for multiple RL agents using ML-Agents. My goal is to produce three different results: single agent performing multiple tasks, multiple agents performing one task, multiple agents performing multiple tasks.

    I have faced difficulties in implementing the concept of agents performing multiple tasks in Unity, I’m trying to find a way to implement it either from scratch or if anyone has any idea on how to tackle this problem (or even better, has an already built example of multitasking in Unity), any help or advice is much appreciated.

    Thank you
     
  2. ruoping_unity

    ruoping_unity

    Unity Technologies

    Joined:
    Jul 10, 2020
    Posts:
    134
    The current ML-Agent toolkit doesn't have explicit algorithm support for multi-task training, but multi-task learning is one of the things that's on our road map and we hope that we can support it soon.

    Here are some directions you can try out with the current toolkit, while there's definitely better approach that requires more effort:
    1. Input a signal representing current task as observation and train the agent with different reward function based on the task.
    2. Make multiple brains and train a one brain for each task. And then when running inference, choose the brain to use according to the current objective.
     
    GamerLordMat and omarsinno like this.
  3. EternalMe

    EternalMe

    Joined:
    Sep 12, 2014
    Posts:
    181
    Something changed in this sector?
     
    SkeVinci likes this.
  4. pagey2004

    pagey2004

    Joined:
    Oct 4, 2018
    Posts:
    1
    We had something similar for our final year project. We implemented multi-objective reinforcement learning. We managed to train the brain with weights so the behaviour could be changed between objectives without retraining. I need to redo this video but here is the link for the video
    The fork for github is at https://github.com/Pagey2004/ml-agents/tree/MORL
     
    EternalMe likes this.
  5. EternalMe

    EternalMe

    Joined:
    Sep 12, 2014
    Posts:
    181