Errors with tflite-model-maker

Hi i am very new to all this.
i was trying a colab notebook to train a small model to use it with my raspberry pi and usb coral device with just one class

i am using an miniconda enviroment with python 3.9 in the colab (colab moved to python 3.10 )

cell

!conda create -n myenv python=3.9

cell

%%shell
eval "$(conda shell.bash hook)"
conda activate myenv
pip install -q tflite-model-maker
pip install -q tflite-support

cell to run python file

%%shell
eval "$(conda shell.bash hook)"
conda activate myenv
python run.py

Python file

import numpy as np
import os

from tflite_model_maker.config import ExportFormat, QuantizationConfig
from tflite_model_maker import model_spec
from tflite_model_maker import object_detector

from tflite_support import metadata

import tensorflow as tf
assert tf.__version__.startswith('2')

tf.get_logger().setLevel('ERROR')
from absl import logging
logging.set_verbosity(logging.ERROR)

I am getting an error when i am reaching in the lines to import “from tflite_model_maker”

2024-02-05 18:19:44.601931: W tensorflow/stream_executor/platform/default/dso_loader.cc:64] Could not load dynamic library ‘libcudart.so.11.0’; dlerror: libcudart.so.11.0: cannot open shared object file: No such file or directory; LD_LIBRARY_PATH: /usr/lib64-nvidia
2024-02-05 18:19:44.601968: I tensorflow/stream_executor/cuda/cudart_stub.cc:29] Ignore above cudart dlerror if you do not have a GPU set up on your machine.
/usr/local/envs/myenv/lib/python3.9/site-packages/tensorflow_addons/utils/tfa_eol_msg.py:23: UserWarning:

TensorFlow Addons (TFA) has ended development and introduction of new features.
TFA has entered a minimal maintenance and release mode until a planned end of life in May 2024.
Please modify downstream libraries to take dependencies from other repositories in our TensorFlow community (e.g. Keras, Keras-CV, and Keras-NLP).

For more information see: TensorFlow Addons Wind Down · Issue #2807 · tensorflow/addons · GitHub

warnings.warn(
/usr/local/envs/myenv/lib/python3.9/site-packages/tensorflow_addons/utils/ensure_tf_install.py:53: UserWarning: Tensorflow Addons supports using Python ops for all Tensorflow versions above or equal to 2.13.0 and strictly below 2.16.0 (nightly versions are not supported).
The versions of TensorFlow you are currently using is 2.8.4 and is not supported.
Some things might work, some things might not.
If you were to encounter a bug, do not file an issue.
If you want to make sure you’re using a tested and supported configuration, either change the TensorFlow version or the TensorFlow Addons’s version.
You can find the compatibility matrix in TensorFlow Addon’s readme:

ModuleNotFoundError: No module named ‘ipykernel’


CalledProcessError Traceback (most recent call last)

in <cell line: 1>()
----> 1 get_ipython().run_cell_magic(‘shell’, ‘’, ‘eval “$(conda shell.bash hook)”\nconda activate myenv\npython run.py\n\n\n#import numpy as np\n#import os\n\n#from tflite_model_maker.config import ExportFormat, QuantizationConfig\n#from tflite_model_maker import model_spec\n#from tflite_model_maker import object_detector\n\n#from tflite_support import metadata\n\n#import tensorflow as tf\n#assert tf.version.startswith('2')\n\n#tf.get_logger().setLevel('ERROR')\n#from absl import logging\n#logging.set_verbosity(logging.ERROR)\n’)

3 frames

/usr/local/lib/python3.10/dist-packages/google/colab/_system_commands.py in check_returncode(self)
135 def check_returncode(self):
136 if self.returncode:
→ 137 raise subprocess.CalledProcessError(
138 returncode=self.returncode, cmd=self.args, output=self.output
139 )

CalledProcessError: Command 'eval “$(conda shell.bash hook)”

i tried to change versions of tflite-model-maker but other compatibility errors appearing
so all the examples are with TFA , that is no more supported should i try to import Keras
are any examples to look ?

thanks in advance

Ok i find the main problem… it was the type of pictures i was using. i had to format them in order to stop having the errors

but still i have question about the warnings :

TFA has entered a minimal maintenance and release mode until a planned end of life in May 2024.
Please modify downstream libraries to take dependencies from other repositories in our TensorFlow community

is something that i have to modified by me ? i am little confused