)]}'
{
  "commit": "9064b4ed276c286499fa0e10824601a47a19392d",
  "tree": "70668cc29220316e235774669f5df19de2198553",
  "parents": [
    "967122def6fea54d36df4294a0275e88c0ff46d9"
  ],
  "author": {
    "name": "Sameer Agarwal",
    "email": "sandwichmaker@gmail.com",
    "time": "Wed May 13 21:13:19 2015 -0700"
  },
  "committer": {
    "name": "Sameer Agarwal",
    "email": "sameeragarwal@google.com",
    "time": "Wed May 13 21:37:15 2015 -0700"
  },
  "message": "Improve numeric differentation near zero.\n\nBefore this change, the default step size\nfor a function F(x) at x was\n\nstep_size \u003d |x| * relative_step_size\n\nif step_size was exactly zero, then to prevent\ndivision by zero we would fall back to relative_step_size.\n\nThis however is not good enough, as values of x say 1e-64\nwould lead to step sizes ~ 1e-70 and dividing by such numbers\nleads to inaccurate results. For even smaller numbers, like\n1e-300, which I have observed can occur as the optimization\nalgorithm makes progress, this leads to NaNs.\n\nThe key change in this CL is to change the fallback mechanism\nto be\n\nstep_size \u003d max(|x| * relative_step_size, min_step_size)\n\nwhere\n\nmin_step_size \u003d sqrt(DBL_EPSILON)\n\nThis is the recommended minimum value for the step size\nfor double precision arithmetic on the interwebs.\n\nThis results in a small loss of precision in the transcendental\nfunctions test, but that is unavoidable as we are not taking\nsufficiently small steps anymore.\n\nOn the whole though this will improve the numerical performance\nof the algorithm.\n\nTo validate this approach, one of the parameter values for the\nEasyFunctorTest has been set to 1e-64, which causes the test\nto start failing without the corrected fallback logic.\n\nThis change should also address some if not all of\n\nhttps://github.com/ceres-solver/ceres-solver/issues/121\n\nChange-Id: I4a9013ef358626c1ba7b8abad60b3904163d63f6\n",
  "tree_diff": [
    {
      "type": "modify",
      "old_id": "d220c7cf181a854bfd2c8302f12c90d06c04db44",
      "old_mode": 33188,
      "old_path": "include/ceres/internal/numeric_diff.h",
      "new_id": "da04a8ddbed02d9cb97f5b6c7137b4b95623c47f",
      "new_mode": 33188,
      "new_path": "include/ceres/internal/numeric_diff.h"
    },
    {
      "type": "modify",
      "old_id": "95d1da53a53c3bb1b0315747fb3cc74aa228044a",
      "old_mode": 33188,
      "old_path": "internal/ceres/numeric_diff_test_utils.cc",
      "new_id": "55954497c1c38434453192371498cffbe1df0024",
      "new_mode": 33188,
      "new_path": "internal/ceres/numeric_diff_test_utils.cc"
    }
  ]
}
