Search Unity

How to combine .demo files for GAIL and Behavioral Cloning?

Discussion in 'ML-Agents' started by xofreshxo, Oct 19, 2020.

  1. xofreshxo

    xofreshxo

    Joined:
    Apr 12, 2017
    Posts:
    79
    So whenever I record my behavior for behavioral cloning, a new .demo file is created and placed in a directory (behavior1.demo, behavior1_0.demo, .., behavior1_99.demo). Each of these files has like 10-15 episodes. My behavior for the agent then uses this directory for behavioral cloning. Now this is fine at a small scale, but lets say I want to get thousands of episodes that I cannot record in one sitting, is there a way to write to an existing demo file or combine .demo files? I want to prevent having too many files but be able to continue adding episodes over a long period of time.
     
  2. vincentpierre

    vincentpierre

    Joined:
    May 5, 2017
    Posts:
    160
    Hi,

    This feature is on our radar. I will mention your request to the team and we will prioritize accordingly.
     
  3. xofreshxo

    xofreshxo

    Joined:
    Apr 12, 2017
    Posts:
    79
    Thank you very much for your response, I look forward to this feature :D.
     
  4. vincentpierre

    vincentpierre

    Joined:
    May 5, 2017
    Posts:
    160
    My apologies,
    I checked with the team, at it is already possible to use multiple demo files to train. You need to place all the .demo files in a directory and then pass the path to this directory in the config file. The documentation says here : https://github.com/Unity-Technologi...g-Configuration-File.md#gail-intrinsic-reward
    gail -> demo_path (Required, no default) The path to your .demo file or directory of .demo files.​
     
  5. xofreshxo

    xofreshxo

    Joined:
    Apr 12, 2017
    Posts:
    79
    Sorry, I may not have been clear enough in my original post, I am currently doing this. I would like to be able to write to existing files or combine files so that I don't have have thousands of files as I am expecting a large number of recordings with a few episodes in each one. Thanks!
     
  6. vincentpierre

    vincentpierre

    Joined:
    May 5, 2017
    Posts:
    160
    My mistake. I logged your issue in our feature requests and we will prioritize appropriately.