fixed small bug in gemv_contract_shape function