repihin code, fix thinning sama normalisasi