Skip to content

--results-dir training command line training option not working #5268

@fredleefarr

Description

@fredleefarr

Describe the bug
Using the command line option "--results-dir" did not create a different results directory.

To Reproduce
Run an "mlagents-learn" command with --results-dir="myresults" to see if the myresults directory is created.

Environment (please complete the following information):

  • Unity Version: 2020.2.2f1
  • OS Windows 10
    Version information:
    ml-agents: 0.25.0,
    ml-agents-envs: 0.25.0,
    Communicator API: 1.5.0,
    PyTorch: 1.7.1+cpu

To Fix
I dug into the source code, and found the following in cli_utils.py (line 192):

argparser.add_argument(
    "--results-dir", default="results", help="Results base directory"
)

Adding "action=DetectDefault" resolved the issue for me:

argparser.add_argument(
    "--results-dir", 
    default="results", 
    help="Results base directory",
    action=DetectDefault
)

Metadata

Metadata

Assignees

Labels

bugIssue describes a potential bug in ml-agents.

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions