2019-04-20 22:15:47 -0500 | received badge | ● Popular Question (source) |
2017-06-25 07:45:34 -0500 | commented question | cv2.so missing on ubuntu I am running into the same missing cv2.so problem on attempting to upgrade from 3.1 to 3.2 ; -- Python 2: gives a suspiciously missing python (for build) field: |
2016-08-14 08:59:22 -0500 | received badge | ● Editor (source) |
2016-08-14 08:26:44 -0500 | asked a question | segfault on python calls from caffe in container I have a thorny issue - when I call cv2 functions from a certain code (caffe) in a docker container I hit the following segfault, which does not occur if not running in a container; however the nvidia container claims to be trouble free. I am not expert in reading stacktraces like these so any pointers to solution would be appreciated. I hit the segfault on using cv2 functions like cv2.flip or getrotationmatrix. However if I just call those functions (in the container) from a python command line, everything is ok.... (more) |
2015-03-01 11:38:50 -0500 | commented question | change source and recompile To convert the extant variable accum (which is a (numrho+2)*(numangle+2) long vector of ints) into a 2-dimensional Mat of uchars called accumulator, and put that Mat into an OutputArray called _acc, I did the following - reasonable? |
2015-03-01 05:47:09 -0500 | commented question | change source and recompile ok so now that I have my new arguments and don't crash anything I'd like to finally get the data I am after which is located in an 'autobuffer' and I'd like to get that data into my inputarray ; I don't seem to be able to access Mat values using m.[row][column] , how would I do this efficiently? Specifically I have a Mat called accumulator which I made as follows but that last line is not going to hack it I blv . |
2015-03-01 02:10:58 -0500 | received badge | ● Enthusiast |
2015-02-28 17:22:21 -0500 | commented question | change source and recompile I'm not sure what was wrong before but this one has started to work: |
2015-02-28 12:47:08 -0500 | commented question | change source and recompile I have yet to crack this nut gets me an error 139 on exiting my function HoughLinesWithAccumulator |
2015-02-26 11:07:09 -0500 | commented question | change source and recompile so is the doc here wrong ( "m - Destination matrix. If it does not have a proper size or type before the operation, it is reallocated") or is it the case that this is only true for calls to copyTo from outside opencv, or what? in any case in meantime i tried This gave trouble (an assertion fail in some malloc) . I'm looking for an opencv coding guide so maybe that'll help |
2015-02-26 04:34:52 -0500 | commented question | change source and recompile another small step forward (i think) - now i get an error 139 in python indicating bad memory access - so I'll try something besides the test I was attempting namely which was an attempt to get the input image back as output image. I'll try |
2015-02-25 13:07:55 -0500 | commented question | change source and recompile Now I get a working cv2.so (which i have to copy by hand into /usr/lib/python2.7/dist-packages , make install doesn't seem to do this). But I don't seem to have access to the extra output argument : when i try the first line is ok while the second gives a 'too many values to unpack' so i guess my OutputArray is not getting picked up by the gen2 and/or hdr_parser scripts. I'll see if I can find output of those guys somewhere. |
2015-02-25 11:45:11 -0500 | commented question | change source and recompile ok, seems as tho the cv2.so wasn't getting regenerated after the cmake, make -j2 , and make install. So I wiped out the build directory and am trying again . |
2015-02-25 08:36:36 -0500 | commented question | change source and recompile I can't seem to figure it - I added exactly one argument to the .cpp function and same to the .hpp, in the same place, with same type - .hpp entry below , in /opencv_src/modules/imgproc/include/opencv2/imgproc.hpp (and not in the .../include/opencv2/imgproc/imgproc.hpp which it looks like is not the right one): |
2015-02-25 07:45:59 -0500 | commented question | change source and recompile a few birthing pains. I tried adding an output array to my function along with the corresponding declaration in the .hpp header. This suffices to break my opencv install - i get the following ImportError: /usr/lib/python2.7/dist-packages/cv2.so: undefined symbol: _ZN2cv25HoughLinesWithAccumulatorERKNS_11_InputArrayERKNS_12_OutputArrayEddidddd I don't think its related to allocating an array for the accumulator , i tried a few things such as Mat accumulator; accumulator.copyTo(_accumulator) or _accumulator = _image but no dice |
2015-02-24 05:34:30 -0500 | commented question | change source and recompile whoops it looks like i shoudlve realized from your answer that i needed to copy the newly generated cv2.so to /usr/lib/python2.7/dist-package . Having done so I can now call my newly minted function, great! Now I will try changing arguments etc to actually get the output i need. Just saw your above answer, yes that wouldve taken care of it. Thanks again for help, it looks like i am in right direction for the time being |
2015-02-24 05:00:41 -0500 | commented question | change source and recompile Thanks for your help first off, so far no dice: I had a declaration in include/opencv2/imgproc.hpp, monkeying the declaration that was already there for houghlines, for my version which i called houghlineswithaccumulator (in meantime keeping same arguments) I read the link, thx I'm not sure how to resintall cv2.pyd , I tried find -name cv2.pyd and locate cv2.pyd but didn't find it. The C++ ide was just to check whether i can first of all call my new function from C++, next step pyt |
2015-02-22 05:14:09 -0500 | asked a question | change source and recompile Hi
I'd like to change the opencv source a bit and recompile (I'd like access to the hough transform 'accumulator' image, which I see in the modules/imgproc/hough.cpp source but isn't exposed).
So what I did was make a copy of the function cv::HoughLines in hough.cpp , called it cv::HoughLinesWithAccumulator and made the corresponding definition in the imgproc.hpp file, then did a cmake which seemed to go ok (although there is some sort of download step, which I hope isn't somehow avoiding my changed code). |
2014-08-13 10:50:01 -0500 | asked a question | doc error at cascade_classification.html I believe there may be an error in the docs here . In the fifth paragraph, second sentence "For example, in the case of the third line feature (2c) the response is calculated as the difference between the sum of image pixels under the rectangle covering the whole feature (including the two white stripes and the black stripe in the middle) and the sum of the image pixels under the black stripe multiplied by 3 in order to compensate for the differences in the size of areas." I think the "multiplied by 3" should be "multiplied by 2" since the black area was counted as white once, so it must be subtracted one time to arrive at the sum of the two white areas, and then must be subtracted again to get white areas minus black areas, in total then requiring subtraction twice and not thrice. |