Ask Your Question

rt90's profile - activity

2017-04-21 00:53:23 -0600 received badge  Enthusiast
2017-04-20 02:17:38 -0600 commented answer stereo matching, census based

Do you mind if I send you my code and you take a look. maybe you'll see a mistake. Or do you see what I'm doing wrong from the pseudo code?

2017-04-06 08:24:23 -0600 answered a question stereo matching, census based

Hey, I'm still having some troubles but I don't know where my mistake is. I wrote my programm as pseudo code. I pretty sure my code is correct for census, DSI, hamming and aggregation. In the last 2 parts LR - matching & RL-Matching, where I'm searching for the lowest costs (WTA) in the disparities. Did I understand that correct?

load left_img
load right_img

calculate census_left(left_img)
calculate census_right(right_img)

//CALC DSI

for d=0 to N_Disp
    for y=0 to height
        for x=d to width
            DSI[d].data[y*width + x] = hamming_distance(census_left[y*width + x],            
                                                       census_right[y*width + x - d])
        end
    end
end

//aggregate costs 5+5 Boxfilter

for d=0 to N_Disp
    for y=0 to height
        for x=d to width
            sum_pixel = boxfilter(dsi[d].data[y*width + x],5)
            dsi_aggr[d].data[y*width + x] = sum_of_elems_pixel;
        end
    end
end

//LR - matching
disp_costs[N_Disp]
minIndex=0
min2Index=0
for y=0 to height
    for x=0 to width
        for d=0 to N_Disp
            disp_costs[d] = dsi_aggr[d].data[y*width + x + d]
        end 
        find_minimum(disp_costs,&minIndex,&min2Index)

        dsi_min_lr[y*width + x] = minIndex
        calculate_confidence_map_value(cm.data[y*width + x],dsi_aggr[].data[y*width + x],minIndex,min2Index)
    end
end

//RL - matching
for y=0 to height
    for x=0+N_Disp to width
        for d=0 to N_Disp
            disp_costs[d] = dsi_aggr[d].data[y*width + x - d]
        end 
        find_minimum(disp_costs,&minIndex,&min2Index)

        dsi_min_rl[y*width + x] = minIndex
        calculate_confidence_map_value(cm,dsi_aggr,minIndex,min2Index)
    end
end
2017-03-28 08:32:24 -0600 commented answer stereo matching, census based

Ok there is an other paper where they explained it thank you for the information. It helped a lot. I have one more question though. For the Confidence Map I calculate the cost difference between the 2 best disparities from my aggregated cost function. Does it matter for which matching direction I determine the 2 best disparities?

2017-03-10 07:00:39 -0600 received badge  Supporter (source)
2017-03-10 03:41:40 -0600 commented answer stereo matching, census based

I'm not sure I can follow. Because If I look at the block diagram there isn't said that it's multiple direction DSI and DSIaggr. So I have the aggregated costs for my disparties and from that I can get Disparity Maps for both directions? I only see a L->R or R->L matching when calculating the DSI, but this would result in 2 DSI if I do it for both directions... Is there a way to get the other direction if you have one? Because if I add the disparity-levels to the left image, I'm matching L->R? Because that's what I'm doing so far.

2017-03-09 13:19:30 -0600 received badge  Student (source)
2017-03-09 10:53:16 -0600 asked a question stereo matching, census based

Hi I'm currently having trouble to understand a part in this paper :

My Problem is the part after the subpixel calculation on page 17. I don't understand it how to get the subpixel disparity map for both directions. Also I'm a little bit confused if my cost aggregation is correct. It's recommended to use a 5x5 windows and sum the values over this block. Do I sum all values in this 5x5 block or do I add every second in every second row, like I did for the census transformation? Thanks for the help!