fixed the bug of interpolation weights.