- During deployment in the Studio (e.g. “WARN: This model contains ops that require flex delegates (FlexErf). You will need to install the flex delegates shared library to run this model.”).
- When running a model using the Linux CLI (e.g. “error while loading shared libraries: libtensorflowlite_flex_2.16.1.so. You will need to install the flex delegates shared library to run this model.”).
Installing the flex delegate library
To install the flex delegate library:- Download the shared library for your target architecture and operating system:
- macOS x86 (also runs on M1/M2 using Rosetta)
- Linux armv7 (most 32-bits Arm-based Linux systems, e.g. Raspberry Pi 4 running 32-bits Raspbian)
- Linux aarch64 (most 64-bits Arm-based Linux systems, e.g. Jetson Nano)
- Linux x86_64 (Intel/AMD based Linux systems)
- Place the
libtensorflowlite_flex_2.16.1.so
(or.dylib
on macOS) file in/usr/lib
or/usr/local/lib
.
Linking the flex delegate library using the C++ SDK
If your model has flex ops, and you’re building using the Linux C++ SDK, then pass theLINK_TFLITE_FLEX_LIBRARY=1
flag when building the application.
When using the Node.js, Go or Python SDK then the .eim file already has the flex delegates library linked in.