def _reassign(check, clusters, base, num):
 check[(check == num)] = base
 clusters[(base - 1)] = np.concatenate((clusters[(base - 1)], clusters[(num - 1)]))
 clusters[(num - 1)] = np.array([], dtype=int)

def _reassign ( check , clusters , base , num ) : check [ ( check == num ) ] = base clusters [ ( base - 1 ) ] = np . concatenate ( ( clusters [ ( base - 1 ) ] , clusters [ ( num - 1 ) ] ) ) clusters [ ( num - 1 ) ] = np . array ( [ ] , dtype = int )
reassign cluster numbers .