- Using a unique competitive coevolution method to niche agents in the game Xpilot to quadrants on "the core" map
- Each agent spawns with a unique chromosome that determines their actions, crossover happens when one agent shoots another
- Work up to May 4th 2025 was documented and presented during the COM 496 research presentations on May 5th 2025
- Computer made after the year 1995 running some sort of linux distro
- At least 1 gigabyte of storage per 24 hours of training
- pip install -r requirements.txt
- Unzip compile.zip
- Navigate to root/compile/scripts/xpilot-ai-1.1.1604-linux.sh and run
- From there, open xpilot-ai
- Copy xpilots_mod and navigate to root/src/Engine
- Paste xpilots_mod over the old xpilots_mod
- Navigate to root/utils
- Run reset_traceback_and_data.sh to clear the data folder, ignore this if you want to continue a previous run
- Run start_team_server.sh or navigate to root/src/Engine/maps and in the terminal run ./../xpilots_mod -map core_teams.xp -shotKillScoreMult 100 -noquit -teamPlay +switchBase 1.0 -maxRoundTime 60 -roundsToPlay 0 +limitedLives -maxClientsPerIP 120 +teamImmunity
- Navigate to root/utils/Team Agents and run launch team agents.sh
- Wait for all agents to finish launching, note that training data is logged in real time to root/data
- Navigate to root/utils
- Run reset_traceback_and_data.sh to clear the data folder, ignore this if you want to continue a previous run
- Run start_xpilots_server.sh or navigate to root/src/Engine/maps and in the terminal run ./../xpilots_mod -map core_teams.xp -shotKillScoreMult 100 -noquit +teamPlay +switchBase 1.0 -maxRoundTime 60 -roundsToPlay 0 +limitedLives -maxClientsPerIP 120 +teamImmunity
- Navigate to root/and run random spawn launcher.sh
- Wait for all agents to finish launching, note that training data is logged in real time to root/data
To test our agents fitness (niched agents in their original quadrants vs niched agents from foreign quadrants):
Note that root/testing fitnesses is preloaded with agents that have already been trained for 72 hours, so to run the best agents, we can run the agents already in testing fitnesses
- Train niched agents or use best agents
- Cut all data saved in root/data
- Navigate to root/testing fitnesses
- Paste
- Run clean_data.py
- Navigate to root/utils
- Run start_battle_server.sh or navigate to root/src/Engine/maps and in the terminal run ./../xpilots_mod -map core_battle.xp -shotKillScoreMult 100 -noquit -teamPlay +switchBase 1.0 -maxRoundTime 60 -roundsToPlay 0 +limitedLives -maxClientsPerIP 120 -teamImmunity
- Run mix and match battle agents, native.sh and mix and match battle agents, shifted.sh at the same time
- Let agents battle for at least 6 hours to give the agents a good amount of time to collect results
- Navigate to root/testing fitnesses
- Run all cells in compare mix and match.ipynb to get a graph of the agents performance over time, note that by default the graphs go from 0 mins to 864 mins, and 0 kills to 12000 kills, you can adjust that at the top of the last cell
Note that root/testing fitnesses is preloaded with agents that have already been trained for 72 hours, so to run the best agents, we can run the agents already in testing fitnesses
- Train niched agents or use best agents
- Cut all data saved in root/data
- Navigate to root/testing fitnesses
- Paste
- Navigate to root/utils
- Train non niched agents or use best agents
- Cut all data saved in root/data
- Navigate to root/testing fitnesses
- Paste
- Run clean_data.py
- Navigate to root/utils
- Run start_battle_server.sh or navigate to root/src/Engine/maps and in the terminal run ./../xpilots_mod -map core_battle.xp -shotKillScoreMult 100 -noquit -teamPlay +switchBase 1.0 -maxRoundTime 60 -roundsToPlay 0 +limitedLives -maxClientsPerIP 120 -teamImmunity
- Run battle agents, niched.sh and battle agents, not niched.sh at the same time
- Let agents battle for at least 6 hours to give the agents a good amount of time to collect results
- Navigate to root/testing fitnesses
- Run all cells in compare mix and match.ipynb to get a graph of the agents performance over time, note that by default the graphs go from 0 mins to 864 mins, and 0 kills to 12000 kills, you can adjust that at the top of the last cell