16 votes
Accepted

Failed to create MMAL component b'vc.ril.camera': Out of memory

This error was resolved when I disconnected and reconnected my camera module. Somehow my camera module must have been wiggled loose when I was working with it and the Pi was not able to detect the ...
Justin's user avatar
  • 432
13 votes

ERROR: Environment '/home/pi/.virtualenvs/cv' does not contain an activate script

I'm running on a raspbian buster with Python 3.7.3. I ran into the same issue, "ERROR...no activation script". I tried @Lombax answer but it didn't work. However, I noticed that the version of ...
vinay kumar's user avatar
11 votes
Accepted

How to install OpenCV on Raspberry Pi 3 in Raspbian Jessie?

I was doubtful too about virtualenv, and quite happy to live without it :) Here are the commands I took from both tutorial you provided, for OpenCV 3.1.0 generic stuff sudo apt-get update sudo apt-...
Technico.top's user avatar
  • 1,406
10 votes

ERROR: Environment '/home/pi/.virtualenvs/cv' does not contain an activate script

I am also facing the same error. You must add these lines on ~/.profile export WORKON_HOME=$HOME/.virtualenvs export VIRTUALENVWRAPPER_PYTHON=/usr/bin/python3 export VIRTUALENVWRAPPER_VIRTUALENV=/usr/...
Abdul Basit's user avatar
6 votes
Accepted

Is it necessary to release Raspberry Pi Camera before rebooting? If so how do I do it?

There is NO NEED to do anything before a reboot. If you issue a sudo reboot command Linux will manage an orderly shutdown of the software. This is, however, a poor way of ensuring a reliable 24/7 ...
Milliways's user avatar
  • 60k
6 votes

How can I use OpenCV with Python 3 on a Raspberry Pi?

It says "Cannot open shared object". ImportError:libQTtest.so.4:cannot open shared object file:no such file or directory Yes, but it does not say this is because "the library isnt shared with it"...
goldilocks's user avatar
  • 58.9k
5 votes

How to install OpenCV on Raspberry Pi 3 in Raspbian Jessie?

I will add to what @Technico.top has suggested. There's another method of installing OpenCV using emulation software to compile the software on your PC that doesn't require cross-complication. This ...
krishna chaitanya's user avatar
5 votes

Is there a Raspbian image with OpenCV 3 pre-installed?

You can install opencv in a few minutes using piwheels: sudo apt install libatlas3-base libwebp6 libtiff5 libjasper1 libilmbase12 libopenexr22 libilmbase12 libgstreamer1.0-0 libavcodec57 ...
ben_nuttall's user avatar
  • 2,451
5 votes
Accepted

Install opencv on Raspberry Pi 3 in a different way than compiling from source

Precompiled wheels of opencv-python and opencv-contrib-python for arm / python 3 are available from piwheels (www.piwheels.org). On current Raspbian Stretch this already pre-configured. On other ...
Dirk's user avatar
  • 3,551
5 votes

How to install OpenCV on Raspbian Stretch?

Following these directions from PyImageSearch fixes the problem. Those directions lack an easy copy-paste and have a lot of interspersed text, so I copy them here. I assume you already have Python3 ...
emonigma's user avatar
  • 273
5 votes
Accepted

Run the program in the laptop and use the raspberry gpios, PWM to control servos

The pigpio library lets you control the GPIO of one or more networked Pis from a laptop. The laptop may be Windows, Mac, Android, or Linux based - in fact it can run any operating system as long as ...
joan's user avatar
  • 71k
5 votes
Accepted

How can i install OpenCV on Raspberry Pi 4 (Raspbian Buster)?

You should use OpenCV from the default Raspbian Repository. It is tested and fits best into the Raspbian distribution without errors (I hope :). On Buster you will find with: rpi ~$ apt list python*...
Ingo's user avatar
  • 42.1k
3 votes
Accepted

Getting extremely low fps on Rpi 3 while image processing

First off, how are you determining that the CPU is only at 25-28%? htop is what I would use as it shows the usage of each core separately. sudo apt-get install htop, then htop to run it, q to quit. ...
tlhIngan's user avatar
  • 3,372
3 votes
Accepted

Stereo Vision Using Compute Module: Pi camera synchronization

The Pi Compute Module's stereoscopic support causes captures (and video recordings) to produce frames containing images from both attached cameras, either side-by-side or top-and-bottom, depending on ...
Dave Jones's user avatar
  • 3,978
3 votes
Accepted

How to use Raspberry Pi and Pi camera standalone like Arduino?

