Re: [Freesurfer] Longitudinal Freesurfer in the presence of large tissue defects

2024-03-04 Thread Philip P
External Email - Use Caution

Thanks Malte, that is very helpful ! 

> On 01.03.2024, at 08:20, Hoffmann, Malte,PhD  
> wrote:
> 
> If you construct the non-linear template within the current rigid (or affine) 
> mid-space, then there are two things you can do.
> 
> (1) You can just replace the base image and run the remainder of the base and 
> longitudinal streams as is to transfer the results out to the TPs using the 
> rigid (or affine) LTAs. This is what we did in the abstract, showing 
> improvements with a better-quality base image that can lead to better 
> longitudinal initialization.
> 
> (2) On top of this, you can use the warps to initialize the longitudinal TPs 
> as you suggest. Unfortunately, we found that this does not always improve 
> things. For example, volumetric warps are often not that great around the 
> cortex, and initializing the longitudinal surfaces with warps instead of the 
> LTAs turned out to be detrimental when I looked into this.
> 
> In principle, we adapted the steps of the longitudinal stream to accept warps 
> but it’s been several years and I’ve not kept track of changes. If you’re up 
> for the challenge, mri_warp_convert --outmgzwarp/--outm3z can be helpful 
> depending on how you estimate your warps.
> 
> 
> From: Philip P mailto:philip.pruck...@gmail.com>>
> Sent: Wednesday, February 28, 2024 20:41
> To: Hoffmann, Malte,PhD
> Cc: freesurfer@nmr.mgh.harvard.edu <mailto:freesurfer@nmr.mgh.harvard.edu>
> Subject: Re: [Freesurfer] Longitudinal Freesurfer in the presence of large 
> tissue defects
> 
>External Email - Use Caution
> 
> Hi Malte,
> 
> Thanks for the response, it’s encouraging to hear you think the longitudinal 
> pipeline will still provide benefits, even in the absence of a non-linear 
> template!
> 
> However out of interest: I was able to generate a non-linear unbiased session 
> template without moving tissue from outside into the resection area. If I’d 
> want to use this template for the analysis, is there any modifications I’d 
> have to make to the existing workflow except for 1) using the non-linear 
> template as norm_template.mgz and 2) running all commands that make use of 
> the session_to_template.lta transforms with the appropriate non-linear warps?
> 
> Thanks for your help, its greatly appreciated !
> 
> Best,
> Philip
> 
> 
>> On 27.02.2024, at 08:42, Hoffmann, Malte,PhD  
>> wrote:
>> 
>> Hi Philip,
>> 
>> The deformable template was most beneficial when differences between time 
>> points (TPs) were largest. While this is perhaps not surprising, it meant 
>> that the long registration time of 8h/TP in the abstract was not time well 
>> spent since we were already certain of group differences.
>> 
>> We generally recommend the longitudinal stream for longitudinal data since 
>> much information is shared between the TPs. The median rigid template is 
>> typically a robust starting point for the processing of the individual TPs, 
>> sometimes even for developmental studies where you see the size of the brain 
>> increase.
>> 
>> In your specific case, non-linear registration (using an image-intensity 
>> objective like in the abstract) might be detrimental. The algorithm will 
>> likely move tissue from outside the resected area into this area since the 
>> scan before resection will have matching intensities there, but this won’t 
>> necessarily make for a good template.
>> 
>> Malte
>> 
>> 
>> From: freesurfer-boun...@nmr.mgh.harvard.edu 
>>  on behalf of Philip P 
>> 
>> Sent: Sunday, February 4, 2024 01:48
>> To: freesurfer@nmr.mgh.harvard.edu
>> Subject: [Freesurfer] Longitudinal Freesurfer in the presence of large  
>> tissue defects
>> 
>>   External Email - Use Caution
>> 
>> Dear Freesurfer Developers,
>> 
>> I am currently running the Longitudinal Pipeline on a cohort with 
>> significant portions of brain tissue removed. The obtained base templates 
>> overall look reasonable, however, when overlaying the transformed session 
>> T1ws and flicking between them, there still are noticeable residual 
>> differences. This is not surprising, given the inevitable brain shift after 
>> tissue removal, which rigid registration cannot account for. In my search 
>> for a non-linear base template option I came across the "Longitudinal 
>> FreeSurfer with non-linear subject-specific template improves sensitivity to 
>> cortical thinning” ISMRM abstract (MailScanner has detected a possible f

Re: [Freesurfer] Longitudinal Freesurfer in the presence of large tissue defects

2024-02-29 Thread Hoffmann, Malte,PhD
If you construct the non-linear template within the current rigid (or affine) 
mid-space, then there are two things you can do.

(1) You can just replace the base image and run the remainder of the base and 
longitudinal streams as is to transfer the results out to the TPs using the 
rigid (or affine) LTAs. This is what we did in the abstract, showing 
improvements with a better-quality base image that can lead to better 
longitudinal initialization.

(2) On top of this, you can use the warps to initialize the longitudinal TPs as 
you suggest. Unfortunately, we found that this does not always improve things. 
For example, volumetric warps are often not that great around the cortex, and 
initializing the longitudinal surfaces with warps instead of the LTAs turned 
out to be detrimental when I looked into this.

In principle, we adapted the steps of the longitudinal stream to accept warps 
but it’s been several years and I’ve not kept track of changes. If you’re up 
for the challenge, mri_warp_convert --outmgzwarp/--outm3z can be helpful 
depending on how you estimate your warps.


From: Philip P 
Sent: Wednesday, February 28, 2024 20:41
To: Hoffmann, Malte,PhD
Cc: freesurfer@nmr.mgh.harvard.edu
Subject: Re: [Freesurfer] Longitudinal Freesurfer in the presence of large 
tissue defects

External Email - Use Caution

Hi Malte,

Thanks for the response, it’s encouraging to hear you think the longitudinal 
pipeline will still provide benefits, even in the absence of a non-linear 
template!

However out of interest: I was able to generate a non-linear unbiased session 
template without moving tissue from outside into the resection area. If I’d 
want to use this template for the analysis, is there any modifications I’d have 
to make to the existing workflow except for 1) using the non-linear template as 
norm_template.mgz and 2) running all commands that make use of the 
session_to_template.lta transforms with the appropriate non-linear warps?

