Ask Your Question
-1

object detection using pixel value

asked 2020-06-05 23:16:36 -0600

Farid.dem gravatar image

updated 2020-06-06 02:02:01 -0600

berak gravatar image

hi i need to detect cloud shadow using pixel values the condtion is

450<band8<775 IF it's true === cloud shadow
edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
2

answered 2020-06-06 02:11:15 -0600

berak gravatar image

it's doubtful, that your "object detection" will work, but applying the "condition" is not so hard:

Mat data = ... // single channel input;

Mat lo = data > 450; 
Mat hi = data < 775;

Mat shadow = lo & hi; // bitwise_and

resulting in a "mask", where "shadow pixels" are 255 and the rest is 0

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2020-06-05 23:16:36 -0600

Seen: 125 times

Last updated: Jun 06 '20