A Hardware Descriptive Approach to Beetle Antennae Search

Zongcheng Yue, Gang Li, Xiangyuan Jiang, Shuai Li, Jian Cheng, Peng RenIEEE Access 2020 · OpenReview

Abstract

Beetle antennae search (BAS) is a newly developed meta-heuristic algorithm which is effectively used for optimizing objective functions of complex forms or even unknown forms. The common practice for implementing meta-heuristic algorithms including the BAS largely relies on programming in a high-level language and executing the code on a computer platform. However, the high-level implementation of the BAS algorithm hinders it from being used in an embedding system, where real-time operations are normally required. To address this limitation, we present an approach to implementing the BAS algorithm on a field-programmable gate array (FPGA). Specifically, we program the BAS function in the Verilog hardware description language (HDL), which provides a tractable vehicle for implementing the BAS algorithm at the gate level on the FPGA chip. We simulate our Verilog HDL based BAS module with the Modelsim platform. Simulation results validate the feasibility of our proposed Verilog HDL implementation of the BAS. Additionally, we implement the BAS model on the Zynq XC7Z010 platform, with 132.5 µs latency for model implementation.

Introduction

Meta-heuristic algorithms, such as Genetic Algorithms or Particle Swarm Optimization, are nature-inspired techniques widely used for solving complex optimization problems. Traditionally, these algorithms are implemented in high-level software environments like MATLAB or Python. While flexible, this software-centric approach introduces significant latency, making it unsuitable for real-time embedded systems—such as autonomous drones or high-speed industrial controllers—that require deterministic, microsecond-level responses.

This paper proposes a hardware-level implementation of the Beetle Antennae Search (BAS) algorithm. By porting the algorithm to a Field-Programmable Gate Array (FPGA) using Verilog Hardware Description Language (HDL), the research achieves the massive parallelism and low latency necessary for edge-computing applications.

The Beetle Antennae Search Algorithm

The BAS algorithm mimics the foraging behavior of longhorn beetles. A beetle uses its two antennae to sense the intensity of an odor (the objective function). By comparing the "odor" strength at each antenna, the beetle adjusts its movement direction toward the source.

The biological logic of Beetle Antennae Search (BAS) across multiple cycles.

In the hardware implementation, this logic is translated into Register Transfer Level (RTL) descriptions. Unlike software where calculations are sequential, the FPGA allows the left and right antennae modules to process information simultaneously, more accurately reflecting the biological process.

Hardware Implementation Strategy

To optimize the BAS for silicon, several architectural choices were made:

1. Fixed-Point Arithmetic

To avoid the high resource cost of floating-point units, the design utilizes fixed-point math with a "shift-and-round" strategy (8 fractional bits). This approach maintains sufficient accuracy—showing only a ~2% error compared to theoretical models—while significantly reducing circuit complexity and power consumption.

2. Pseudo-Random Number Generation

FPGAs lack a native random function. To generate the stochastic search vectors required by BAS, the authors implemented Linear Feedback Shift Registers (LFSRs).

Hardware implementation of a Linear Feedback Shift Register (LFSR) for pseudo-random number generation.

A "twin model" using two LFSRs with different seeds was employed to generate independent 2D coordinates for the search vectors.

3. Modular RTL Design

The system is partitioned into specialized hardware modules, including a Random Number Generator, Antennae Modules to calculate objective function values, and a Position Module to update the beetle's coordinates based on the gradient.

Experimental Results

The implementation was tested on the Zynq XC7Z010 platform using the Booth function, a standard non-linear benchmark for optimization.

  • Latency: The hardware implementation achieved a total optimization latency of 132.5 µs, orders of magnitude faster than typical software executions.
  • Resource Efficiency: The design is remarkably lightweight, utilizing only 4.98% of available Lookup Tables (LUTs) and 15% of Digital Signal Processors (DSPs).
  • Power: Total power consumption was measured at approximately 1.64W at a 100MHz clock frequency.

Conclusion

This work demonstrates that the BAS algorithm can be effectively implemented at the hardware level, providing a high-performance alternative to software-based optimization. While currently limited to 2D space, the low resource footprint and microsecond-level latency suggest that FPGA-based BAS is a viable candidate for real-time control in complex embedded environments. Future work will focus on expanding the architecture to handle higher-dimensional optimization problems.

Summary updated

Abstract

Beetle antennae search (BAS) is a newly developed meta-heuristic algorithm which is effectively used for optimizing objective functions of complex forms or even unknown forms. The common practice for implementing meta-heuristic algorithms including the BAS largely relies on programming in a high-level language and executing the code on a computer platform. However, the high-level implementation of the BAS algorithm hinders it from being used in an embedding system, where real-time operations are normally required. To address this limitation, we present an approach to implementing the BAS algorithm on a field-programmable gate array (FPGA). Specifically, we program the BAS function in the Verilog hardware description language (HDL), which provides a tractable vehicle for implementing the BAS algorithm at the gate level on the FPGA chip. We simulate our Verilog HDL based BAS module with the Modelsim platform. Simulation results validate the feasibility of our proposed Verilog HDL implementation of the BAS. Additionally, we implement the BAS model on the Zynq XC7Z010 platform, with <inline-formula xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink"> <tex-math notation="LaTeX">$132.5~\mu $ </tex-math></inline-formula> s latency for model implementation.
BibTeX
@inproceedings{yue2020hardware,
  author = {Zongcheng Yue and Gang Li and Xiangyuan Jiang and Shuai Li and Jian Cheng and Peng Ren},
  title = {{A Hardware Descriptive Approach to Beetle Antennae Search}},
  booktitle = {IEEE Access},
  year = {2020},
  url = {https://openreview.net/forum?id=FA84LsV9OJ},
}
Figure