added connected components tool