How can I use Raspberry Pi standalone which works just like Arduino? You can't use it exactly like an Arduino, or at least not easily, and it would not be very desirable to do so. The Pi is a ...
goldilocks's user avatar
  • 58.9k
3 votes
Accepted

Unable to capture faces "y is not defined"

y is out of scope after leaving the for-loop which is why you get the not defined error with your imwrite. Check your intented program flow and indentation. for (x,y,w,h) in faces: cv2.rectangle(...
Ghanima's user avatar
  • 15.9k
3 votes
Accepted

Syntax error in python code for setMouseCallback() event

You are missing a (, try: img = np.zeros((512, 512, 3), np.uint8)
Stephen Rauch's user avatar
3 votes
Accepted

Increasing fps of pi camera using OpenCV C++ implementation

As suggested in the comments, I think you need to set the frame geometry first and then set the frame-rate afterwards. std::cout <<"\t[PARAM_FRAME_WIDTH] "; if(!cap.set(CV_CAP_PROP_FRAME_WIDTH,...
Mark Setchell's user avatar
3 votes

How to install opencv on raspbian jessie Lite?

Being two years old, that script has issues such as tying to an older version of OpenCV. Rather than downloading from Itseez's GitHub repo you're better off installing via the Raspbian package ...
jdonald's user avatar
  • 2,904
3 votes

Is there a Raspbian image with OpenCV 3 pre-installed?

This, link may be helpfull. The image contains the last raspbian SO (Stretch), Ros and OpenCV https://medium.com/@rosbots/ready-to-use-image-raspbian-stretch-ros-opencv-324d6f8dcd96
Iker Arana's user avatar
3 votes

Is there a Raspbian image with OpenCV 3 pre-installed?

Preparing a Raspberry Pi for OpenCV development is really time consuming, OpenCV takes hours to compile and a lot of other things have to be set up, so I just share my SD Card image here to speed up ...
Milan Toth's user avatar
3 votes

Is it necessary to release Raspberry Pi Camera before rebooting? If so how do I do it?

No, it is not necessary to stop the Pi camera before rebooting.
joan's user avatar
  • 71k
3 votes

Is it necessary to release Raspberry Pi Camera before rebooting? If so how do I do it?

No there is no need to stop the camera before reboot. Also preforming killall python is not doing you any good as the reboot is going to force the program to close anyway. If you are worried about ...
Chad G's user avatar
  • 1,043
3 votes
Accepted

Pre-built OpenCV on Raspbian Buster

You just needed to run apt-get update and retry your command to install your desired package. The issue was that one of the dependencies (libpango in this case) which needed to be installed along ...
ksjoberg's user avatar
3 votes

Getting stuck at 100% using make -j4 command while installing open cv on Rasbian buster , Raspberry Pi 4 B+

You don't tell us why do you want to compile OpenCV from source so I assume it is not necessary. We have seen many problems on this site doing it. You also try to compile for python version 2. This is ...
Ingo's user avatar
  • 42.1k
3 votes

Raspberry 4 B not booting from raspberry stretch OS

The raspberrypi.org blog explained the need for Buster as follows: "The reason for this [new version of Rapbian] is that one of the important new features of Raspberry Pi 4 is that the open-source ...
John P's user avatar
  • 179
3 votes

Raspberry Pi4 Error while using 2 USB cameras, VIDIOC_QBUF: Invalid argument

I was able to narrow this down to a Kernel issue. I do think there is something that has been updated that is causing the problem since the 7/10 release... If you look at a list (lsmod) of your ...
Bill Armstrong's user avatar
3 votes

Raspberry Pi4 Error while using 2 USB cameras, VIDIOC_QBUF: Invalid argument

I believe that there are some limitations in the main USB camera driver uvc, or your CPU/GPU's processing power for that matter, where running multiple uncompressed camera streams will just ... hang. ...
Nasser Al-Wohaibi's user avatar
3 votes
Accepted

How to execute a Python 3 + OpenCV 4 script @reboot on Raspbian Lite (headless)?

By adding this single command to the chain (as per seen at the bottom of /home/pi/.bashrc) it resolved the whole thing: export LD_LIBRARY_PATH=/opt/opencv-4.1.0/lib:$LD_LIBRARY_PATH So basically, ...
that-ben's user avatar
  • 221
3 votes
Accepted

Raspberry pi line follower using camera

What is a line follower robot? Line follower or Line detector is an autonomous robot that follows either black line in white are or white line in the black area. The robot must be able to detect a ...
M. Rostami's user avatar
  • 4,323

Only top scored, non community-wiki answers of a minimum length are eligible