debuged clustering mode