Combining Multi-Objective Bayesian Optimization with Reinforcement Learning for TinyML

2305.14109

YC

0

Reddit

0

Published 6/7/2024 by Mark Deutel, Georgios Kontes, Christopher Mutschler, Jurgen Teich

🛠️

Abstract

Deploying Deep Neural Networks (DNNs) on microcontrollers (TinyML) is a common trend to process the increasing amount of sensor data generated at the edge, but in practice, resource and latency constraints make it difficult to find optimal DNN candidates. Neural Architecture Search (NAS) is an excellent approach to automate this search and can easily be combined with DNN compression techniques commonly used in TinyML. However, many NAS techniques are not only computationally expensive, especially hyperparameter optimization (HPO), but also often focus on optimizing only a single objective, e.g., maximizing accuracy, without considering additional objectives such as memory consumption or computational complexity of a DNN, which are key to making deployment at the edge feasible. In this paper, we propose a novel NAS strategy for TinyML based on Multi-Objective Bayesian optimization (MOBOpt) and an ensemble of competing parametric policies trained using Augmented Random Search (ARS) Reinforcement Learning (RL) agents. Our methodology aims at efficiently finding tradeoffs between a DNN's predictive accuracy, memory consumption on a given target system, and computational complexity. Our experiments show that we outperform existing MOBOpt approaches consistently on different data sets and architectures such as ResNet-18 and MobileNetV3.

Create account to get full access

or

If you already have an account, we'll log you in

Overview

  • Deploying deep neural networks (DNNs) on microcontrollers, known as TinyML, is a common way to process the increasing amount of sensor data generated at the edge.
  • However, resource and latency constraints make it challenging to find optimal DNN candidates for deployment.
  • Neural Architecture Search (NAS) is a promising approach to automate this search, and it can be combined with DNN compression techniques commonly used in TinyML.
  • Many NAS techniques, including hyperparameter optimization (HPO), are computationally expensive and often focus on optimizing a single objective, such as maximizing accuracy, without considering other key factors for edge deployment like memory consumption or computational complexity.

Plain English Explanation

Deep neural networks (DNNs) are a type of powerful machine learning model that can be used to process large amounts of sensor data. As the amount of data generated at the "edge" (i.e., on small devices like microcontrollers) continues to grow, there is a need to deploy these DNNs directly on these microcontrollers, in a field known as TinyML.

However, the limited resources (memory, processing power) and tight latency requirements of microcontrollers make it challenging to find the best DNN models to use. Neural Architecture Search (NAS) is a technique that can help automate the process of finding the optimal DNN model for a given task and hardware. NAS can be combined with other techniques, like model compression, that are commonly used in TinyML.

Many NAS techniques, though, have their own challenges. They can be computationally expensive, especially when it comes to optimizing the hyperparameters of the DNN model. Also, a lot of NAS approaches focus only on optimizing a single factor, like the model's accuracy, without considering other important factors for edge deployment, such as the model's memory usage or computational complexity.

Technical Explanation

In this paper, the researchers propose a novel NAS strategy for TinyML that uses Multi-Objective Bayesian Optimization (MOBOpt) and an ensemble of competing Augmented Random Search (ARS) Reinforcement Learning (RL) agents. The goal is to efficiently find a balance between a DNN's predictive accuracy, memory consumption on the target system, and computational complexity.

The researchers' methodology aims to address the limitations of existing NAS techniques by jointly optimizing multiple objectives, rather than just focusing on a single factor like accuracy. This multi-objective approach allows them to identify DNN models that provide a good trade-off between performance, memory usage, and computational efficiency - all key requirements for successful deployment on microcontrollers in the context of TinyML.

The experiments show that the researchers' approach outperforms existing MOBOpt methods consistently on different datasets and architectures, including ResNet-18 and MobileNetV3.

Critical Analysis

The paper presents a promising approach to NAS for TinyML applications, addressing the limitations of existing techniques by considering multiple objectives beyond just accuracy. However, the researchers acknowledge that their method is still computationally expensive, especially when it comes to the HPO step.

Additionally, the paper does not provide a detailed analysis of the specific trade-offs between the different objectives (accuracy, memory, and computational complexity) or how these trade-offs might vary across different datasets and hardware constraints. Further research could explore these trade-offs in more depth and provide guidance on how to best balance the competing objectives for different real-world TinyML use cases.

Conclusion

This paper introduces a novel NAS strategy for TinyML that uses multi-objective Bayesian optimization and reinforcement learning to efficiently find DNN models that balance predictive accuracy, memory consumption, and computational complexity - all crucial factors for successful deployment on microcontrollers. The researchers' approach outperforms existing multi-objective NAS methods, demonstrating the value of jointly optimizing multiple objectives when searching for optimal DNN architectures for edge computing applications.



This summary was produced with help from an AI and may contain inaccuracies - check out the links to read the original source documents!

Related Papers

Multi-objective Differentiable Neural Architecture Search

Multi-objective Differentiable Neural Architecture Search

