I tried for 3 days straight - 12 hours a day - then found your videos and got it working in the time of the video - approx 20 mins. Thank you so much. Also your hell handsome
Excellent video I have looked at other videos and they always say, "go do something" and presume you know how to. This video has every single step explained in detail and is really easy to follow. Thank You Sam for taking the time to make this video - much appreciated!
Great video. FYI - ensure you (the audience) ``` pip install protobuf==3.20.* ``` before installing the tensorflow wheel if using tf=2.8+py=3.9 on 64bit Bullseye (aarch64). This may be true for other combinations as well (untested). This wasn't needed in the original video but due to updates over the last 6 months is now necessary.
i am using raspberrypi 3b+ python3 -V = "3.7.*" AND uname -m = "armv7l" and python3 -m pip install tensorflow-2.5.0-cp37-none-linux_armv7l.whl it frezed in "Building wheel for grpcio (setup.py) " what to do??
Thank you very much!! I couldn't install tensorflow on my Pi 4, I needed to do this pip3 install --upgrade protobuf==3.20.0, since he asked me for these 2 things: 1-Downgrade the protobuf package to 3.20.x or lower. 2. Set PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python (but this will use pure-Python parsing and will be much slower).
Hey thank you for this. I work in a lab at a hospital and this is a part of a project I'm working on. For others who may experience the same issue: I used pip uninstall protobuf; pip install protobuf==3.9.2
Why there is an error "Note selecting 'libhdf5-dev' instead of 'libhdf5-serial-dev' E: Unable to locate package libopenblas-base is there a way to solve this I can't input the additional libraries
Hi, got it resolved. So I was using python 3.11 and when I downgraded it to 3.9.2 the issue was resolved. But I started from scratch (ie. from the start of the code of this video). I think the issue may be that tensorflow is incompatible with some of the recent python versions (not really sure about this though). Anyway, got the issue solved. Hope it helps someone.
Hi Excellent job But I have a problem Error: tensorflow-2.8.0-cp39-none-lunix_aarch64.whl is not supported wheel on this platform If you can help me I have raspberry pi 4 (2ram)
Following your tutorial I have been very successful getting all of this to work. And have even trained a YOLOv5 model for image detection. I am having trouble with converting that best.pt file to a keras model because I cannot find a tensorflow-addons that works with this. Can you recommend a workaround.
Im kinda new to this and I went through with python 3.11 even tho tensorflow doesn't show a supported version tryed other tutorials but couldn't get it to work i really needed to downgrade with a version that is compatiblewith the tensorflow models
Thanks for great video sir. i currently have a project for my exam and this is help me. so far i dont have any trouble at all. but when i come to use import tensorflow.. it gave me h5py problem. from the description you suggest to install specific HDF5_Version = [Desired Version] which is confused me which one is suitable for my instalation. the UserWarning said that 'h5py is running against HDF5 1.10.6 when it was built against 1.10.4'. and i have still no ideas how to fix this. thanks for any reply.
Could you perhaps make a tutorial about how to install picamera2? Or make any way of making images with you latests operating system version perhaps? The latest version of the operating system has some issues with the camera library. Much appreciated :D
Hey Sam, Awesome content. I have a request - how can we stream a video from raspberry pi to a Mac/windows browser with face/eye detection running on the pi
Hello, i really enjoyed this tutorial, most of all that you are using last version of all packages and that's awesome. Have you tried deepsort on a raspberry with the picamera?? Thank you !!
I haven’t used the Jetson Nano but I think this process should work. It’s 64-bit and supports aarch64 (you can verify with uname -m). Especially since the Jetsen OS is based on Ubuntu
Thanks for the tutorial. I am stuck at point "python3 -m pip install tensorflow-[Your version here].whl". When i run this command, the installation stops at " Building wheel for grpcio". The RPi become very slow and i can't do anything. I'm using RPi 3B Python 3.9.2 aarch64. UPDATE: I have just used the shell file with tf 2.8 python 3.9, aarch64 and np1221 and it works.
Hey sam im installing tensorflow as per your instruction and I'm facing an error stating " ERROR: Could not build wheels for h5py, which is required to install pyproject.toml-based projects" while running the command HDF5_VERSION=1.10.6 pip install --no-binary=h5py h5py==3.1.0 could you please help me rectify it?
thank u for the tutorial ur the best , btw my camera pi v 1.2 doesn't work in my os 64bit any solution ? and i must use os 64 bit cuz i use pytorch in my classification and pytorch exist only in 64 bit
Hey man you are really helpful and I appreciate you. I was wondering if you could make a video of installation of opencv tensorFlow and mediapipe because I have followed your instructions for tensorFlow and opencv in 64 bit and its not working with mediapipe,and when I downgrade python to 3.7.12 with 32 bit i have the same problem as mentioned above. Thank you so much sir for your time.
Thank you so much !!! I’m so glad I have the right to learn from you! I’m really appreciate you. It’s for my final project and im really really stuck in the raspberry pi step. Dont know what to do. My code uses opencv tensorFlow and mediapipe and i don’t succeeded running it on my raspberry for 2 months!!!! Really need your help.. (3.9.2 64bit os)
14:27 when I run the command "python3 " and then import tensorflow as tf i get the message : Traceback (most recent call last): File "", line 1, in File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/_init_.py", line 37, in from tensorflow.python.tools import module_util as _module_util File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/python/_init_.py", line 37, in from tensorflow.python.eager import context File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/python/eager/context.py", line 29, in from tensorflow.core.framework import function_pb2 File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/core/framework/function_pb2.py", line 16, in from tensorflow.core.framework import attr_value_pb2 as tensorflow_dot_core_dot_framework_dot_attr_value_pb2 File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/core/framework/attr_value_pb2.py", line 16, in from tensorflow.core.framework import tensor_pb2 as tensorflow_dot_core_dot_framework_dot_tensor__pb2 File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/core/framework/tensor_pb2.py", line 16, in from tensorflow.core.framework import resource_handle_pb2 as tensorflow_dot_core_dot_framework_dot_resource_handle_pb2 File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/core/framework/resource_handle_pb2.py", line 16, in from tensorflow.core.framework import tensor_shape_pb2 as tensorflow_dot_core_dot_framework_dot_tensor_shape_pb2 File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/core/framework/tensor_shape_pb2.py", line 36, in _descriptor.FieldDescriptor( File "/home/st2023/env/lib/python3.9/site-packages/google/protobuf/descriptor.py", line 561, in _new_ _message.Message._CheckCalledFromGeneratedFile() TypeError: Descriptors cannot not be created directly. If this call came from a _pb2.py file, your generated code is out of date and must be regenerated with protoc >= 3.19.0. If you cannot immediately regenerate your protos, some other possible workarounds are: 1. Downgrade the protobuf package to 3.20.x or lower. 2. Set PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python (but this will use pure-Python parsing and will be much slower). plss help
Thank you for the vide it is very clear and silmple with good explanation. Yet i have some issues i'd like to as for some help. my priority in installing is that i want openCV first installed, then TF is just secondary. Yet i am unable to install CV2, it gave me an error message, after it i started troubleshooting and found some interesting outcomes. i have pi model 3 B 32 bit (difficult one) python version is 3.9.2 but managed the special environment issue, where i have 3.7.17 installed. the interestin phenomena i occured is that starting up a python shell and importing numpy simply does not work. out of the shell if i want to install, it says already installed (even within or out of the virt env) yet whenever entering a python shell, gives a message that no such package as numpy. I think this one can be a begening of my error. Any idea? Thank you all in advance
how to reinstall tensorflow......if i do uninstall all packages are left in python/sitepackages how to remove all those and install newly Update: now I have installed TensorFlow successfully by following your steps(before some supporting packages were not installed)
After installing TensorFlow I have tried to import it in a python environment and that returns this error......ImportError: cannot import name 'minidom' from 'xml.dom' (unknown location)
python3 -m pip install -U wheel mock six what does this command do and do we need it? its in the description but you skipped it in the video. thanks for everything, your videos are top quality
Some people were having errors so I included this command. It's not needed in most cases. -U: upgrade the package if it's already installed wheel: a tool to work with .whl files mock: a library for testing six: a Python 2 to 3 compatibility library
Hi. I got error when install the tensorflow, I'm downloading tensorflow 2.0.0 64bit but when i use the pip install with whl file the output is error invalid whl file I'm using pyenv python 3.7.6 Raspberry pi 4b Helppppppp.....!!!!!
I successfully installed tansorflow & opencv in raspberry pi 3b exactly show in tutorial & it work perfectly but after next day when import cv2 or import tansorflow it show bash command not found
failed - import tensorflow as tf (error: TypeError: Descriptors cannot be created directly. If this call came from a _pb2.py file, your generated code is out of date and must be regenerated with protoc >= 3.19.0. If you cannot immediately regenerate your protos, some other possible workarounds are: 1. Downgrade the protobuf package to 3.20.x or lower. 2. Set PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python (but this will use pure-Python parsing and will be much slower).
Fyi, I still failed to install tf2.5 with numpy==1.19.5, raspbian 64 bit bullseye, python3.9 , aarch64 even though I am using the correct whl file. The error ERROR: No matching distribution found for tensorflow-2.5.0-cp39-none-linux_aarch64_numpy1195.sh still happens, may I know how to fix it?
When I'm trying to install opencv and while importing it is showing numpy.core.multiarray import error 🥺 can anyone solve this i have to complete my project
Thanks for the video. I have an issue with tensorflow library. Basically I wanted to run both opencv and tensorflow for the same python code but the issue is that I have a code which requires tensorflow 1.14.0 as it has tensorflow.contrib command and similar old commands which work only with 1.14.0. I tried to edit and update my code but it has many commands and it is tedious so I followed this video and downgraded python to 3.7.4 (as I ran the same code with this version in windows and I had tensorflow lib installed too). For the sh file I chose `download_tensorflow-1.14.0-cp37-cp37m-linux_aarch64.sh` as I have RP os 64 bit and RP 4, 4 gb ram same as that used in video. So after following this command `python3 -m pip install tensorflow-[Your version here].whl` I got the error Unable to find the required version of tensorflow just the same error when I try to install tf lib directly through command `pip install tensorflow` in python 3.9.2. So how do I solve this issue? Please guide me Please note: I came to know about tensorflow.contrib issue when I ran the code on tf 2.8 version in python 3.9.2 as done in this video.
This command `python3 -m pip install tensorflow-1.14.0.whl` is important because it doesn't use the pip library. In your files, (type "ls" into the terminal) there should be a file called tensorflow-1.14.0.whl. If that is there, your installation should give a different error than the one you mentioned
Try This.. couldn't install tensorflow on my Pi 4, I needed to do this pip3 install --upgrade protobuf==3.20.0, since he asked me for these 2 things: 1-Downgrade the protobuf package to 3.20.x or lower. 2. Set PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python (but this will use pure-Python parsing and will be much slower).
Hello, please I am getting an error when i import tensorflow as tf. something like Tradeback (most recent call last): file "", line 1, in and so on. I have raspberry pi 4 64 OS bit with python 3.9 version aarch64
i keep getting stuck at the building wheel for h5py and it just doesnt load. no error no nothing just keeps loading and doesnt go anywhere from there. please help
Was getting "TypeError: Descriptors cannot not be created directly." Error when importing tensorflow. Needed to downgrade protobuf with this command. pip install --upgrade "protobuf
Sometimes the protobuf package might be installed without your involvement. For this, you have two solutions to apply. Try one of the below solutions and it should work. Solution 01:- You can downgrade the protobuf plugin, pip install protobuf==3.20.* or you can add it to the requirements.txt file as the last package. Because this will override the previously installed protobuf package. ... protobuf==3.20.* Solution 02:- You can set the following environment variable. export PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python
For those that could not get it working: try: sudo apt update sudo apt upgrade sudo apt install -y libhdf5-dev libc-ares-dev libeigen3-dev sudo apt install -y python3-pip pip3 install tensorflow can also add specific version by: pip3 install tensorflow==2.5.0 then: python3 import tensorflow as tf print(tf.__version__) quit()
I got an error on " import tensorflow as tf" >>>UserWarning: h5py is running against HDF5 1.10.6 when it was built against 1.10.4, this may cause problems '{0}.{1}.{2}'.format(*version.hdf5_built_version_tuple)
Hey, I followed your steps and installed python 3.7.12 along with opencv-python , i can access the opencv from the terminal but not in thonny python. Why is that ?
You won’t be able to access this in thonny. You can write the scripts in python, but you have to run the script in the terminal. Changing python versions with pyenv does not change python versions in thonny
@@SamWestbyTech I believe I am in the same situation, so I think he's getting stuck at 3:34. I am also running a virtual Pi in VirtualBox and the command "uname -m" is giving me "x86_64". So I don't really know which .sh script to pick.
Hi sir, I manage to change from 3.9.2 to 3.7.12, but when I open the Python in Raspberry Pi, it reappears as 3.9.2 You know maybe how do I set this to default in thonny?
Pyenv does not change python versions in thonny. You’ll have to run the script from the terminal instead of from thonny. Or you’ll have to follow a different method to change python versions in thonny
Has anyone faced with error: ..cp39-none-linux-aarch64.whl is not supported wheel on this platform..? I would really need help if anyone was able to solve the error
hey man! really like your tutorials! But in this case I am getting the following error: "ERROR: Wheel 'tensorflow' located at /home/pi/Desktop/project/tensorflow-2.5.0-cp37-none-linux_armv7l.whl is invalid." ps. im trying to install tensorflow in Raspberry pi 2 B with python 3.7.12
thanks for your excellent video. When I type pyenv install 3.7.12, it gets stuck on "patching file configure" and doesn't move on. how can I fix it? I also tried other versions of python still not working. RP 3B 32bit armv7l current py version: 3.9.2
@@SamWestbyTech about 20 mins. but then I changed my os to 64bit and as I didn't need to change my python version anymore, so the problem is solved automatically :)
I tried for 3 days straight - 12 hours a day - then found your videos and got it working in the time of the video - approx 20 mins. Thank you so much.
Also your hell handsome
Excellent video I have looked at other videos and they always say, "go do something" and presume you know how to. This video has every single step explained in detail and is really easy to follow.
Thank You Sam for taking the time to make this video - much appreciated!
Great video. FYI - ensure you (the audience) ``` pip install protobuf==3.20.* ``` before installing the tensorflow wheel if using tf=2.8+py=3.9 on 64bit Bullseye (aarch64). This may be true for other combinations as well (untested). This wasn't needed in the original video but due to updates over the last 6 months is now necessary.
thanks you bro
thank you so much boss
This was huge. thanks for adding this step
i am using raspberrypi 3b+ python3 -V = "3.7.*" AND uname -m = "armv7l" and python3 -m pip install tensorflow-2.5.0-cp37-none-linux_armv7l.whl it frezed in "Building wheel for grpcio (setup.py) " what to do??
Thank you sir. I had to uninstall protobuf 4.23.4 first then install your mentioned version. 👍
Thank you very much!! I couldn't install tensorflow on my Pi 4, I needed to do this pip3 install --upgrade protobuf==3.20.0, since he asked me for these 2 things:
1-Downgrade the protobuf package to 3.20.x or lower.
2. Set PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python (but this will use pure-Python parsing and will be much slower).
Hey thank you for this. I work in a lab at a hospital and this is a part of a project I'm working on. For others who may experience the same issue: I used pip uninstall protobuf; pip install protobuf==3.9.2
Thank you so much for mentioning this@@adamgulamhusein8768
Dude is basically a legend
Why there is an error "Note selecting 'libhdf5-dev' instead of 'libhdf5-serial-dev'
E: Unable to locate package libopenblas-base
is there a way to solve this I can't input the additional libraries
I learned a lot, thanks for the great tutorial, I wish everyone explains in such beautiful way
Hi, I followed the tutorial and made sure the version are identical, however I recieved an tensorflow.whl is not a supported wheel on this platform.
Got the same issue, any ideas on how to resolve it?
Hi, got it resolved. So I was using python 3.11 and when I downgraded it to 3.9.2 the issue was resolved. But I started from scratch (ie. from the start of the code of this video). I think the issue may be that tensorflow is incompatible with some of the recent python versions (not really sure about this though). Anyway, got the issue solved. Hope it helps someone.
You are great. You taught good. YOU DESERVE MORE.
Thank You.
This is a good tutorial, it helped me very much. I fixed the error about can't install Tensorflow on Python 3.7. Thank you very much!
I'm working on tensorflow this really helpful keep doing your work on raspi and make videos related to errors in raspi
Got any errors in particular that you would like a video about?
Hi sadly i still get the not a supported wheel for this platform I have a 64bit system and I tried to install it for 3.8
Hi
Excellent job
But I have a problem
Error: tensorflow-2.8.0-cp39-none-lunix_aarch64.whl is not supported wheel on this platform
If you can help me
I have raspberry pi 4 (2ram)
running into the same issue
I have the same error. Have you solved this?
having the same error
Me too . Help me
This was so helpful, can't thank you enough, perfect video!!!
Excellent explanation, clear and to the point.
Following your tutorial I have been very successful getting all of this to work. And have even trained a YOLOv5 model for image detection. I am having trouble with converting that best.pt file to a keras model because I cannot find a tensorflow-addons that works with this. Can you recommend a workaround.
Error: .whl is not a supported wheel on this platform pls help
first I want to thank you for this clear information ,you are doing well .
second, How could I install tensorflow on raspian as a virtual machine?
ein erstklassiges Video !! 👍
Jazak Allah kher , may God bless you insha Allah!!
This was insanely helpful, thanks alot
Excellent job! Was able to follow and get everything set up - even a s a relative Newbie to RP Thanks ...
great video Sam. Thanks for sharing.
This method worked for me. Thanks a ton :-)
I have an RPi5 with Raspbian Bookworm. I followed this guide and get ‘wheel not supported’
Any ideas? Does this work yet on a Pi5?
wonderful, this is exactly what I need !! thank you
it was really helpful. Thank you so much
Great video and very well explained. Thank you very much
This was so helpful. Thanks alot!!
Im kinda new to this and I went through with python 3.11 even tho tensorflow doesn't show a supported version tryed other tutorials but couldn't get it to work i really needed to downgrade with a version that is compatiblewith the tensorflow models
this was really helpful
thank you
Thanks for great video sir. i currently have a project for my exam and this is help me. so far i dont have any trouble at all. but when i come to use import tensorflow.. it gave me h5py problem. from the description you suggest to install specific HDF5_Version = [Desired Version] which is confused me which one is suitable for my instalation. the UserWarning said that 'h5py is running against HDF5 1.10.6 when it was built against 1.10.4'. and i have still no ideas how to fix this. thanks for any reply.
Could you perhaps make a tutorial about how to install picamera2? Or make any way of making images with you latests operating system version perhaps? The latest version of the operating system has some issues with the camera library. Much appreciated :D
I do not have a picamera but I will look into it if I get one
Thanks for the tutorial, it helped me a lot! But thank you especially for the clear way in which you explain
getting error : not a supported wheel on this platform
Nice tutorial..it's really helpful for install opencv & tensorflow
thank you so much, sir. This video really helped me
I was wondering if you could do a video on object detection using openCV that runs smoothly at 20 frames or more
I can look into it. This will probably be doable if the pixels are small enough
@@SamWestbyTech Thank you
getting this error " /bin/bash: ./download_tensorflow-2.5.0-cp37-none-linux_armv7l_numpy1195.sh: Permission denied"
Hey Sam, Awesome content. I have a request - how can we stream a video from raspberry pi to a Mac/windows browser with face/eye detection running on the pi
Hello, i really enjoyed this tutorial, most of all that you are using last version of all packages and that's awesome. Have you tried deepsort on a raspberry with the picamera?? Thank you !!
Great video! Was wondering if the Tensorflow process would work on the Jetson Nano also?
I haven’t used the Jetson Nano but I think this process should work. It’s 64-bit and supports aarch64 (you can verify with uname -m). Especially since the Jetsen OS is based on Ubuntu
well presented well documented video, thank yu
Thanks for the tutorial. I am stuck at point "python3 -m pip install tensorflow-[Your version here].whl". When i run this command, the installation stops at " Building wheel for grpcio". The RPi become very slow and i can't do anything. I'm using RPi 3B Python 3.9.2 aarch64.
UPDATE: I have just used the shell file with tf 2.8 python 3.9, aarch64 and np1221 and it works.
same problème how did you solve it?
thank you so much you almost covered everything 😁
Hey sam im installing tensorflow as per your instruction and I'm facing an error stating " ERROR: Could not build wheels for h5py, which is required to install pyproject.toml-based projects" while running the command HDF5_VERSION=1.10.6 pip install --no-binary=h5py h5py==3.1.0 could you please help me rectify it?
thank u for the tutorial ur the best , btw my camera pi v 1.2 doesn't work in my os 64bit any solution ?
and i must use os 64 bit cuz i use pytorch in my classification and pytorch exist only in 64 bit
Thanks brother. Really helpful
Hey man you are really helpful and I appreciate you. I was wondering if you could make a video of installation of opencv tensorFlow and mediapipe because I have followed your instructions for tensorFlow and opencv in 64 bit and its not working with mediapipe,and when I downgrade python to 3.7.12 with 32 bit i have the same problem as mentioned above. Thank you so much sir for your time.
I’ll look into it!
Thank you so much !!! I’m so glad I have the right to learn from you! I’m really appreciate you. It’s for my final project and im really really stuck in the raspberry pi step. Dont know what to do. My code uses opencv tensorFlow and mediapipe and i don’t succeeded running it on my raspberry for 2 months!!!! Really need your help.. (3.9.2 64bit os)
@@avivkarbassi7837 hi did you solve this issue?
Nice Video, thank you so much
can you make vedio for raspberry pi 0w open cv, mediapipe and rpi-gpio
14:27 when I run the command "python3 " and then import tensorflow as tf i get the message :
Traceback (most recent call last):
File "", line 1, in
File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/_init_.py", line 37, in
from tensorflow.python.tools import module_util as _module_util
File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/python/_init_.py", line 37, in
from tensorflow.python.eager import context
File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/python/eager/context.py", line 29, in
from tensorflow.core.framework import function_pb2
File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/core/framework/function_pb2.py", line 16, in
from tensorflow.core.framework import attr_value_pb2 as tensorflow_dot_core_dot_framework_dot_attr_value_pb2
File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/core/framework/attr_value_pb2.py", line 16, in
from tensorflow.core.framework import tensor_pb2 as tensorflow_dot_core_dot_framework_dot_tensor__pb2
File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/core/framework/tensor_pb2.py", line 16, in
from tensorflow.core.framework import resource_handle_pb2 as tensorflow_dot_core_dot_framework_dot_resource_handle_pb2
File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/core/framework/resource_handle_pb2.py", line 16, in
from tensorflow.core.framework import tensor_shape_pb2 as tensorflow_dot_core_dot_framework_dot_tensor_shape_pb2
File "/home/st2023/env/lib/python3.9/site-packages/tensorflow/core/framework/tensor_shape_pb2.py", line 36, in
_descriptor.FieldDescriptor(
File "/home/st2023/env/lib/python3.9/site-packages/google/protobuf/descriptor.py", line 561, in _new_
_message.Message._CheckCalledFromGeneratedFile()
TypeError: Descriptors cannot not be created directly.
If this call came from a _pb2.py file, your generated code is out of date and must be regenerated with protoc >= 3.19.0.
If you cannot immediately regenerate your protos, some other possible workarounds are:
1. Downgrade the protobuf package to 3.20.x or lower.
2. Set PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python (but this will use pure-Python parsing and will be much slower).
plss help
why do we need the virtual environment for?
Thank you for the vide it is very clear and silmple with good explanation. Yet i have some issues i'd like to as for some help.
my priority in installing is that i want openCV first installed, then TF is just secondary. Yet i am unable to install CV2, it gave me an error message, after it i started troubleshooting and found some interesting outcomes.
i have pi model 3 B 32 bit (difficult one)
python version is 3.9.2
but managed the special environment issue, where i have 3.7.17 installed.
the interestin phenomena i occured is that starting up a python shell and importing numpy simply does not work. out of the shell if i want to install, it says already installed (even within or out of the virt env) yet whenever entering a python shell, gives a message that no such package as numpy. I think this one can be a begening of my error. Any idea?
Thank you all in advance
when installing tensorflow it says BadZipFile: file is not a zip file
which file did u use
@@kvakash8912 Thanks for reply but its a bit late I completed that project 1 year ago 😅
@@hasrat17 oo okay
I'm now stuck here 🥲
Any idea bout this badzipfile
I am getting this error
zipfile.BadZipFile: File is not a zip file
while installing the wheel file
Great video! But i got an error when i install the whl file. It says wheel is invalid. Do you have any idea?
You got a RPi 5?
please make a video to install tensoflow and opencv without virtual environment in RPi 3
how to reinstall tensorflow......if i do uninstall all packages are left in python/sitepackages how to remove all those and install newly
Update: now I have installed TensorFlow successfully by following your steps(before some supporting packages were not installed)
When I run script on thonny python it shows no module tensor flow... How to import tensor flow without env or how to run env on reeboot
After installing TensorFlow I have tried to import it in a python environment and that returns this error......ImportError: cannot import name 'minidom' from 'xml.dom' (unknown location)
python3 -m pip install -U wheel mock six
what does this command do and do we need it? its in the description but you skipped it in the video.
thanks for everything, your videos are top quality
Some people were having errors so I included this command. It's not needed in most cases.
-U: upgrade the package if it's already installed
wheel: a tool to work with .whl files
mock: a library for testing
six: a Python 2 to 3 compatibility library
thank you
Hi. I got error when install the tensorflow, I'm downloading tensorflow 2.0.0 64bit but when i use the pip install with whl file the output is error invalid whl file
I'm using pyenv python 3.7.6
Raspberry pi 4b
Helppppppp.....!!!!!
Thanks for a great tutorial. Subscribe and Liked :)
I successfully installed tansorflow & opencv in raspberry pi 3b exactly show in tutorial & it work perfectly but after next day when import cv2 or import tansorflow it show bash command not found
Don't forget to reactivate your virtual environment
failed - import tensorflow as tf (error: TypeError: Descriptors cannot be created directly.
If this call came from a _pb2.py file, your generated code is out of date and must be regenerated with protoc >= 3.19.0.
If you cannot immediately regenerate your protos, some other possible workarounds are:
1. Downgrade the protobuf package to 3.20.x or lower.
2. Set PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python (but this will use pure-Python parsing and will be much slower).
thank you so mush it was so helpfull
Fyi, I still failed to install tf2.5 with numpy==1.19.5, raspbian 64 bit bullseye, python3.9 , aarch64 even though I am using the correct whl file. The error ERROR: No matching distribution found for tensorflow-2.5.0-cp39-none-linux_aarch64_numpy1195.sh still happens, may I know how to fix it?
same here, did you find any solution?
Hii im having errors on importing the cv2. It always shows "ImportError: numpy.core.multiarray failed to import"
Try `pip install --upgrade numpy`. I'm guessing you have an old version of numpy
hi could you help me installing opencv and the latest version of mediapipe I have been trying but I could not
I’ll add things with mediapipe to my list
When I'm trying to install opencv and while importing it is showing numpy.core.multiarray import error 🥺 can anyone solve this i have to complete my project
Thanks for the video. I have an issue with tensorflow library. Basically I wanted to run both opencv and tensorflow for the same python code but the issue is that I have a code which requires tensorflow 1.14.0 as it has tensorflow.contrib command and similar old commands which work only with 1.14.0. I tried to edit and update my code but it has many commands and it is tedious so I followed this video and downgraded python to 3.7.4 (as I ran the same code with this version in windows and I had tensorflow lib installed too). For the sh file I chose
`download_tensorflow-1.14.0-cp37-cp37m-linux_aarch64.sh`
as I have RP os 64 bit and RP 4, 4 gb ram same as that used in video. So after following this command
`python3 -m pip install tensorflow-[Your version here].whl`
I got the error Unable to find the required version of tensorflow just the same error when I try to install tf lib directly through command `pip install tensorflow` in python 3.9.2.
So how do I solve this issue?
Please guide me
Please note: I came to know about tensorflow.contrib issue when I ran the code on tf 2.8 version in python 3.9.2 as done in this video.
This command `python3 -m pip install tensorflow-1.14.0.whl` is important because it doesn't use the pip library. In your files, (type "ls" into the terminal) there should be a file called tensorflow-1.14.0.whl. If that is there, your installation should give a different error than the one you mentioned
Try This.. couldn't install tensorflow on my Pi 4, I needed to do this pip3 install --upgrade protobuf==3.20.0, since he asked me for these 2 things:
1-Downgrade the protobuf package to 3.20.x or lower.
2. Set PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python (but this will use pure-Python parsing and will be much slower).
thank you man
Hello, please I am getting an error when i import tensorflow as tf. something like Tradeback (most recent call last): file "", line 1, in and so on. I have raspberry pi 4 64 OS bit with python 3.9 version aarch64
same error
Well its back to the jetson nano.❤
i keep getting stuck at the building wheel for h5py and it just doesnt load. no error no nothing just keeps loading and doesnt go anywhere from there. please help
hello did you solve this problem?
@@gxdx697 i directly installed tensorflow lite using sudo apt get instead of using a wheel file and it worked
Thank you so much!!! U R HERO 👍
Was getting "TypeError: Descriptors cannot not be created directly." Error when importing tensorflow. Needed to downgrade protobuf with this command. pip install --upgrade "protobuf
Sometimes the protobuf package might be installed without your involvement. For this, you have two solutions to apply. Try one of the below solutions and it should work.
Solution 01:-
You can downgrade the protobuf plugin,
pip install protobuf==3.20.*
or you can add it to the requirements.txt file as the last package. Because this will override the previously installed protobuf package.
...
protobuf==3.20.*
Solution 02:-
You can set the following environment variable.
export PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python
For those that could not get it working:
try:
sudo apt update
sudo apt upgrade
sudo apt install -y libhdf5-dev libc-ares-dev libeigen3-dev
sudo apt install -y python3-pip
pip3 install tensorflow
can also add specific version by:
pip3 install tensorflow==2.5.0
then:
python3
import tensorflow as tf
print(tf.__version__)
quit()
I got an error on " import tensorflow as tf"
>>>UserWarning: h5py is running against HDF5 1.10.6 when it was built against 1.10.4, this may cause problems
'{0}.{1}.{2}'.format(*version.hdf5_built_version_tuple)
hi can you do steps on how to install PyQt5 in raspi 3b+ 64bit debian 11? thankyou
I’ll check it out!
Hey, I followed your steps and installed python 3.7.12 along with opencv-python , i can access the opencv from the terminal but not in thonny python. Why is that ?
You won’t be able to access this in thonny. You can write the scripts in python, but you have to run the script in the terminal. Changing python versions with pyenv does not change python versions in thonny
@@SamWestbyTech so, how can we access opencv from thonny ide ?
hi ,
can u do a video of plant disease detection with raspberry pi with VIT thank you
awesome video
yes please..
When i install pip install tensorflow-2.5.0….. i got error wheel is invalid, why this is happen?
i got the same error, have you gotten a solution yet
Hello sir. I want install tensorflow lite but I install raspberry pi desktop(x86_64) version on virtual Box. Is there's any way to download tflite?
I haven’t used virtual box. Do you get stuck at a certain point in the tutorial?
@@SamWestbyTech I believe I am in the same situation, so I think he's getting stuck at 3:34. I am also running a virtual Pi in VirtualBox and the command "uname -m" is giving me "x86_64". So I don't really know which .sh script to pick.
What version of Raspberry are you using?
Bullseye
15:45 open cv
Github raw file is not opening what to do??
Thanks a lot
I tried to install tensorflow, and keep getting an error in pyenv.
Then, I installed the raspian 64-bit and fix the problem.
Yep 64-bit makes it way easier
Hi sir, I manage to change from 3.9.2 to 3.7.12, but when I open the Python in Raspberry Pi, it reappears as 3.9.2
You know maybe how do I set this to default in thonny?
Yeah, Same for me
Pyenv does not change python versions in thonny. You’ll have to run the script from the terminal instead of from thonny. Or you’ll have to follow a different method to change python versions in thonny
Ok sir so how can I change python version in thonny ?
Same. Tensorflow cant install python 3.9.2
@@avivkarbassi7837 hey did you got solution on that?
Has anyone faced with error: ..cp39-none-linux-aarch64.whl is not supported wheel on this platform..? I would really need help if anyone was able to solve the error
i had the same error, to fix it i had to make sure i was running on python 3.9.2, newer versions dont work
@@redemy2591 Yea,I did the same thing,it works pretty well with 3.9 version.Thank you for answering.
hey man! really like your tutorials! But in this case I am getting the following error:
"ERROR: Wheel 'tensorflow' located at /home/pi/Desktop/project/tensorflow-2.5.0-cp37-none-linux_armv7l.whl is invalid."
ps. im trying to install tensorflow in Raspberry pi 2 B with python 3.7.12
Ok double check your python version is 3.7 with “python -V”
Double check you have armv7l with “uname -m”
Let me know the output of these
@@SamWestbyTech yeah it's showing python 3.7.12 and armv7l as outputs
@@SamWestbyTech having the same problem
@@hri7ik It's the linux version one
Same problem here plz plz help!!!
is this works on python 3.11.2
Is it work?
nice video bro ... but make the same for pi 3 please ...
installment of librosa ..... please
I’ll look into it
देवमाणूस(God) Bro🙏🙏
thanks for your excellent video.
When I type pyenv install 3.7.12, it gets stuck on "patching file configure" and doesn't move on. how can I fix it?
I also tried other versions of python still not working. RP 3B 32bit armv7l current py version: 3.9.2
How long have you let it run? This step takes a while
@@SamWestbyTech about 20 mins.
but then I changed my os to 64bit and as I didn't need to change my python version anymore, so the problem is solved automatically :)
@@amirgharghabi1970 Glad to hear you got it working!
your vide are kick ass please do a bignners tutorial on OpenCV and TensorFlow and make it for "dummies"
just like my writing haha