Cannot install edgetpu_compiler on raspberry pi - python

I want to use a custom model on a raspberry pi using Google Coral accelerator. I trained the quantized mobilenet-ssd model on my dataset and I have the tflite file and the label txt file. Now I need to use edgetpu_compiler so the tflite file will be optimized for the Google Coral accelerator. The problem is that I can't install it. This is what I get (I followed these instructions: https://coral.ai/docs/edgetpu/compiler/):
pi#raspberrypi:~/Desktop/project/mobilenet_ssd_v2 $ sudo apt-get
install edgetpu Reading package lists... Done Building dependency tree
Reading state information... Done Some packages could not be
installed. This may mean that you have requested an impossible
situation or if you are using the unstable distribution that some
required packages have not yet been created or been moved out of
Incoming. The following information may help to resolve the situation:
The following packages have unmet dependencies: edgetpu : Depends:
edgetpu-compiler but it is not installable E: Unable to correct
problems, you have held broken packages.
Even when I try to specifically install edgetpu-compiler, it doesn't work:
pi#raspberrypi:~/Desktop/project/mobilenet_ssd_v2 $ sudo apt-get
install edgetpu-compiler Reading package lists... Done Building
dependency tree Reading state information... Done Package
edgetpu-compiler is not available, but is referred to by another
package. This may mean that the package is missing, has been
obsoleted, or is only available from another source
E: Package 'edgetpu-compiler' has no installation candidate
Any idea how to solve this? Or is there another way to compile the tflite file?

This is because the edgetpu compiler is not supported for 32 bits OS, unfortunately. This used to be supported, but coral has moved onto only supporting 64 bits architecture. You can see the requirements here

Related

Error when trying to install Lazypredict, problem with lightgbm

I'm trying to install Lazypredict, an autoML python library, on macOS 10.14.6.
Thus, I simply run
"pip install lazypredict" in the terminal , it wants to install lightgbm, but always fails to do so. I think it tries to install lightgbm through pip although I have already installed it with brew (as recommendend).
Hence i get such errors and really don't know what to do. I already have CMake installed too
Do you have ideas of what could enable me to install lazypredict ?
PS: Same happenned with other auto ML packages such as PyCaret
The errors I get are the following:
ERROR: Failed building wheel for lightgbm
Running setup.py clean for lightgbm
Failed to build lightgbm
Installing collected packages: lightgbm
Running setup.py install for lightgbm ... error
ERROR: Command errored out with exit status 1:
Exception: Please install CMake and all required dependencies first
SOLUTION 1 (Recommended)
LazyPredict works with specific versions of other libraries, I recommend you to work with Google Colab or Kaggle Notebook. They create a separate environment having multiple versions of other libraries, when you install lazypredict on colad or kaggle you won't face any issues.
One more reason to use lazypredict on Colab or Kaggle is that this library is just for testing purposes you cannot use this library for deployment, and it won't work on large datasets.
SOLUTION 2
As I mentioned lazypredict depends on specific versions of other libraries, you can search on google and will find a list of those libraries along with their version, try to manually install those versions but it is a time-consuming step, the other way is to install a new python version within which you can create a Virtual Environment and then try to install lazypredict in it.
SOLUTION 3 (only perform if you know docker)
If you are aware of Docker you can install a python image in it, a fresh install that does not contain any libraries, so you can install lazypredict in it.

nodejs ask python-minimal that no longer use on python2

i use linux
nodejs had no problem untill i upgraded my system (sudo apt upgrade)
now when i try to install nodejs it say python-minimal mot installed
then i knew that it casue of updating python from python2.7.17 to python2.7.18 and python minimal is no longer require ,but now i cant install nodejs cause it ask for python-minimal
can any one help me
the problem is when i want to install nodejs 15 or 14
but when i install nodejs 12 or lower it have no problem
this is what it say after i write (sudo apt install nodejs)
sudo apt upgrade nodejs
[sudo] password for julian:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
libnode72 : Conflicts: nodejs-legacy
nodejs : Depends: python-minimal but it is not installable
E: Broken packages
This
sudo apt remove libnode72:amd64
sudo apt autoclean
sudo apt autoremove
should do the job.
I encountered this issue today after going from Ubuntu 18.04 to Ubuntu 20.04 and there are a lot of old Ask Ubuntu questions surrounding this and Github questions where for one reason or another various apps (Node included) rely on core Python functions that are leveraged from the python-minimal library.
For better or worse it also doesn't seem to care if Python is installed or not in it's entirety. It wants the minimal package specifically.
The thing is all the python-minimal repositories are marked OldStable (about OldStable if you want to know)and rely on Python 2 which has been sunset.
It seems if you haven't upgraded your OS in a while there is something hanging out in the package manager that will tell you that node needs python minimal to be run or installed but this is not the case as is evident by the lack of package support.
The solution I found was after upgrade to simply rerun the installation for Node based on the package manager instructions for your operating system. In my case it was specifically Dedbian and Ubuntu based distributions.

Slow xmlsec package build with pip install

I'm using xmlsec 1.3.3 in my python web application.
Every time I run a clean pip install, this is the package it hangs on, for about 5 minutes.
The package size is 15KB and pip show a using cached... message, so I guess the time is taken by building some specific security libraries.
Is there a way to do a clean pip install, but without rebuilding the xmlsec related libraries?
xmlsec is distributed in source code only but it's written in C so pip needs to compile it on every fresh installation. It's not possible to not compile it.
You can pre-compile it yourself if you use one specific platform and always install from your package instead of PyPI.

cant install lirc due to higher python version

Okay so i got i PiFace2 and i am trying to install pifacecad but you need pyton3lirc but this is what i am trying
pi#raspberrypi:~ $ sudo apt-get install python3-lirc
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
python3-lirc : Depends: python3 (< 3.5) but 3.5.3-1 is to be installed
E: Unable to correct problems, you have held broken packages.

Unable to install v0.11.0 tensorflow-gpu

I am having issues with installing the v0.11.0 version of tensorflow-gpu. My code works on tensorflow==0.11.0 but really slow. I had a tensorflow-gpu==0.11.0 but i had lost it due to an upgrade. The pip repository doesn't have a v0.11 anymore and starts with v0.12 only. I got the v0.11 wheel from here. I am able to install tensorflow==0.11.0 using the wheel at export TF_BINARY_URL=https://storage.googleapis.com/tensorflow/linux/cpu/tensorflow-0.11.0-cp27-none-linux_x86_64.whl
but I am unable to install the GPU version of tensorflow-gpu==0.11.0 using the corresponding link at export TF_BINARY_URL=https://storage.googleapis.com/tensorflow/linux/gpu/tensorflow-0.11.0-cp27-none-linux_x86_64.whl
The link looks same to me with just the folder different from gpu/ and cpu/. Upon using the link for GPU, it installs tensorflow==0.11.0 and not tensorflow-gpu=0.11.0. Where can I find a tensorflow-gpu==0.11.0 wheel?

Categories

Resources