Ask Your Question

pradeep_kb's profile - activity

2016-02-16 10:24:37 -0600 commented question CvTracks undeclared in class

Can anyone help me on this please..

2016-02-15 15:46:08 -0600 asked a question CvTracks undeclared in class
class ImageProcessing       //user defined class 
{   
Public:
    void checkzone(CvTracks::const_iterator ot, double position1);
       .
       .
       .
     };

When I compile, compiler is throwing

  1. error: 'CvTracks' has not been declared.
  2. error: expected ',' or '...' before 'ot'

But when I declare this function outside the class, compiler is not throwing error.

Please help me to resolve this error.

2016-02-02 10:05:12 -0600 commented answer OpenCV 2.4.3 rectangle detection

@donald83180 How did you calculate the angle rotation?

2016-01-25 11:01:53 -0600 asked a question how to know the angle of orientation of the detected rectangular object with respect to X-Axis

Hello,

My program has to detect the rectangular object present in the water and measure its angle of orientation with respect to X-Axis. The idea behind this is, i have to move my vehicle in the direction of the object orientation, the object will be rectangular in shape. So if I get the angle of orientation of the object then I can send that angle to my vehicle and then rotate the vehicle with that angle and then move on.

2016-01-12 14:42:20 -0600 commented question optimization techniques for opencv, C++

@Vit @StevenPuttemans @sturkmen, I have done profiling for the program on raspberry pi 2 with raspbian OS. here are the details. Need your help to analyse it in depth.

2016-01-12 10:32:37 -0600 commented question optimization techniques for opencv, C++

This profiling i have done in my PC not on raspberry pi. On raspberry pi compiler is not generating gmon.out I am working on that. I have followed theset steps. But not working for raspbian OS.

2016-01-12 10:24:10 -0600 commented question optimization techniques for opencv, C++

@Vit @StevenPuttemans @sturkmen, I have done profiling for my program using gprof tool here is the details. I am new to this, not able to analyze properly. Thanks for the help.

2016-01-11 16:27:16 -0600 commented question optimization techniques for opencv, C++

@Vit, From the above result that I have posted I found morphology process is taking more time. I think background subtraction process will take less time then morphology process, What do you say? I am new to Opencv, this program was written by someone else. I have to optimize it now.

2016-01-11 15:36:13 -0600 commented question optimization techniques for opencv, C++

how about this

2016-01-11 15:23:00 -0600 commented question optimization techniques for opencv, C++

@Vit @StevenPuttemans I have gone through the profiling, I got to know we need a tool to check the which function is taking much time. But there are lot of tools available. Which is the best tool to use for Opencv, Raspberry pi, C++?

2016-01-11 15:15:28 -0600 commented question optimization techniques for opencv, C++

@Vit, this is manual profiling that I have done. All the results are in milliseconds.

Total time: 3.99949e+07ms  fps: 2.5e-05
END OF VIDEO
Times: 
1-Moving difference, grayscale conversion-------------->1.18404e+06
2-Image binarization----------------------------------->102496
3-Dilate and erode (Morphology)------------------------>1.35859e+07
4-Blob process(FilterByArea,UpdateTracks,RenderTracks)->983343
5-Car and person detection----------------------------->99999.6
6-Getting frames from video and frames skipped--------->1.63229e+06
(Adding 1 to 6) Total->1.75881e+07
2016-01-10 19:12:44 -0600 commented question optimization techniques for opencv, C++

@sturkmen @Vit Does Background subtraction helps to speedup the program?

2016-01-10 19:11:04 -0600 commented question optimization techniques for opencv, C++

@Vit, I did not do profiling, I don't know what it is. Could you please help me to know that

2016-01-10 19:08:12 -0600 asked a question how to differentiate the two overlapped cars in the video

I have written program for detecting cars in the video. If two cars found simultaneously my program is counting for only one or some times it do not count. is there any way to solve this problem? Does background subtraction help to solve this problem?

2016-01-09 22:33:34 -0600 commented question optimization techniques for opencv, C++

@sturkmen I have even done re-sizing of image to 50% 75% and 25%.. did all possible thinngs to get good result.

2016-01-09 22:24:21 -0600 commented answer optimization techniques for opencv, C++

