fixed a bug of haar.

Fixed some bugs of haar.