* 환경
pytorch에서 unity ml-agent 환경을 load해서 학습하는 경우
engine_configuration_channel = EngineConfigurationChannel()
env = UnityEnvironment(file_name=env_name,
side_channels=[engine_configuration_channel])
env.reset()
1. 화면 풀스크린 해제 및 크기 설정
env = UnityEnvironment(file_name=env_name,
additional_args=["-screen-fullscreen", "0", "-screen-width", "800", "-screen-height", "600"],
side_channels=[engine_configuration_channel])
* screen-fullscreen 옵션을 통해 전체화면 여부 결정
* screen-width 및 screen-height 옵션으로 화면 크기 설정
2. GUI 비활성화
env = UnityEnvironment(file_name=env_name,
no_graphics=True,
side_channels=[engine_configuration_channel])
* no_graphics=True 옵션으로 화면 띄우지 않고 학습만 수행하여 속도 향상 가능
'강화학습' 카테고리의 다른 글
| [유니티] 강화학습 환경 구축을 위한 드론 환경 세팅 (2) - ml-agent와 오브젝트 연결 (4) | 2025.08.10 |
|---|---|
| [Unity] The type or namespace name 'NewtonSoft' does not exist in the namespace 'UnityEditor' 에러 해결 (1) | 2025.07.27 |
| [Unity] The type or namespace name 'Recorder' does not exist in the namespace 'UnityEditor' 에러 해결 (0) | 2025.07.27 |
| [유니티] 강화학습 환경 구축을 위한 드론 환경 세팅 (1) - 유니티 세팅 (3) | 2025.07.13 |
| [유니티] ml-agent 설치 (0) | 2025.07.13 |