I am detecting the cars present in the video and counting no. of cars entering in certain region. I am not processing every frame. I am have tested the program with 4, 6 & 8 frame skips. But still it is taking more time and not processing in required time. The video that have is of 5 hours and when I run the program it is taking 6.5 to 7 hours for skip 8 but it is not giving accurate results. The number of cars count is reducing.

2016-01-09 22:23:44 -0600 commented question optimization techniques for opencv, C++

@sturkmen I am detecting the cars present in the video and counting no. of cars entering in certain region. I am not processing every frame. I am have tested the program with 4, 6 & 8 frame skips. But still it is taking more time and not processing in required time. The video that have is of 5 hours and when I run the program it is taking 6.5 to 7 hours for skip 8 but it is not giving accurate results. The number of cars count is reducing.

2016-01-09 12:55:22 -0600 asked a question optimization techniques for opencv, C++

I have written a program in which the program has to detect objects from the video. the actual duration of video is 5 hours but it is taking nearly 10 hours on raspberry pi 2. It is taking very long time, doesn't work in real time. Is there any technique to utilize all the 4 cores of raspberry pi to run the program? Are there any optimization techniques available for opencv to make my program run faster?

2015-12-21 13:30:58 -0600 commented question How to know the co-ordinates/angle of the object detected (Rectangular)

@pkblab , I am very new to opencv.. I didn't think about it still. Please advice me your best.

2015-12-21 13:13:06 -0600 asked a question How to know the co-ordinates/angle of the object detected (Rectangular)

Hello,

I want to know the co-ordinates or angle with respect to y axis of the object detected. In my case we are detecting rectangular object placed in side the swimming pool or water. I should get the any of the object and I should make my robot to align and move in that direction. Please advice.

