nianticlabs/manydepth

about confidence_mask

biggiantpigeon opened this issue · 2 comments

I don't think I understand what confidence_mask is and what is this function doing:

    def compute_confidence_mask(self, cost_volume, num_bins_threshold=None):
        """ Returns a 'confidence' mask based on how many times a depth bin was observed"""

        if num_bins_threshold is None:
            num_bins_threshold = self.num_depth_bins
        confidence_mask = ((cost_volume > 0).sum(1) == num_bins_threshold).float()

        return confidence_mask

Is this just the same with 1-missing_mask?
Can you please explain it? Or does this have any explanation in the paper? Thanks!

Hi, and thanks for your interest!

Ah yes this confidence mask is is not something which is mentioned in the paper, and is code left in from an experiment which didn't really change anything.

This mask is finding pixels for which all bins have a valid value - i.e. they reproject inside the lookup image for all depth bins. For KITTI, this will be almost all pixels since the camera generally moves in a forward motion.

I hope this helps, and let me know if you have any further questions.

Thanks again!

can I ask another question about the final matching mask here? I notice from some picture produce strange matching mask(which in the end, will be multiplied to the final consistency mask), and here is my result:
image
image
yet for most images, the matching mask is mostly white(valid). Is this normal or something is wrong?