try
	RVI = single(RVI);
	RVI = RVI/255;
	RVI_max = max(max(RVI))
		
	index_new = RVI;
	imgCMP = gen_map1_img(index_new);
	filename = strcat(UID,"/rvi")
	filename=strcat(filename,".png");
	imwrite(uint8(imgCMP),filename);
	imgCMP = gen_map2_img(index_new);
	filename = strcat(UID,"/rvi_cmap2")
	filename=strcat(filename,".png");
	imwrite(uint8(imgCMP),filename);
catch
	aa = 1;
end



try
filename = strcat(UID,"/dem.png");
DEM = imread(filename);
DEM_new = imresize(DEM,[sizeVARI(1),sizeVARI(2)]);
imwrite(DEM_new,filename);
catch
	akkk = 1;
end