FINN Framework…NN to IP
No doubt more capabilites were added for designers after the release of this framework. But the question is “Is it worth?” Indeed
FINN Framework…NN to IP
Human being is now witnessing a revolution in technology based on the big development in AI algorithms. Developers are competing in implementing Neural Networks using different approaches serving different applications. Starting from the single layer perceptron passing with YOLO and ending up with transformers and LLMs, no one can now predict how far this technology would reach.
Nevertheless, these stuff is computational hungry with a high need for high throughput devices to do the inference. People mostly depend on GPUs for this task but the question is “ Is it affordable for all projects?”. The answer is simply NO. Deploying these heavy networks on any platform carrying this enormous number of weights and activations represented in the 16- and 32-bit floating bit precesion won’t be always your best choice to run your network inference.
That said, quantization algorithms were used to scale down the network to lower precisions hence, one would get smaller needed memory. But why not to imagine of creating a dedicated IP for neural networks instead of the legacy counting on GPUs. Having a portable chip for AI inference and excluding off-chip memories would definitely reveal a new era of technology.
FINN came to rescue!
However, this dream has become no more imagination. FINN framework, introduced by Xilinx Research Lab, is introduced to do this task. This open-source framework is responsible for the conversion of the Neural Network into synthesisable hardware layers that can be whether used as a standalone project or even integrated into more complex projects.
Nevertheless, like most of the approaches for accelerating AI, this framework has some limitations. Hardware unfriendly functions and operations such as sigmoid and tensor transpose aren’t yet ready to be converted into logic cells. But don’t be upset, these operations can still be implemented on your CPU with leaving the core computations for your hardware accelerator.

More in deep…Docker Installation
If you came interested for the challenge, let’s move forward to the installation steps. If you didn’t, feel free to scroll down to the end of the article to see the magic results then return back to here to complete your installation😜
FINN is supported by Linux-based OS. Ubuntu 22.04 LTS is recommended.
For properly installing the framework, you should have docker running on your system without root. Hence, the first step is to remove the old versions of docker from your device.
$ for pkg in docker.io docker-doc docker-compose docker-compose-v2 podman-docker containerd runc; do sudo apt-get remove $pkg; done
Having this done, you are now required to install the up-to-date docker version.
$ # Add Docker's official GPG key:
sudo apt-get update
sudo apt-get install ca-certificates curl
sudo install -m 0755 -d /etc/apt/keyrings
sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc
sudo chmod a+r /etc/apt/keyrings/docker.asc
# Add the repository to Apt sources:
echo \
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/ubuntu \
$(. /etc/os-release && echo "${UBUNTU_CODENAME:-$VERSION_CODENAME}") stable" | \
sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
sudo apt-get update
$ sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
If you aren’t sure if you have successfully installed docker or not, no worries. The next line gives you a hello world test. If you had the output saying hello from docker, then congratulations you have completed this step.
$ sudo docker run hello-world
The next step is to run docker without root for the proper run of the framework. This is pretty easy using the following commands.
$sudo groupadd docker
#Replace the $USER with your username on the system
$sudo usermod -aG docker $USER
$ newgrp docker
#run hello world again
$docker run hello-world
Installing FINN
Once you have installed the docker without root, you are now ready for installing FINN. FINN source code is provided on their github repository. And as most of the open source projects, to run the framework you have firstly to clone the repo.
git clone https://github.com/Xilinx/finn/

Content to be found in the finn directory after cloning
Before running your first project, there are some important steps left. FINN is a framework that targets Xilinx FPGAs. Hence, it is important to provide some paths as environment variables in order to work properly. These variables are Xilinx tools installation directory (e.g. /tools/Xilinx), Vivado package version (e.g. 2022.2) and if you are targetting non-webpack boards you have to provide your license path.
Now you are ready!
Running FINN
Everything is ready now to run. What you need now is to type the following command in a terminal opened in the finn directory so that you can get a link for the framework Jupyter Notebook.
./run-docker.sh notebook

FINN Jupyter Notebook View
FINN provides a notebook server to facilitate the interaction between the user and the built-in functions. Additionally, you can explore the provided folders for having introductory examples for the framework.
More Details about the flow

FINN typical flow
The previous flowchart shows the typical flow for building your project using FINN. Some notes should be considered:
1-Streamlining and Hardware Conversion Stages
This stage serves its following stage by converting the network layers into hardware friendly operations. However, some complex networks may still have unconvertable layers. Don’t worry! In the Hardware conversion stage only the convertable layers are implemented in the Programmable Logic (PL) Side of the FPGA and other operations are left for the user to implement using software or any desired custom logic.
Also, for some operations, the user is free to choose from two flavors (HLS/RTL) for the HW conversion process.
2-The output drivers
FINN provides both python and C++ drivers. The purpose is to facilitate the flow for those who are intending to apply HW/SW Co-design flow on their project. Hence, they can communicate with the generated IP using these drivers. For those who aren’t familiar with the Co-design concept, you can review my previous article from here.
How far can you reach from this?
No doubt more capabilites were added for designers after the release of this framework. But the question is “Is it worth?”
Indeed, the answer is yess. By making use of this framework, you can convert your neural network into completely pure-hardware system. Aren’t you convinced yet?🤔
In this paper, you can find an evidence for my claim. Our work demonstrating a novel implementation for the YOLO network through having pure hardware YOLO inference depending only on the PL Side of the board. You can also find a practical explanation for the project on its github repository as well as the code (under MIT License) and more practical notes.

Snippet from the Repository
Article References
[1] https://github.com/Xilinx/finn/blob/main/docs/finn/getting_started.rst
[2] https://docs.docker.com/engine/install/ubuntu/
[4] https://github.com/m7md5303/pure-hardware-YOLO-inference
메타데이터
- post_id
- dc88df882a5b
- slug
- finn-framework-nn-to-ip-dc88df882a5b
- url
- https://medium.com/@m7md5303/finn-framework-nn-to-ip-dc88df882a5b
- canonical_url
- https://medium.com/@m7md5303/finn-framework-nn-to-ip-dc88df882a5b
- author_url
- https://medium.com/@m7md5303
- status
- ok
- fetched_at
- 2026-06-23 17:05:31