lk_least_squares seems to be working