Fix sqrt loss bug.