function cc = check_clouds(uid, FieldID)

pkg load image
	mainPath = strcat(uid, "/");
mainPath = strcat(mainPath,FieldID);
filenametci = strcat(mainPath,"/ETCI.png");
tci = imread(filenametci);
	try
		%%TCIgray = rgb2gray(tci);
		sizegray = size(tci);
		graycount = 0;
		for i = 1:sizegray(1)
			for j = 1:sizegray(2)
				pixel_r = tci(i,j,1);
				pixel_g = tci(i,j,2);
				pixel_b = tci(i,j,3);
				if (pixel_r + pixel_g + pixel_b) >660
					graycount=graycount+1;
				end
				
			end
		end
		graycount
		pixelcount = sizegray(1)*sizegray(2)
		if(graycount>0.5*pixelcount)
			cc = 2
			result_status2 = 'Too much cloud in cropped tci image'
			return
		end

		cc = 0
		return
	catch
		cc = 2
		aa = 'too much cloud'
		return
end
end
	

