News Report Technology
June 20, 2023

DeepMind’s AlphaZero Learns Efficient Sorting Algorithms in Neural Network Optimization

DeepMind has once again made an advancement in the machine learning. Following their success in using reinforcement learning (RL) to teach AlphaZero more efficient matrix multiplication algorithms, they have now turned their attention to sorting algorithms, with promising results.

DeepMind's AlphaZero Learns Efficient Sorting Algorithms in Neural Network Optimization
deepmind.com

Sorting is a fundamental operation used in numerous computer programs. The efficiency of sorting arrays, performing the task in the fewest operations possible, holds great importance. Traditionally, researchers have devised various efficient sorting algorithms for different scenarios based on array sizes and data characteristics. However, DeepMind decided to explore a novel approach: teaching a neural network to solve this problem.

To accomplish this, DeepMind introduced the task of sorting an array as a game to AlphaZero. Through RL techniques, they trained AlphaZero to play this sorting game. The resulting model, known as AlphaDev, showcased remarkable capabilities in learning efficient sorting algorithms.

The sorting game operates by representing the environment’s state as a pair, where P denotes the current sorting algorithm generated in assembly language, and Z represents the state of memory and registers. At each time step, the AlphaZero agent takes the current state as input and performs an action, which involves adding a new instruction to the assembler language algorithm, such as mov.

Step by step, AlphaZero constructs the final sorting algorithm in assembly language. The model’s reward at each step is determined by two factors: the correctness of the algorithm obtained and its latency. Correctness is evaluated based on predefined input-output pairs, where the input represents an unsorted array, and the output represents the same array but sorted.

The process of generating the sorting algorithm continues for a predetermined number of steps. If a final working algorithm is not obtained within this timeframe, the generation process starts anew.

The trained model was tasked with producing sorting algorithms for sequences of length 3, 4, and 5. It’s worth noting that there are two types of sorting algorithms: fixed sort, which sorts arrays of a specific length, and variable sort, which can handle arrays of different lengths. In both cases, AlphaZero surpassed existing algorithms commonly used in programs. AlphaZero achieved improvements in sorting arrays of length 3 and 5 for fixed sort, and it discovered an intriguing approach to sort arrays of length 4 for variable sort.

For a more comprehensive understanding of the sorting algorithms discovered by AlphaDev, refer to the Nature article titled “AlphaDev: AlphaZero’s Journey into Efficient Sorting Algorithms”.

Read more about AI:

Disclaimer

In line with the Trust Project guidelines, please note that the information provided on this page is not intended to be and should not be interpreted as legal, tax, investment, financial, or any other form of advice. It is important to only invest what you can afford to lose and to seek independent financial advice if you have any doubts. For further information, we suggest referring to the terms and conditions as well as the help and support pages provided by the issuer or advertiser. MetaversePost is committed to accurate, unbiased reporting, but market conditions are subject to change without notice.

About The Author

Damir is the team leader, product manager, and editor at Metaverse Post, covering topics such as AI/ML, AGI, LLMs, Metaverse, and Web3-related fields. His articles attract a massive audience of over a million users every month. He appears to be an expert with 10 years of experience in SEO and digital marketing. Damir has been mentioned in Mashable, Wired, Cointelegraph, The New Yorker, Inside.com, Entrepreneur, BeInCrypto, and other publications. He travels between the UAE, Turkey, Russia, and the CIS as a digital nomad. Damir earned a bachelor's degree in physics, which he believes has given him the critical thinking skills needed to be successful in the ever-changing landscape of the internet. 

More articles
Damir Yalalov
Damir Yalalov

Damir is the team leader, product manager, and editor at Metaverse Post, covering topics such as AI/ML, AGI, LLMs, Metaverse, and Web3-related fields. His articles attract a massive audience of over a million users every month. He appears to be an expert with 10 years of experience in SEO and digital marketing. Damir has been mentioned in Mashable, Wired, Cointelegraph, The New Yorker, Inside.com, Entrepreneur, BeInCrypto, and other publications. He travels between the UAE, Turkey, Russia, and the CIS as a digital nomad. Damir earned a bachelor's degree in physics, which he believes has given him the critical thinking skills needed to be successful in the ever-changing landscape of the internet. 

NFTs & Mining: A Digital Synergy

The rise in usage of the non-fungible tokens has changed the way we see and engage with ...

Know More

AI in Crypto

Explore the ever-evolving realm of artificial intelligence within the cryptocurrency sphere. Discover the transformative impact of AI ...

Know More
Join Our Innovative Tech Community
Read More
Read more
Figure Raises $675M Funding for Humanoid Robot Development, Collaborates with OpenAI for AI Model Research
Business News Report
Figure Raises $675M Funding for Humanoid Robot Development, Collaborates with OpenAI for AI Model Research
February 29, 2024
Telegram Plans to Sell TON at Discount to Long-Term Investors, Limiting Token Holdings to 10%
News Report Technology
Telegram Plans to Sell TON at Discount to Long-Term Investors, Limiting Token Holdings to 10%
February 29, 2024
FTX-Linked Crypto Hedge Fund Rebrands to MNNC Group, Attracts “Mid-Eight-Figure” Investment Post-FTX Collapse
Business News Report
FTX-Linked Crypto Hedge Fund Rebrands to MNNC Group, Attracts “Mid-Eight-Figure” Investment Post-FTX Collapse
February 29, 2024
Silence Laboratories Raises $4.1M Funding to  Protect Enterprise Data with Cryptographic Multiparty Computation 
Business News Report
Silence Laboratories Raises $4.1M Funding to Protect Enterprise Data with Cryptographic Multiparty Computation 
February 29, 2024
What You
Need to Know

Subscribe To Our Newsletter.
Daily search marketing tidbits for savvy pros.