0

I am using opencv FAST corner detection algorithm

but I have a question about the threshold in this code

fast = cv2.FastFeatureDetector_create(threshold=25)

what is the meaning of the threshold ? why we use it ?

according to opencv we just select an appropriate value of it

1 Answer 1

1

From the second page of Rosten E., Drummond T. (2006). Machine learning for high-speed corner detection:

The majority of feature detection algorithms work by computing a corner response function (C) across the image. Pixels which exceed a threshold cornerness value (and are locally maximal) are then retained.

and from page 5:

The segment test criterion operates by considering a circle of sixteen pixels around the corner candidate p. The original detector [2,3] classifies p as a corner if there exists a set of n contiguous pixels in the circle which are all brighter than the intensity of the candidate pixel Ip plus a threshold t, or all darker than Ip − t, as illustrated in Figure 1. n was chosen to be twelve because it admits a high-speed test which can be used to exclude a very large number of non-corners: the test examines only the four pixels at 1, 5, 9 and 13 (the four compass directions). If p is a corner then at least three of these must all be brighter than Ip + t or darker than Ip − t. If neither of these is the case, then p cannot be a corner. The full segment test criterion can then be applied to the remaining candidates by examining all pixels in the circle.

I'd recommend experimenting with different values and seeing what varying threshold changes in the output as the good way to understand the meaning/value of the threshold.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.