{"action":"created","issue":{"url":"https://api.github.com/repos/InsightSoftwareConsortium/ITKMinimalPathExtraction/issues/61","repository_url":"https://api.github.com/repos/InsightSoftwareConsortium/ITKMinimalPathExtraction","labels_url":"https://api.github.com/repos/InsightSoftwareConsortium/ITKMinimalPathExtraction/issues/61/labels{/name}","comments_url":"https://api.github.com/repos/InsightSoftwareConsortium/ITKMinimalPathExtraction/issues/61/comments","events_url":"https://api.github.com/repos/InsightSoftwareConsortium/ITKMinimalPathExtraction/issues/61/events","html_url":"https://github.com/InsightSoftwareConsortium/ITKMinimalPathExtraction/issues/61","id":432477765,"node_id":"MDU6SXNzdWU0MzI0Nzc3NjU=","number":61,"title":"Gradient sometimes zero (which prevents a gradient decent optimizer from decenting)","user":{"login":"romangrothausmann","id":10707398,"node_id":"MDQ6VXNlcjEwNzA3Mzk4","avatar_url":"https://avatars3.githubusercontent.com/u/10707398?v=4","gravatar_id":"","url":"https://api.github.com/users/romangrothausmann","html_url":"https://github.com/romangrothausmann","followers_url":"https://api.github.com/users/romangrothausmann/followers","following_url":"https://api.github.com/users/romangrothausmann/following{/other_user}","gists_url":"https://api.github.com/users/romangrothausmann/gists{/gist_id}","starred_url":"https://api.github.com/users/romangrothausmann/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/romangrothausmann/subscriptions","organizations_url":"https://api.github.com/users/romangrothausmann/orgs","repos_url":"https://api.github.com/users/romangrothausmann/repos","events_url":"https://api.github.com/users/romangrothausmann/events{/privacy}","received_events_url":"https://api.github.com/users/romangrothausmann/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2019-04-12T09:40:17Z","updated_at":"2019-04-16T08:01:03Z","closed_at":"2019-04-13T19:34:09Z","author_association":"CONTRIBUTOR","body":"I have experienced many cases where I can extract a path with the [IterateNeighborhoodOptimizer](https://itk.org/Doxygen/html/classitk_1_1IterateNeighborhoodOptimizer.html) but where the [GradientDescentOptimizer](https://itk.org/Doxygen/html/classitk_1_1GradientDescentOptimizer.html) does not start to decent even though the speed function is continuous, apparently because the initial local gradient is calculated to be zero (even though start- and end-point, speed function etc are kept the same).\r\nI have a vague feeling that this thresholding:\r\nhttps://github.com/InsightSoftwareConsortium/ITKMinimalPathExtraction/blob/6ae35b9d044ff2be22ce42776c64258be9252313/include/itkSingleImageCostFunction.hxx#L145-L152\r\nto a hard coded value of `15.0`:\r\nhttps://github.com/InsightSoftwareConsortium/ITKMinimalPathExtraction/blob/6ae35b9d044ff2be22ce42776c64258be9252313/include/itkSingleImageCostFunction.hxx#L140\r\ncould be the culprit.\r\n\r\nAnother possible reason I could imagine is that the floating point precision might not suffice under some circumstances to calculate a non-zero gradient even if there is no extrema in the cost function at the current optimizer position."},"comment":{"url":"https://api.github.com/repos/InsightSoftwareConsortium/ITKMinimalPathExtraction/issues/comments/483554304","html_url":"https://github.com/InsightSoftwareConsortium/ITKMinimalPathExtraction/issues/61#issuecomment-483554304","issue_url":"https://api.github.com/repos/InsightSoftwareConsortium/ITKMinimalPathExtraction/issues/61","id":483554304,"node_id":"MDEyOklzc3VlQ29tbWVudDQ4MzU1NDMwNA==","user":{"login":"romangrothausmann","id":10707398,"node_id":"MDQ6VXNlcjEwNzA3Mzk4","avatar_url":"https://avatars3.githubusercontent.com/u/10707398?v=4","gravatar_id":"","url":"https://api.github.com/users/romangrothausmann","html_url":"https://github.com/romangrothausmann","followers_url":"https://api.github.com/users/romangrothausmann/followers","following_url":"https://api.github.com/users/romangrothausmann/following{/other_user}","gists_url":"https://api.github.com/users/romangrothausmann/gists{/gist_id}","starred_url":"https://api.github.com/users/romangrothausmann/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/romangrothausmann/subscriptions","organizations_url":"https://api.github.com/users/romangrothausmann/orgs","repos_url":"https://api.github.com/users/romangrothausmann/repos","events_url":"https://api.github.com/users/romangrothausmann/events{/privacy}","received_events_url":"https://api.github.com/users/romangrothausmann/received_events","type":"User","site_admin":false},"created_at":"2019-04-16T08:01:03Z","updated_at":"2019-04-16T08:01:03Z","author_association":"CONTRIBUTOR","body":"While testing that #62 works as expected, even setting DerivativeThreshold of 1e9 did not solve the issue reported here, that under some (unknown) circumstances no gradient decent optimizer starts to run, apparently because the computed gradient is zero even though the IterateNeighborhoodOptimizer does find lower values even with the same step-size.\r\n@thewtex Any idea what could cause this? Can you re-open the issue (I can't)?"}}
{"actor":{"display_login":"romangrothausmann"}}