I am not having the error but when I run the below line its continuously showing that kernel appears to dead. It will restart automatically.
I am having the python 3.7.10 and tensorflow 2.4.0 installed.
The error is showing when I run the below line of code.
from imageai.Detection.Custom import DetectionModelTrainer
I tried every solution which is mentioned on google but unable to solve.
Thanks is advance.
There could be the problem with supported package version mismatch in the anaconda environment. You can try by restarting the kernel after sometime or can rectify this error by creating a new environment and install the
TensorFlow
and other required packages again on that.Create a new environment for
TensorFlow
using the code below:and insatll
TensorFlow
:You need to open the
JUPYTER notebook
in the same environment by selecting the"tf2"
and try importingTensorFlow
:if there is no error -
TensorFlow
installed successfully.Now, you can install any reuired package using
!pip install package_name
inJupyter Notebook
, as in this case:Also check this link as a reference for using imageai