2015-12-02 00:21:57 -0600 received badge  Enthusiast
2015-12-01 19:32:34 -0600 asked a question cvCaptureFromCAM(x) returning NULL, tried with X = 0,1, 2.. on raspberry pi2
> #include <iostream>
> #include <opencv/cv.h>
> #include <opencv/highgui.h>
> 
> using namespace std;
> 
> char key;
> 
> int main() {
>   cvNamedWindow("Camera_Output",1);    
> //create a window     CvCapture* capture
> =cvCaptureFromCAM(0);                   // Capture using any camera, we can
> aslo use 0 as a parameter if we are
> using single camera.  if(capture ==
> NULL)         {           printf("cannot open
> camera#n");           return -1;      }
>   while(1){                            
> //creating any infinite loop for live
> streaming
>           IplImage* frame = cvQueryFrame(capture);                
> //capture image frames from camera
>       cvShowImage("Camera_Output",frame); 
> //show image frames on created window
>       key = cvWaitKey(10);                
> //Capture keyboard storke
>       if(char(key) == 27){
>                   break;      }   }       cvReleaseCapture(&capture);          
> //Release capture Image
>   cvDestroyWindow("camera_Output");    
> //Destroy Window
> 
>   return 0; }

please advice

2015-12-01 18:55:59 -0600 answered a question during run time the program hangs on raspberry pi 2 at cvLabel

I got the answer for my issue. The below changes are required specially for raspberry pi 2(armhf) which avoids the program to run infinite.

go to /home/pi/cvblob/cvBlob

In cvLabel.h file

const char movesE ... const char movesI ...

to

const signed char movesE ... const signed char movesI ...

and in cvBlob/cvcontour.cpp , line 84:

change

const char cvChainCodeMoves[8][2] = { { 0, -1},

to

const signed char cvChainCodeMoves[8][2] = { { 0, -1},

2015-11-29 15:31:20 -0600 asked a question during run time the program hangs on raspberry pi 2 at cvLabel

Hello Everyone,

I have written a program to count no of cars from the captured video. I have installed opencv and cvblob, raspbian wheezy OS on raspberry pi 2. The problem I am facing is "During run time the program hangs at cvLabel after certain no of iterations.

IplImage *labelImg =cvCreateImage(cvGetSize(greyImage), IPL_DEPTH_LABEL, 1);
unsigned int result = cvLabel(greyImage, labelImg,blobs);

But when I run the same program on Virtual Machine in my laptop it will run completely. What might be the reason for this..? Please advice

Thanks.

2015-11-14 11:49:21 -0600 asked a question Video is not playing during runtime.

Hello Everyone,

I have written program for Car tracking. I am sending video Car.mp4 during run time.

g++ -I/usr/local/include CarMotion-HSV.cpp $(pkg-config opencv cvblob --cflags --libs)

./a.out -f Car.mp4

The problem here is it will open a window and remain stagnant showing only picture of video, it is not playing video in the window. However when I play it with omxplayer it will play (omxplayer -o hdmi Car.mp4). Same code I have tried in Ubuntu Mate in VM, its working. But not working in Raspberry pi 2, Raspbian Jesse OS.

Please help me out to know how to run video during run time.

Thanks in advance

2015-11-14 11:32:25 -0600 commented question can anyone help me to know mv /tmp/my_project.cpp . means?

@theodore Thank you

2015-11-13 08:05:25 -0600 asked a question can anyone help me to know mv /tmp/my_project.cpp . means?

I am installing Opencv, CvBlob on Raspbian OS. there were list of build instruction which i was following and found this line.

Thanks in advance

2015-11-09 16:58:22 -0600 received badge  Editor (source)
2015-11-09 15:39:40 -0600 asked a question Error : Cannot open output file a.out : Permission denied on OpenCV sample program compilation

I am getting error Cannot open output file a.out: Permission denied when i tried to run the sample program which are present in opencv-2.4.11 directory. the path of the directory is /home/pi/opencv-2.4.11/samples/.. the properties of the cpp file are -rw-r--r-- 1 root root starter_video.cpp.

i even tried to change the permission for directory /home/pi/opencv-2.4.11/samples/.. it didn't work. it throw "Changing permissions of 'samples' : Operation not permitted".

Please advice

2015-11-07 15:32:43 -0600 commented question compiling Opencv and cvBlob libraries in Raspbian Wheezy OS. Getting undefined references error

@berak Thank you.. I compiled with linking the libraries.. errors got resolved.

2015-11-05 11:25:51 -0600 commented question compiling Opencv and cvBlob libraries in Raspbian Wheezy OS. Getting undefined references error

@berak Could you please explain in detail. I am new to OpenCV

2015-11-05 11:20:32 -0600 asked a question compiling Opencv and cvBlob libraries in Raspbian Wheezy OS. Getting undefined references error
pi@raspberrypi ~ $ g++ CarMotionTwoLines-HSV.cpp

CarMotionTwoLines-HSV.cpp: In constructor ‘CarVideoHandler::CarVideoHandler()’:
CarMotionTwoLines-HSV.cpp:92:17: warning: deprecated conversion from string constant to ‘char*’ [-Wwrite-strings]
CarMotionTwoLines-HSV.cpp:93:14: warning: deprecated conversion from string constant to ‘char*’ [-Wwrite-strings]
CarMotionTwoLines-HSV.cpp:94:14: warning: deprecated conversion from string constant to ‘char*’ [-Wwrite-strings]
CarMotionTwoLines-HSV.cpp:95:17: warning: deprecated conversion from string constant to ‘char*’ [-Wwrite-strings]
CarMotionTwoLines-HSV.cpp:98:15: warning: deprecated conversion from string constant to ‘char*’ [-Wwrite-strings]
CarMotionTwoLines-HSV.cpp:99:15: warning: deprecated conversion from string constant to ‘char*’ [-Wwrite-strings]
/tmp/cclicE4h.o: In function `allocateOnDemand(_IplImage**, CvSize, int, int)':
CarMotionTwoLines-HSV.cpp:(.text+0x380): undefined reference to `cvCreateImage'
/tmp/cclicE4h.o: In function `resizeImg(_IplImage*, int)':
CarMotionTwoLines-HSV.cpp:(.text+0x4e0): undefined reference to `cvResize'
/tmp/cclicE4h.o: In function `resizeImgColor(_IplImage*, int)':
CarMotionTwoLines-HSV.cpp:(.text+0x5a8): undefined reference to `cvResize'
/tmp/cclicE4h.o: In function `MorfologiaDE(_IplImage*, _IplImage*, int)':
CarMotionTwoLines-HSV.cpp:(.text+0x628): undefined reference to `cvCreateStructuringElementEx'
CarMotionTwoLines-HSV.cpp:(.text+0x648): undefined reference to `cvDilate'
CarMotionTwoLines-HSV.cpp:(.text+0x660): undefined reference to `cvErode'
CarMotionTwoLines-HSV.cpp:(.text+0x66c): undefined reference to `cvReleaseStructuringElement'
/tmp/cclicE4h.o: In function `mouseHandler(int, int, int, int, void*)':
CarMotionTwoLines-HSV.cpp:(.text+0x1178): undefined reference to `cvCloneImage'
CarMotionTwoLines-HSV.cpp:(.text+0x1278): undefined reference to `cvRectangle'
CarMotionTwoLines-HSV.cpp:(.text+0x148c): undefined reference to `cvLine'
CarMotionTwoLines-HSV.cpp:(.text+0x14e0): undefined reference to `cvShowImage'
/tmp/cclicE4h.o: In function `idTrackCarPerson(_IplImage*, int**, std::_Rb_tree_const_iterator<std::pair<unsigned int const, cvb::CvBlob*> >, std::_Rb_tree_const_iterator<std::pair<unsigned int const, cvb::CvTrack*> >, int, double, double, double, CvFont, char*, int**, int**, int**, int**, int&, int&, int*, int*, int*, int*, int*, int, int, int, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::basic_string<char, std::char_traits<char>, std::allocator<char> >)':
CarMotionTwoLines-HSV.cpp:(.text+0x4c88): undefined reference to `cvInitFont'
CarMotionTwoLines-HSV.cpp:(.text+0x4db0): undefined reference to `cvPutText'
CarMotionTwoLines-HSV.cpp:(.text+0x4f08): undefined reference to `cvPutText'
CarMotionTwoLines-HSV.cpp:(.text+0x5148): undefined reference to `cvRectangle'
CarMotionTwoLines-HSV.cpp:(.text+0x5338): undefined reference to `cvRectangle'
CarMotionTwoLines-HSV.cpp:(.text+0x5794): undefined reference to `cvRectangle'
CarMotionTwoLines-HSV.cpp:(.text+0x57b8): undefined reference to `cvInitFont'
CarMotionTwoLines-HSV.cpp:(.text+0x5920): undefined reference to `cvPutText'
CarMotionTwoLines-HSV.cpp:(.text+0x5b50): undefined reference to `cvRectangle'
CarMotionTwoLines-HSV.cpp:(.text+0x6374): undefined reference to `cvRectangle'
CarMotionTwoLines-HSV.cpp:(.text+0x6398): undefined reference to `cvInitFont'
CarMotionTwoLines-HSV.cpp:(.text+0x6500): undefined reference to `cvPutText'
CarMotionTwoLines-HSV.cpp:(.text+0x6654): undefined reference to `cvPutText'
CarMotionTwoLines-HSV.cpp:(.text+0x6844): undefined reference to `cvRectangle'
CarMotionTwoLines-HSV.cpp:(.text+0x69cc): undefined reference to `cvInitFont'
CarMotionTwoLines-HSV.cpp:(.text+0x6af4): undefined reference to `cvPutText'
CarMotionTwoLines-HSV.cpp:(.text+0x6c4c): undefined reference to `cvPutText'
CarMotionTwoLines-HSV.cpp:(.text+0x6e7c): undefined reference to `cvRectangle'
CarMotionTwoLines-HSV.cpp:(.text+0x706c): undefined reference to `cvRectangle'
/tmp/cclicE4h.o: In function `idTrackCarPersonOneLine(_IplImage*, int**, std::_Rb_tree_const_iterator<std::pair<unsigned int const, cvb::CvBlob*> >, std::_Rb_tree_const_iterator<std::pair<unsigned int const, cvb::CvTrack*> >, int, double, double, CvFont, char*, int**, int**, int&, int&, int*, int*, int*, int*, int*, int, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::basic_string<char, std::char_traits<char>, std::allocator<char> >, int**)':
CarMotionTwoLines-HSV ...
(more)