color = imread('319_road_new.jpg');
gray = rgb2gray(color);
image(gray);
%gray
for i_1 = 1:700
    for i_2 = 1:1200
        if gray(i_1,i_2) ~= 0
            gray(i_1, i_2) = 255;
        else
            gray(i_1,i_2) = 0;
        end
    end
end
image(gray)
imwrite(gray, 'road_mask_new.jpg')
gray = double(gray./255);
save 'road_mask' gray