Monday, April 19, 2021
  • Setup menu at Appearance » Menus and assign menu to Top Bar Navigation
Advertisement
  • AI Development
    • Artificial Intelligence
    • Machine Learning
    • Neural Networks
    • Learn to Code
  • Data
    • Blockchain
    • Big Data
    • Data Science
  • IT Security
    • Internet Privacy
    • Internet Security
  • Marketing
    • Digital Marketing
    • Marketing Technology
  • Technology Companies
  • Crypto News
No Result
View All Result
NikolaNews
  • AI Development
    • Artificial Intelligence
    • Machine Learning
    • Neural Networks
    • Learn to Code
  • Data
    • Blockchain
    • Big Data
    • Data Science
  • IT Security
    • Internet Privacy
    • Internet Security
  • Marketing
    • Digital Marketing
    • Marketing Technology
  • Technology Companies
  • Crypto News
No Result
View All Result
NikolaNews
No Result
View All Result
Home Machine Learning

Training a Deep Reinforcement Learning Agent to Play Snake

August 12, 2020
in Machine Learning
Training a Deep Reinforcement Learning Agent to Play Snake
586
SHARES
3.3k
VIEWS
Share on FacebookShare on Twitter

Those of us who have ever used a Nokia mobile phone two decades ago will remember the Snake game that was first introduced on the Nokia 6110. An adaption of an arcade game from 1976, it eventually found itself on 400 million phones. Indeed, there is even a “World Snake Day” for nostalgic fans to remember this bygone era.

But can you train a deep reinforcement learning agent to play the game? Data scientist Hennie de Harder decided to find out and chronicled her journey of pitting an agent against a Python version of the game in a blog post on Towards Data Science.

You might also like

Machine Learning Helps Optimize Therapeutic Antibodies

Researchers at MIT DAI Lab Have Recently Built Cardea: A Machine Learning Framework That Turns Health Care Data Into Insights

Automating Drug Discovery With Machine Learning

There’s an ML agent for that

One of three basic machine learning paradigms, reinforcement learning is an area of machine learning concerned with software agents that take action based on maximizing predefined rewards.

On its part, deep reinforcement combines deep learning and reinforcement learning to simulate how humans learn from experience.

She describes it this way: “Deep Learning uses artificial neural networks to map inputs to outputs… The network exists of layers with nodes. The first layer is the input layer. Then the hidden layers transform the data with weights and activation functions. The last layer is the output layer, where the target is predicted. By adjusting the weights, the network can learn patterns and improve its predictions.”

Training the agent entails rewarding or penalizing it based on its actions, which was what de Harder focused on. Eating the apple will net 10 points, drawing closer to apple 1, moving away from the apple is negative 1, and dying by hitting the wall or itself would be a negative 100.

She also experimented with various tweaks to the state space, changing the feedback that the agent gets with regards to the status of the game to improve learning. That didn’t work out, however, with slower improvements with options other than the original.

Success! Sort of

It was evident that learning from the experience of previous plays allowed for fast learning after only 30 games. Indeed, taking this away saw the agent fare very poorly, catching just three apples even after 10,000 games. From the experiments, a batch size of four worked the best.

But while the high score of between 40 and 60 after just 50 games is much better than a random agent – and probably many of us – it is far from the maximum theoretical score of 399. The reason for this? The agent fails to see the entire game, which means that the propensity to eventually enclose upon itself and lose is high, increasing as the snake grows longer.

One possible improvement, suggest de Harder, would be to apply convolutional neural networks in the state space to give the agent visibility over the entire game instead of being limited nearby obstacles. But that is probably a whole new project by itself.

You can access the code on GitHub here.

Photo credit: Screenshot/playsnake.org

 

Credit: Google News

Previous Post

B2B Buyers' Top Challenges With Vendors

Next Post

Seek apologises for 'internal technical issue' that exposed user details

Related Posts

Machine Learning Helps Optimize Therapeutic Antibodies
Machine Learning

Machine Learning Helps Optimize Therapeutic Antibodies

April 18, 2021
Researchers at MIT DAI Lab Have Recently Built Cardea: A Machine Learning Framework That Turns Health Care Data Into Insights
Machine Learning

Researchers at MIT DAI Lab Have Recently Built Cardea: A Machine Learning Framework That Turns Health Care Data Into Insights

April 18, 2021
Automating Drug Discovery With Machine Learning
Machine Learning

Automating Drug Discovery With Machine Learning

April 18, 2021
Twitter aims to fight bias by examining its own machine learning algorithms
Machine Learning

Twitter aims to fight bias by examining its own machine learning algorithms

April 18, 2021
Make Machine Learning Interpretable with Shapash
Machine Learning

Make Machine Learning Interpretable with Shapash

April 18, 2021
Next Post
It’s time to say goodbye to the EU-US Privacy Shield

Seek apologises for 'internal technical issue' that exposed user details

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

Recommended

Plasticity in Deep Learning: Dynamic Adaptations for AI Self-Driving Cars

Plasticity in Deep Learning: Dynamic Adaptations for AI Self-Driving Cars

January 6, 2019
Microsoft, Google Use Artificial Intelligence to Fight Hackers

Microsoft, Google Use Artificial Intelligence to Fight Hackers

January 6, 2019

Categories

  • Artificial Intelligence
  • Big Data
  • Blockchain
  • Crypto News
  • Data Science
  • Digital Marketing
  • Internet Privacy
  • Internet Security
  • Learn to Code
  • Machine Learning
  • Marketing Technology
  • Neural Networks
  • Technology Companies

Don't miss it

Machine Learning Helps Optimize Therapeutic Antibodies
Machine Learning

Machine Learning Helps Optimize Therapeutic Antibodies

April 18, 2021
Researchers at MIT DAI Lab Have Recently Built Cardea: A Machine Learning Framework That Turns Health Care Data Into Insights
Machine Learning

Researchers at MIT DAI Lab Have Recently Built Cardea: A Machine Learning Framework That Turns Health Care Data Into Insights

April 18, 2021
Automating Drug Discovery With Machine Learning
Machine Learning

Automating Drug Discovery With Machine Learning

April 18, 2021
Twitter aims to fight bias by examining its own machine learning algorithms
Machine Learning

Twitter aims to fight bias by examining its own machine learning algorithms

April 18, 2021
Make Machine Learning Interpretable with Shapash
Machine Learning

Make Machine Learning Interpretable with Shapash

April 18, 2021
Why the Patent Classification System Needs an Update
Machine Learning

Why the Patent Classification System Needs an Update

April 18, 2021
NikolaNews

NikolaNews.com is an online News Portal which aims to share news about blockchain, AI, Big Data, and Data Privacy and more!

What’s New Here?

  • Machine Learning Helps Optimize Therapeutic Antibodies April 18, 2021
  • Researchers at MIT DAI Lab Have Recently Built Cardea: A Machine Learning Framework That Turns Health Care Data Into Insights April 18, 2021
  • Automating Drug Discovery With Machine Learning April 18, 2021
  • Twitter aims to fight bias by examining its own machine learning algorithms April 18, 2021

Subscribe to get more!

© 2019 NikolaNews.com - Global Tech Updates

No Result
View All Result
  • AI Development
    • Artificial Intelligence
    • Machine Learning
    • Neural Networks
    • Learn to Code
  • Data
    • Blockchain
    • Big Data
    • Data Science
  • IT Security
    • Internet Privacy
    • Internet Security
  • Marketing
    • Digital Marketing
    • Marketing Technology
  • Technology Companies
  • Crypto News

© 2019 NikolaNews.com - Global Tech Updates