Fishing in the original God, someone even used deep intensive learning and opened it up

Time:2021-12-31

From: the heart of the machine

Still worried about not catching fish in the original God? Here’s a late tiwat fishing guide.

In the game circle, you may not have played, but you must have heard the original God.

Although this is a word-of-mouth polarized game, we have to admit that the original God is one of the hottest games at present.

Especially in foreign countries, the original God can be said to be a mess of fire.

In September this year, this open world adventure game, which has repeatedly topped the discussion heat and ranked first in the gold absorption list of mobile games at home and abroad since the open beta, updated its version, added / enriched maps, and launched a small game fishing. There are fishing spots in many waters in the game. You can catch different fish in different positions.

Although it is a common way to play, it still attracts players. Generally speaking, fishing is divided into three steps: throwing the rod → waiting for the fish to hook → lifting the rod. The principles involved need a certain basis of digital image processing and machine learning. The model is divided into two parts: fish positioning and identification and pull rod (and fish game).

Many players are looking for fishing strategies. Are you still worried that you can’t catch fish in the original God? Today we send you this late tiwat fishing guide.

This fishing guide can be said to completely liberate your hands without any operation. You only need to start the program to complete it. In just a few days, 1600 + stars were harvested.

Fishing in the original God, someone even used deep intensive learning and opened it up

GitHub address:

https://github.com/7eu7d7/gen…

Interested partners can also go to station B to watch videos. They have been online for less than three days and played more than 440000 times. This screen full of bullets, people can not help but call it outrageous.

Some netizens have started, and commented that they are already deploying and downloaded Anaconda overnight.

Fishing in the original God, someone even used deep intensive learning and opened it up

Station B address:

https://www.bilibili.com/video/BV1964y1b7vV?spm_id_from=333.905.b_7570566964656f.3

Project introduction

The protoss auto fishing AI consists of two models:YOLOX、DQN。 In addition, the project also uses transfer learning and semi supervised learning for training. The model also contains some non learnable parts implemented by traditional digital image processing methods such as OpenCV.

  • Yolox is used for the positioning and type identification of fish and the positioning of fishing rod landing point;
  • Dqn is used to adaptively control the click of fishing process to make the force fall in the best area.

install

This project is used in the python running environment. You need to install Python first. Anaconda is recommended here.

Configure environment: open Anaconda prompt (command line interface), create a new Python environment and activate it (Python 3.7 or below is recommended):

conda create -n ysfish python=3.6
conda activate ysfish

Download the project code: use git to download, or download it directly on the GitHub web page and decompress it directly:

git clone https://github.com/7eu7d7/genshin_auto_fish.git

Dependency library installation: switch the command line to the directory where the project is located:

cd genshin_auto_fish

Execute the following command to install dependencies:

python -m pip install -U pip
python requirements.py

If you want to use a graphics card for acceleration, you need to install CUDA and cudnn. After installation, ignore the above command and install the GPU version with the following:

pip install -U pip
python requirements. Py -- CUDA [CUDA version]
#For example, cuda11 x
python requirements.py --cuda 110

Install yolox: switch the command line to the directory where the project is located, and execute the following command to install yolox:

python setup.py develop

Pre training weight Download: Download pre training weight (. PTH file), yolox_ tiny. After PTH download, put the weight file in the project directory / weights.

Yolox training workflow: the yolox part is labeled with semi supervised learning. After labeling a small number of samples, the training model generates false labels for other samples, and then manually modifies them, iterating continuously to improve the accuracy. The sample size is small, so transfer learning is used to carry out fine tuning on the coco pre training model.

Set yolox / exp / yolox_ tiny_ fish. Self in py data_ The value of dir is changed to the path of the two folders after decompression.

Training code:

python yolox_tools/train.py -f yolox/exp/yolox_tiny_fish.py -d 1 -b 8 --fp16 -o -c weights/yolox

Dqn training workflow: control strength and use reinforcement learning model dqn for training. The difference between the two schedules is regarded as reward to provide learning direction for the model. Interactive learning between model and environment.

It takes a long time to train directly in the original God. First, you need to make a simulation environment to simulate the fishing strength control operation. Pre train a model in the simulation environment. The first mock exam is then transferred to the original God to achieve inter domain migration.

Simulation environment pre training code:

python train_sim.py

Protoss in game training:

python train.py

function

After the above is ready, you can run fishing AI. Note that the command line window must be started with administrator privileges.

Graphics card acceleration:

python fishing.py image -f yolox/exp/yolox_tiny_fish.py -c weights/best_tiny3.pth --conf 0.25 --nms 0.45 --tsize 640 --device gpu

CPU running:

python fishing.py image -f yolox/exp/yolox_tiny_fish.py -c weights/best_tiny3.pth --conf 0.25 --nms 0.45 --tsize 640 --device cpu

When init OK appears after running, press R to start fishing. Yuanshen needs full screen. For performance reasons, the detection box will not be displayed in real time, and the processing operation will be carried out in the background.

For more implementation details, readers can refer to the original project.

https://github.com/7eu7d7/gen…

Open source outpostShare popular, interesting and practical open source projects on a daily basis. Participate in maintaining the open source technology resource library of 100000 + star, including python, Java, C / C + +, go, JS, CSS and node js、PHP、. Net, etc.