Skip to content

dzylikecode/snake-AI

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

snake-AI

preview struct

  • 当前文件夹的封面或者根目录

  • exercise

    习题

  • book

    学习的主要知识

command usage

  • 激活常用命令

    source ./command.sh
  • 创建环境

    make

    dz_mk
  • 删除环境

    remove

    dz_rm
  • 进入环境

    dz_cd
  • 离开环境

    left

    dz_lf
  • 导入环境

    import

    dz_im
  • 导出环境

    dz_ex

example

install pytorch

dz_in pytorch torchvision torchaudio pytorch-cuda=11.6 -c pytorch -c nvidia

install

  1. prepare for virtual environment

    dz_mk
  2. install pygame

    dz_cd
    • how to install pygame

      • linux ubuntu

        sudo apt-get install python3-pygame

        recommend:

        python3 -m pip install -U pygame --user
      • uninstall

        dz_cd && pip uninstall pygame
  3. play

    • play snake

      dz_snake
    • play snake with AI

      dz_ai

issue