Rhea Sanjay Sukthanker, Arber Zela, Benedikt Staffler, Samuel Dooley, Josif Grabocka, Frank Hutter

YC

0

Reddit

0

Pareto front profiling in multi-objective optimization (MOO), i.e. finding a diverse set of Pareto optimal solutions, is challenging, especially with expensive objectives like neural network training. Typically, in MOO neural architecture search (NAS), we aim to balance performance and hardware metrics across devices. Prior NAS approaches simplify this task by incorporating hardware constraints into the objective function, but profiling the Pareto front necessitates a computationally expensive search for each constraint. In this work, we propose a novel NAS algorithm that encodes user preferences for the trade-off between performance and hardware metrics, and yields representative and diverse architectures across multiple devices in just one search run. To this end, we parameterize the joint architectural distribution across devices and multiple objectives via a hypernetwork that can be conditioned on hardware features and preference vectors, enabling zero-shot transferability to new devices. Extensive experiments with up to 19 hardware devices and 3 objectives showcase the effectiveness and scalability of our method. Finally, we show that, without extra costs, our method outperforms existing MOO NAS methods across a broad range of qualitatively different search spaces and datasets, including MobileNetV3 on ImageNet-1k, an encoder-decoder transformer space for machine translation and a decoder-only transformer space for language modelling.

Read more

6/21/2024

Multi-objective Neural Architecture Search by Learning Search Space Partitions

Multi-objective Neural Architecture Search by Learning Search Space Partitions

Yiyang Zhao, Linnan Wang, Tian Guo

YC

0

Reddit

0

Deploying deep learning models requires taking into consideration neural network metrics such as model size, inference latency, and #FLOPs, aside from inference accuracy. This results in deep learning model designers leveraging multi-objective optimization to design effective deep neural networks in multiple criteria. However, applying multi-objective optimizations to neural architecture search (NAS) is nontrivial because NAS tasks usually have a huge search space, along with a non-negligible searching cost. This requires effective multi-objective search algorithms to alleviate the GPU costs. In this work, we implement a novel multi-objectives optimizer based on a recently proposed meta-algorithm called LaMOO on NAS tasks. In a nutshell, LaMOO speedups the search process by learning a model from observed samples to partition the search space and then focusing on promising regions likely to contain a subset of the Pareto frontier. Using LaMOO, we observe an improvement of more than 200% sample efficiency compared to Bayesian optimization and evolutionary-based multi-objective optimizers on different NAS datasets. For example, when combined with LaMOO, qEHVI achieves a 225% improvement in sample efficiency compared to using qEHVI alone in NasBench201. For real-world tasks, LaMOO achieves 97.36% accuracy with only 1.62M #Params on CIFAR10 in only 600 search samples. On ImageNet, our large model reaches 80.4% top-1 accuracy with only 522M #FLOPs.

Read more

6/4/2024

Multi-Objective Neural Architecture Search for In-Memory Computing

Multi-Objective Neural Architecture Search for In-Memory Computing

Md Hasibul Amin, Mohammadreza Mohammadi, Ramtin Zand

YC

0

Reddit

0

In this work, we employ neural architecture search (NAS) to enhance the efficiency of deploying diverse machine learning (ML) tasks on in-memory computing (IMC) architectures. Initially, we design three fundamental components inspired by the convolutional layers found in VGG and ResNet models. Subsequently, we utilize Bayesian optimization to construct a convolutional neural network (CNN) model with adaptable depths, employing these components. Through the Bayesian search algorithm, we explore a vast search space comprising over 640 million network configurations to identify the optimal solution, considering various multi-objective cost functions like accuracy/latency and accuracy/energy. Our evaluation of this NAS approach for IMC architecture deployment spans three distinct image classification datasets, demonstrating the effectiveness of our method in achieving a balanced solution characterized by high accuracy and reduced latency and energy consumption.

Read more

6/12/2024

Towards Leveraging AutoML for Sustainable Deep Learning: A Multi-Objective HPO Approach on Deep Shift Neural Networks

Towards Leveraging AutoML for Sustainable Deep Learning: A Multi-Objective HPO Approach on Deep Shift Neural Networks

Leona Hennig, Tanja Tornede, Marius Lindauer

YC

0

Reddit

0

Deep Learning (DL) has advanced various fields by extracting complex patterns from large datasets. However, the computational demands of DL models pose environmental and resource challenges. Deep shift neural networks (DSNNs) offer a solution by leveraging shift operations to reduce computational complexity at inference. Following the insights from standard DNNs, we are interested in leveraging the full potential of DSNNs by means of AutoML techniques. We study the impact of hyperparameter optimization (HPO) to maximize DSNN performance while minimizing resource consumption. Since this combines multi-objective (MO) optimization with accuracy and energy consumption as potentially complementary objectives, we propose to combine state-of-the-art multi-fidelity (MF) HPO with multi-objective optimization. Experimental results demonstrate the effectiveness of our approach, resulting in models with over 80% in accuracy and low computational cost. Overall, our method accelerates efficient model development while enabling sustainable AI applications.

Read more

4/5/2024