Make ai_simulation python3 compatible