Kinds-of-Intelligence-CFI / animal-ai-unity

Animal-AI Unity
https://github.com/Kinds-of-Intelligence-CFI/animal-ai
Apache License 2.0
1 stars 2 forks source link

Error in arena cycling in play mode #33

Open kozzy97 opened 4 months ago

kozzy97 commented 4 months ago

When playing the following config with multiple arenas, I occasionally get an error where the arena skips to the next one several times in quick succession, until settling on one of the arenas. Each arena works individually, and the skipping doesn't seem to be dependent on the particular arena.

Steps to reproduce the behavior:

  1. Run the following config in play mode using a jupyter notebook, the latest AAI release and the latest PyPI release.
    !ArenaConfig
    showNotification: true
    arenas:
    0: !Arena
    pass_mark: 1
    t: 500
    items:
    - !Item
      name: Agent
      positions:
      - !Vector3 {x: 20, y: 0, z: 1}
      rotations: [0]
    - !Item
      name: GoodGoal
      positions:
      - !Vector3 {x: 20, y: 0, z: 20}
      sizes:
      - !Vector3 {x: 2, y: 2, z: 2}
    1: !Arena
    pass_mark: 1
    t: 500
    items:
    - !Item
      name: Agent
      positions:
      - !Vector3 {x: 20, y: 0, z: 1}
      rotations: [0]
    - !Item
      name: GoodGoalMulti
      positions:
      - !Vector3 {x: 20, y: 0, z: 20}
      sizes:
      - !Vector3 {x: 2, y: 2, z: 2}
    2: !Arena
    pass_mark: 1
    t: 500
    items:
    - !Item
      name: Agent
      positions:
      - !Vector3 {x: 20, y: 0, z: 1}
      rotations: [0]
    - !Item
      name: BadGoal
      positions:
      - !Vector3 {x: 20, y: 0, z: 20}
      sizes:
      - !Vector3 {x: 2, y: 2, z: 2}
    3: !Arena
    pass_mark: 1
    t: 500
    items:
    - !Item
      name: Agent
      positions:
      - !Vector3 {x: 20, y: 0, z: 1}
      rotations: [0]
    - !Item
      name: DeathZone
      positions:
      - !Vector3 {x: 20, y: 0, z: 20}
      sizes:
      - !Vector3 {x: 10, y: 2, z: 2}
      rotations: [0]

Expected behavior Arenas should cycle through and enable the player to play each episode unless they skip it.

Screenshots Contact me for a screen capture of the problem.

Desktop (please complete the following information):

alhasacademy96 commented 4 months ago

Hi, @kozzy97, is this for PLAY or TRAINING mode? Have you tried on both or either to reproduce the bug?

kozzy97 commented 4 months ago

@alhasacademy96 as stated in the issue title, the issue is in play mode. I have only noticed the bug in play mode.

alhasacademy96 commented 4 months ago

Hi @kozzy97, i wasn't able to reproduce the bug. I'm also using the latest build and python package. It could be as simple as memory overload on your computer, causing a bottleneck during play. I tried play and train mode and works fine. I had no other applications open/running when I pressed play.

I've tested on WIN11 and macOS.

I will continue debugging to see if any of the parameter values are the culprit.

github-actions[bot] commented 2 months ago

This issue is stale because it has been open for 45 days with no activity.

alhasacademy96 commented 2 months ago

Being actively worked on now.

github-actions[bot] commented 4 weeks ago

This issue is stale because it has been open for 45 days with no activity.