Ask Your Question
1

Going beyond the documentation

asked 2019-09-27 04:52:07 -0600

Watol gravatar image

updated 2019-09-27 05:08:03 -0600

berak gravatar image

Hi,

this is a common problem I have when using libraries: I want to use a function, however the documentation seem to be incomplete. Sometimes after extensive search I find out that in deed, not all parameters or methods available were listed in the docs.

I know I can look at the source code. However to me, this is not always helpful. If I am using python modules that have been written in cpp I find myself unable to figure out the names of the parameter/method in the python wrap.

Also my favorite python method of using inspect.getmembers() does not seem to work for wrapped libraries. All I can see are the data model methods, but not the parameters or normal methods.

So my questions is, how to go beyond the documentation in these cases? Is there something like "inspect.getmembers()" so I can extract all parameters and methods of an imported class?

particularly I am trying to figure out specifics of the cv2.SimpleBlobDetector. Maybe I am unable to search the docs well. But all I could find about this methode is: https://docs.opencv.org/4.1.1/d0/d7a/...

Thank you very much for your help in advance. If there is a good method to go beyond the docs in these cases this would help me out many times!

edit retag flag offensive close merge delete

Comments

1

cv2.SimpleBlobDetector is a class. To create an object in python you must use cv.SimpleBlobDetector_create and parameters attribute are definedhere. You must sometimes follow C++ link to get doc (cv::SimpleBlobDetector::Params)

LBerger gravatar imageLBerger ( 2019-09-27 05:20:18 -0600 )edit
1

what about the obvious >>> help(cv2.SimpleBlobDetector)

berak gravatar imageberak ( 2019-09-27 08:09:42 -0600 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2019-09-27 05:51:16 -0600

Watol gravatar image

Thank you, I have been overlooking that.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2019-09-27 04:52:07 -0600

Seen: 215 times

Last updated: Sep 27 '19