fix dimension error