ResnetGPT  by FengQuanLi

AI for playing Honor of Kings (Arena of Valor)

Created 4 years ago
2,925 stars

Top 16.3% on SourcePulse

GitHubView on GitHub
Project Summary

This project provides an AI agent for playing the mobile game "Honor of Kings" using a ResNet101 and GPT architecture. It's designed for researchers and enthusiasts interested in game AI and reinforcement learning, offering a practical implementation of a vision-based agent.

How It Works

The AI combines a ResNet101 for visual feature extraction from game screenshots with a GPT-based decoder for action prediction. This approach leverages pre-trained image recognition capabilities and sequence modeling to interpret game state and generate control commands. The system relies on minitouch for touch input simulation on Android devices.

Quick Start & Requirements

  • Installation: Clone the repository and install dependencies via pip.
  • Prerequisites:
    • Windows 10/7
    • NVIDIA GPU with 6GB+ VRAM (4GB may work)
    • Android phone with USB debugging enabled, running "Honor of Kings" with a specific game layout.
    • scrcpy (Windows version)
    • minitouch (may auto-install, otherwise manual installation required; note: minitouch does not support Android 10).
  • Setup: Requires careful configuration of device ID, game layout, and potentially touch mapping (.json files) based on phone resolution and orientation.

Highlighted Details

  • Uses ResNet101 for image feature extraction and a GPT decoder for action generation.
  • Relies on minitouch for simulating touch inputs on Android devices.
  • Includes scripts for data generation, preprocessing, and model training.
  • Provides pre-trained models and sample training data via Baidu Netdisk and Google Cloud.
  • Requires manual mapping of game controls to minitouch coordinates based on device specifics.

Maintenance & Community

The project is explicitly marked as no longer updated, with a successor project focusing on reinforcement learning. The original author mentions potential future video tutorials.

Licensing & Compatibility

The README does not explicitly state a license. Compatibility is limited to specific Android versions (pre-Android 10 due to minitouch) and requires precise game layout matching.

Limitations & Caveats

The provided pre-trained model is described as having a very low skill level (potentially worse than beginner AI bots) due to limited training data (100+ games). Game updates may break functionality. Touch mapping requires significant manual adjustment for different devices and orientations.

Health Check
Last Commit

4 years ago

Responsiveness

1 day

Pull Requests (30d)
0
Issues (30d)
0
Star History
18 stars in the last 30 days

Explore Similar Projects

Feedback? Help us improve.