Thanks for your help, its greatly appreciated !

Best,
Philip


> On 27.02.2024, at 08:42, Hoffmann, Malte,PhD  
> wrote:
>
> Hi Philip,
>
> The deformable template was most beneficial when differences between time 
> points (TPs) were largest. While this is perhaps not surprising, it meant 
> that the long registration time of 8h/TP in the abstract was not time well 
> spent since we were already certain of group differences.
>
> We generally recommend the longitudinal stream for longitudinal data since 
> much information is shared between the TPs. The median rigid template is 
> typically a robust starting point for the processing of the individual TPs, 
> sometimes even for developmental studies where you see the size of the brain 
> increase.
>
> In your specific case, non-linear registration (using an image-intensity 
> objective like in the abstract) might be detrimental. The algorithm will 
> likely move tissue from outside the resected area into this area since the 
> scan before resection will have matching intensities there, but this won’t 
> necessarily make for a good template.
>
> Malte
>
> 
> From: freesurfer-boun...@nmr.mgh.harvard.edu 
>  on behalf of Philip P 
> 
> Sent: Sunday, February 4, 2024 01:48
> To: freesurfer@nmr.mgh.harvard.edu
> Subject: [Freesurfer] Longitudinal Freesurfer in the presence of large  
> tissue defects
>
>External Email - Use Caution
>
> Dear Freesurfer Developers,
>
> I am currently running the Longitudinal Pipeline on a cohort with significant 
> portions of brain tissue removed. The obtained base templates overall look 
> reasonable, however, when overlaying the transformed session T1ws and 
> flicking between them, there still are noticeable residual differences. This 
> is not surprising, given the inevitable brain shift after tissue removal, 
> which rigid registration cannot account for. In my search for a non-linear 
> base template option I came across the "Longitudinal FreeSurfer with 
> non-linear subject-specific template improves sensitivity to cortical 
> thinning” ISMRM abstract (MailScanner has detected a possible fraud attempt 
> from "secure-web.cisco.com" claiming to be 
> https://secure-web.cisco.com/1bhEHVI_wdXl_mLwpwWSqHCKW0qpfVsSGTa6OP2rDyN8h_SQEuJtTL1Bp8YHjzANH8rsJ5sHIKLq7gAJkuuM1H86WIChMxaXgBgvC2iC23AkgfntCssGgMBcVDMPxb9gn52JM9bgfoJaxbhQwk1R2GUVh9k8AoCqP0Uc1dMX-m5ylU3pAHt_8VSh3VKdxbIvAyrumtnw-Gf9v0BLOZa_9jipH4onGhWJgrfzHlsy0zeP37uvHSdD9Fp97Yylqub0ewbCWh-7EmuM0plUYwvrQ17rurRUtYfR3yAY1Pbka7nqV0sAeG7DU_HMt11igojv_/https%3A%2F%2Farchive.ismrm.org%2F2020%2F1050.html<https://secure-web.cisco.com/1me4RY0enlek75e3PAqIseSGOO7tfF84eBwPlWXYndHKO5G2tJAD

Re: [Freesurfer] Longitudinal Freesurfer in the presence of large tissue defects

2024-02-28 Thread Philip P
External Email - Use Caution

Hi Malte, 

Thanks for the response, it’s encouraging to hear you think the longitudinal 
pipeline will still provide benefits, even in the absence of a non-linear 
template! 

However out of interest: I was able to generate a non-linear unbiased session 
template without moving tissue from outside into the resection area. If I’d 
want to use this template for the analysis, is there any modifications I’d have 
to make to the existing workflow except for 1) using the non-linear template as 
norm_template.mgz and 2) running all commands that make use of the 
session_to_template.lta transforms with the appropriate non-linear warps? 

