minor channges to make clustering resetable