Unity

[Unity] MLAgent Setting 방법

Guk-blog 2021. 6. 9. 13:12
728x90
반응형
[Unity]
Package Manager - Ml-agents 다운

 

[Python]
Version 3.8.1

 

[cmd ]
cd [프로젝트 경로] cd C:\Users\Dev-park\Desktop\MLAgent_Test
pytorch 다운(옵션) //https://pytorch.org/get-started/previous-versions/ pytorch 버전 참고
pip install torch==1.7.1+cu110 torchvision==0.8.2+cu110 torchaudio==0.7.2 -f https://download.pytorch.org/whl/torch_stable.html
ml-agent 다운 python -m pip install mlagents==0.20.0
//or
python -m pip install mlagents==0.18.0
  1. 가상 환경 생성
python -m venv [가상 환경 이름]
python -m venv agentTrain
  1. 가상 환경 활성화
cd [가상 환경 이름]/scripts
cd agentTrain/sciprts
cd [프로젝트 경로]/[가상 환경 이름]/scripts
cd C:\Users\Dev-park\Desktop\MLAgent_Test/agentTrain/scripts

 

실행 방법

일반 실행 mlagents-learn
덮어 쓰기 mlagents-learn --force
이어 하기 mlagents-learn --resume

 

학습된 브레인 경로 [가상 환경 이름]/scripts/results/ppo
cagentTrain/sciprts/results/ppo
[학습명].nn <- Agent에 부착한 Behavior Parameters에 Behavior Name이 이름

 

728x90
반응형