{"action":"opened","issue":{"url":"https://api.github.com/repos/stnava/ANTs/issues/376","repository_url":"https://api.github.com/repos/stnava/ANTs","labels_url":"https://api.github.com/repos/stnava/ANTs/issues/376/labels{/name}","comments_url":"https://api.github.com/repos/stnava/ANTs/issues/376/comments","events_url":"https://api.github.com/repos/stnava/ANTs/issues/376/events","html_url":"https://github.com/stnava/ANTs/issues/376","id":185958608,"number":376,"title":"Smoothing Sigmas in Physical Space and High Resolution Images - A solution proposal","user":{"login":"gdevenyi","id":3001850,"avatar_url":"https://avatars.githubusercontent.com/u/3001850?v=3","gravatar_id":"","url":"https://api.github.com/users/gdevenyi","html_url":"https://github.com/gdevenyi","followers_url":"https://api.github.com/users/gdevenyi/followers","following_url":"https://api.github.com/users/gdevenyi/following{/other_user}","gists_url":"https://api.github.com/users/gdevenyi/gists{/gist_id}","starred_url":"https://api.github.com/users/gdevenyi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gdevenyi/subscriptions","organizations_url":"https://api.github.com/users/gdevenyi/orgs","repos_url":"https://api.github.com/users/gdevenyi/repos","events_url":"https://api.github.com/users/gdevenyi/events{/privacy}","received_events_url":"https://api.github.com/users/gdevenyi/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-10-28T15:55:20Z","updated_at":"2016-10-28T15:55:20Z","closed_at":null,"body":"A challenge I'm running into for a tool I'm writing is getting antsRegistration to do the same thing regardless of the input resolution of the scans.\r\n\r\nThis comes from two problems\r\n1) Shrink factors reduce the resolution by downsampling, but have no sense of actual input resolution\r\n\r\nI fixed this by checking the input resolution and computing my shrink factors to target physical space sampling values I want based on the resolution of the input.\r\n\r\nNow I run into issues with smoothing: I can specify smoothing sigmas in real space (aka mm resolution) however, for high resolution images, I frequently run into this:\r\n```sh\r\nWARNING: In /opt/quarantine/ANTs/git/src/build/ITKv4-install/include/ITK-4.11/itkGaussianOperator.hxx, line 61\r\nGaussianOperator (0x7fffdcae62b0): Kernel size has exceeded the specified maximum width of 32 and has been truncated to 33 elements.  You can raise the maximum width using the SetMaximumKernelWidth method.\r\n```\r\n\r\nThis is for a smoothing of 16mm FWHM\r\n\r\nAfter much reading through layers of code, I determined that it looks look I'm running into the default maximum kernel size of ``DiscreteGaussianImageFilter``, which is used inside ``ImageRegistrationMethodv4``.\r\n\r\nTo see if I could resolve this, I insterted SetMaximumKernelWidth( 64 )\r\nafter\r\nhttps://github.com/InsightSoftwareConsortium/ITK/blob/30206c0ec0cfecb6df9dec22e9a54e98463189db/Modules/Registration/RegistrationMethodsv4/include/itkImageRegistrationMethodv4.hxx#L619\r\nand\r\nhttps://github.com/InsightSoftwareConsortium/ITK/blob/30206c0ec0cfecb6df9dec22e9a54e98463189db/Modules/Registration/RegistrationMethodsv4/include/itkImageRegistrationMethodv4.hxx#L637\r\n\r\nThis resolved the issue down to 0.4mm, however, at 0.3mm, my highest res data I still ran into the above warning.\r\n\r\nChanging to SetMaximumKernelWidth( 128 ) resolves the issue at 0.3mm.\r\n\r\nObviously, blurring takes longer now since the kernel is no longer truncated.\r\n\r\n\r\nWhat do you think of such a proposed change to the registration internals? In general it should have no impact except for those people running into these issues."}}
{"actor":{"display_login":"gdevenyi"}}