Thanks for your help, its greatly appreciated !

Best, 
Philip 


> On 27.02.2024, at 08:42, Hoffmann, Malte,PhD  
> wrote:
> 
> Hi Philip,
> 
> The deformable template was most beneficial when differences between time 
> points (TPs) were largest. While this is perhaps not surprising, it meant 
> that the long registration time of 8h/TP in the abstract was not time well 
> spent since we were already certain of group differences.
> 
> We generally recommend the longitudinal stream for longitudinal data since 
> much information is shared between the TPs. The median rigid template is 
> typically a robust starting point for the processing of the individual TPs, 
> sometimes even for developmental studies where you see the size of the brain 
> increase.
> 
> In your specific case, non-linear registration (using an image-intensity 
> objective like in the abstract) might be detrimental. The algorithm will 
> likely move tissue from outside the resected area into this area since the 
> scan before resection will have matching intensities there, but this won’t 
> necessarily make for a good template.
> 
> Malte
> 
> 
> From: freesurfer-boun...@nmr.mgh.harvard.edu 
>  on behalf of Philip P 
> 
> Sent: Sunday, February 4, 2024 01:48
> To: freesurfer@nmr.mgh.harvard.edu
> Subject: [Freesurfer] Longitudinal Freesurfer in the presence of large  
> tissue defects
> 
>External Email - Use Caution
> 
> Dear Freesurfer Developers,
> 
> I am currently running the Longitudinal Pipeline on a cohort with significant 
> portions of brain tissue removed. The obtained base templates overall look 
> reasonable, however, when overlaying the transformed session T1ws and 
> flicking between them, there still are noticeable residual differences. This 
> is not surprising, given the inevitable brain shift after tissue removal, 
> which rigid registration cannot account for. In my search for a non-linear 
> base template option I came across the "Longitudinal FreeSurfer with 
> non-linear subject-specific template improves sensitivity to cortical 
> thinning” ISMRM abstract (MailScanner has detected a possible fraud attempt 
> from "secure-web.cisco.com" claiming to be 
> https://secure-web.cisco.com/17N_xqg9IuaXhy0eeSRmExNHOVIHuG1VhD7ehDfM9lhAHQx1DjHxZBZOkIMpkZZmaQvKpod_U13FTUEv4Mjlf_zxtBMz1pQDVTSG1Ftye1JN4xO5M5SG4U9BUMa6MFgUFqBl5WtH2iRGieDTWRqoo8pvi4rCDtBE39N59hFeqN8U5vIB60L2hdNZJDtYXE52DhMQ0DXrzAslz3D1MWe2BGQ_pFz6OGMDL62b5vwC629XpD8V8-BX-ErWqw9btxdnEjeXaz1ok0rmjvz_gpZ-RZtp6dXP-PN-niavD-_2ptdlhNpMhri8khgegNPA8q9FJBtKH9dC14pJoywm04FJvMQ/https%3A%2F%2Farchive.ismrm.org%2F2020%2F1050.html)
>  as well as related code on Github (MailScanner has detected a possible fraud 
> attempt from "secure-web.cisco.com" claiming to be 
> https://secure-web.cisco.com/1kHilcnCgkwQrldX6iuJ88RE0UoXG5EVoDzuvrFNtUvMJmI9NVVlU6hLHzV_16j7zCxcIDLMuv0QWeoIUrIxm-VtU7KHbMv7W5aY14QjqJxZnIy61sXLVxGMS9GwOY_P3gKjaPcVtShNSu944zWe8iRW5SqV6JQSeH0YxD8k4cElitgB30TuChwpCxpOZ7LUEvF-eEIsdaBtKcwxqt_LJ6MMWVcWrgi26xNlZvTsutJN2trCkbxFFUlWcw3nXbb6HggJx8gWErRDsEpYDA3cNU1OVgY2z1JTDsjOdzUPetcyO-CxasSZ0zIuz5mcBWsGny_ziEMeOR
AnZeds3EIeBhQ/https%3A%2F%2Fgithub.com%2Fmu40%2Ffreesurfer%2Ftree%2Fnf-long-nonlin).
> 
> I was wondering whether you could provide insights into what you think the 
> best strategy for obtaining reliable longitudinal cortical thickness 
> measurements in such a dataset. Do you have a feel 

Re: [Freesurfer] Longitudinal Freesurfer in the presence of large tissue defects

2024-02-26 Thread Hoffmann, Malte,PhD
Hi Philip,

The deformable template was most beneficial when differences between time 
points (TPs) were largest. While this is perhaps not surprising, it meant that 
the long registration time of 8h/TP in the abstract was not time well spent 
since we were already certain of group differences.

We generally recommend the longitudinal stream for longitudinal data since much 
information is shared between the TPs. The median rigid template is typically a 
robust starting point for the processing of the individual TPs, sometimes even 
for developmental studies where you see the size of the brain increase.

In your specific case, non-linear registration (using an image-intensity 
objective like in the abstract) might be detrimental. The algorithm will likely 
move tissue from outside the resected area into this area since the scan before 
resection will have matching intensities there, but this won’t necessarily make 
for a good template.

Malte


From: freesurfer-boun...@nmr.mgh.harvard.edu 
 on behalf of Philip P 

Sent: Sunday, February 4, 2024 01:48
To: freesurfer@nmr.mgh.harvard.edu
Subject: [Freesurfer] Longitudinal Freesurfer in the presence of large  tissue 
defects

External Email - Use Caution

Dear Freesurfer Developers,

I am currently running the Longitudinal Pipeline on a cohort with significant 
portions of brain tissue removed. The obtained base templates overall look 
reasonable, however, when overlaying the transformed session T1ws and flicking 
between them, there still are noticeable residual differences. This is not 
surprising, given the inevitable brain shift after tissue removal, which rigid 
registration cannot account for. In my search for a non-linear base template 
option I came across the "Longitudinal FreeSurfer with non-linear 
subject-specific template improves sensitivity to cortical thinning” ISMRM 
abstract (MailScanner has detected a possible fraud attempt from 
"secure-web.cisco.com" claiming to be 
https://archive.ismrm.org/2020/1050.html)
 as well as related code on Github (MailScanner has detected a possible fraud 
attempt from "secure-web.cisco.com" claiming to be 
https://github.com/mu40/freesurfer/tree/nf-long-nonlin).

I was wondering whether you could provide insights into what you think the best 
strategy for obtaining reliable longitudinal cortical thickness measurements in 
such a dataset. Do you have a feel for whether the Longitudinal Freesurfer 
processing stream still provides benefits over Cross-Sectional analysis in the 
presence of large defects? Would you recommend giving the above-mentioned 
non-linear implementation a shot or were there other reasons the feature has 
not been implemented yet in the official version?

Thanks already in advance!

Best

Philip

___
Freesurfer mailing list
Freesurfer@nmr.mgh.harvard.edu
https://mail.nmr.mgh.harvard.edu/mailman/listinfo/freesurfer
The information in this e-mail is intended only for the person to whom it is 
addressed.  If you believe this e-mail was sent to you in error and the e-mail 
contains patient information, please contact the Mass General Brigham 
Compliance HelpLine at https://www.massgeneralbrigham.org/complianceline 
 .
Please note that this e-mail is not secure (encrypted).  If you do not wish to 
continue communication over unencrypted e-mail, please notify the sender of 
this message immediately.  Continuing to send or respond to e-mail after 
receiving this message means you understand and accept this risk and wish to 
continue to communicate over unencrypted e-mail.