Added img. averaging