train_curriculum.py 765 Bytes
Newer Older
Benjamin's avatar
Benjamin committed
1
2
3
4
5
6
from mlagents.trainers.trainer_util import load_config

from animalai_train.run_options_aai import RunOptionsAAI
from animalai_train.run_training_aai import run_training_aai

trainer_config_path = "configurations/training_configurations/train_ml_agents_config.yaml"
Benjamin's avatar
Benjamin committed
7
environment_path = "env/AnimalAI"
Benjamin's avatar
Benjamin committed
8
9
curriculum_path = "configurations/curriculum"
run_id = "train_curriculum"
Benjamin's avatar
Benjamin committed
10
11
base_port = 5005
number_of_environments = 8
Benjamin's avatar
Benjamin committed
12
13
14
15
16
17
18
19
20
21
22
23
24
number_of_arenas_per_environment = 1

args = RunOptionsAAI(
    trainer_config=load_config(trainer_config_path),
    env_path=environment_path,
    run_id=run_id,
    base_port=base_port,
    num_envs=number_of_environments,
    curriculum_config=curriculum_path,
    n_arenas_per_env=number_of_arenas_per_environment,
)

run_training_aai(0, args)