Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-10-06 Thread Glasser, Matthew
I think if you start doing a lot of HPF you start picking up structured 
artifacts in the data, which may make distinguishing between signal and noise 
more difficult for the ICA.  I'm not aware of any other tests than the one that 
Steve and I did between hp2000 (essentially linear detrend) and hp200.  hp2000 
performed better with ICA+FIX classification and convergence, but the 
confounding variable was that I classified all of the hp2000 and Steve all the 
hp200, so it is possible that I did a better job with the classification too.

Matt.

From: 
mailto:hcp-users-boun...@humanconnectome.org>>
 on behalf of Keith Jamison mailto:kjami...@umn.edu>>
Date: Thursday, October 6, 2016 at 1:35 PM
To: "Xu, Junqian" mailto:junqian...@mssm.edu>>
Cc: HCP Users 
mailto:HCP-Users@humanconnectome.org>>, "Ely, 
Benjamin" mailto:benjamin@mssm.edu>>
Subject: Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

Steve,

Have you found an obvious downside to a shorter HPF cutoff of, say, 200 
seconds?  Would the HCP FIX training data still apply or would the classifier 
need to be retrained?

-Keith


On Thu, Oct 6, 2016 at 12:43 PM, Xu, Junqian 
mailto:junqian...@mssm.edu>> wrote:

> On Oct 4, 2016, at 9:03 PM, Ely, Benjamin 
> mailto:benjamin@mssm.edu>> wrote:
>
> Thanks Steve, that's good to keep in mind. Our acquisition is a single 
> "HCP-like" 15 minute run at MB6, 2.1mm isotropic resolution, TR=1s, AP phase 
> encoding, 32-channel head coil on a 3T Skyra; hopefully that gives us a 
> similar temporal profile.

It's not much about the acquisition protocol (though in the multiband era, MB 
is now related to scanner transmitter stability), but rather the scanner 
stability itself.

> Sounds like I should compare our temporal stability against the HCP's - is 
> there a measure you recommend?

HCP Connectom Skyra scanner has quite small temporal drift and a very linear 
trend (specific to the gradient and body coil hardware characteristics), which 
a typical Skyra can't match. To determine what detrending cutoff you should use 
for your site-specific data, you could run a 5-10min fBIRN phantom scan with 
your fMRI protocol and look at the scanner stability.

___
HCP-Users mailing list
HCP-Users@humanconnectome.org<mailto:HCP-Users@humanconnectome.org>
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


___
HCP-Users mailing list
HCP-Users@humanconnectome.org<mailto:HCP-Users@humanconnectome.org>
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


The materials in this message are private and may contain Protected Healthcare 
Information or other information of a sensitive nature. If you are not the 
intended recipient, be advised that any unauthorized use, disclosure, copying 
or the taking of any action in reliance on the contents of this information is 
strictly prohibited. If you have received this email in error, please 
immediately notify the sender via telephone or return mail.

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-10-06 Thread Keith Jamison
Steve,

Have you found an obvious downside to a shorter HPF cutoff of, say, 200
seconds?  Would the HCP FIX training data still apply or would the
classifier need to be retrained?

-Keith


On Thu, Oct 6, 2016 at 12:43 PM, Xu, Junqian  wrote:

>
> > On Oct 4, 2016, at 9:03 PM, Ely, Benjamin  wrote:
> >
> > Thanks Steve, that's good to keep in mind. Our acquisition is a single
> "HCP-like" 15 minute run at MB6, 2.1mm isotropic resolution, TR=1s, AP
> phase encoding, 32-channel head coil on a 3T Skyra; hopefully that gives us
> a similar temporal profile.
>
> It’s not much about the acquisition protocol (though in the multiband era,
> MB is now related to scanner transmitter stability), but rather the scanner
> stability itself.
>
> > Sounds like I should compare our temporal stability against the HCP's -
> is there a measure you recommend?
>
> HCP Connectom Skyra scanner has quite small temporal drift and a very
> linear trend (specific to the gradient and body coil hardware
> characteristics), which a typical Skyra can’t match. To determine what
> detrending cutoff you should use for your site-specific data, you could run
> a 5-10min fBIRN phantom scan with your fMRI protocol and look at the
> scanner stability.
>
> ___
> HCP-Users mailing list
> HCP-Users@humanconnectome.org
> http://lists.humanconnectome.org/mailman/listinfo/hcp-users
>

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-10-06 Thread Xu, Junqian

> On Oct 4, 2016, at 9:03 PM, Ely, Benjamin  wrote:
> 
> Thanks Steve, that's good to keep in mind. Our acquisition is a single 
> "HCP-like" 15 minute run at MB6, 2.1mm isotropic resolution, TR=1s, AP phase 
> encoding, 32-channel head coil on a 3T Skyra; hopefully that gives us a 
> similar temporal profile.

It’s not much about the acquisition protocol (though in the multiband era, MB 
is now related to scanner transmitter stability), but rather the scanner 
stability itself.

> Sounds like I should compare our temporal stability against the HCP's - is 
> there a measure you recommend?

HCP Connectom Skyra scanner has quite small temporal drift and a very linear 
trend (specific to the gradient and body coil hardware characteristics), which 
a typical Skyra can’t match. To determine what detrending cutoff you should use 
for your site-specific data, you could run a 5-10min fBIRN phantom scan with 
your fMRI protocol and look at the scanner stability.

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-10-06 Thread Xu, Junqian

> On Oct 4, 2016, at 9:03 PM, Ely, Benjamin  wrote:
> 
> Thanks Steve, that's good to keep in mind. Our acquisition is a single 
> "HCP-like" 15 minute run at MB6, 2.1mm isotropic resolution, TR=1s, AP phase 
> encoding, 32-channel head coil on a 3T Skyra; hopefully that gives us a 
> similar temporal profile.

It’s not much about the acquisition protocol (though in the multiband era, MB 
is now related to scanner transmitter stability), but rather the scanner 
stability itself.

> Sounds like I should compare our temporal stability against the HCP's - is 
> there a measure you recommend?

HCP Connectom Skyra scanner has quite small temporal drift and a very linear 
trend (specific to the gradient and body coil hardware characteristics), which 
a typical Skyra can’t match. To determine what detrending cutoff you should use 
for your site-specific data, you could run a 5-10min fBIRN phantom scan with 
your fMRI protocol and look at the scanner stability.

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-10-04 Thread Ely, Benjamin
Hi Michael,

My initial interest was in comparing aggressive vs. soft regression of the 
noise ICs. When I tried simply regressing them out using fsl_regfilt with and 
without the -a flag, though, I realized that my soft denoised file didn't match 
the HCP denoised file, so this became more of an exercise to figure out why. 
Now that I have the FIX scripts running and can replicate the expected 
behavior, I can go back to comparing apples to aggressively denoised apples :)

Thanks again,
-Ely

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-10-04 Thread Ely, Benjamin
Thanks Steve, that's good to keep in mind. Our acquisition is a single 
"HCP-like" 15 minute run at MB6, 2.1mm isotropic resolution, TR=1s, AP phase 
encoding, 32-channel head coil on a 3T Skyra; hopefully that gives us a similar 
temporal profile. Sounds like I should compare our temporal stability against 
the HCP's - is there a measure you recommend?

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-10-04 Thread Harms, Michael

Glad you got it all figured out.  I’m curious though:  was this exercise just 
to understand the various steps internal to FIX (and hcp_fix) or is there some 
more fundamental reason that you can't use those actual scripts for your 
processing?

cheers,
-MH

--
Michael Harms, Ph.D.
---
Conte Center for the Neuroscience of Mental Disorders
Washington University School of Medicine
Department of Psychiatry, Box 8134
660 South Euclid Ave. Tel: 314-747-6173
St. Louis, MO  63110 Email: mha...@wustl.edu

From: 
mailto:hcp-users-boun...@humanconnectome.org>>
 on behalf of "Ely, Benjamin" 
mailto:benjamin@mssm.edu>>
Date: Tuesday, October 4, 2016 at 1:07 AM
To: "Burgess, Gregory" mailto:gburg...@wustl.edu>>, 
"HCP-Users@humanconnectome.org<mailto:HCP-Users@humanconnectome.org>" 
mailto:HCP-Users@humanconnectome.org>>
Subject: Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

Hi Greg,

Thank you very much for your detailed response!

I have now generated a Movement_Regressors.mat file with the correct 24 
parameters (6 rigid body, 6 derivatives, 6 rigid body squared, 6 derivatives 
squared). As I didn't have code handy to run highpass filtering on the movement 
regressors, I based this file on the detrended movement regressors; the HCP's 
highpass filtering is described as "detrending-like", so this should 
(hopefully) give approximately the same result. I also noticed an error in my 
original highpass filtering of the fMRI data that accounts for part of the 
difference I was seeing; the correct sigma is 1389, not 1000 (cutoff = 
2*TR*sigma, so a TR of 0.72s and cutoff of 2000s requires a sigma of 1389; I 
forgot to account for the TR in my original filtering). Between the two, I am 
able to get much closer to matching the HCP's denoised data.

Regarding your second point, I think my setup is removing all of the variance 
in the movement parameters, but not in the noise ICs. fsl_glm, which is how I 
remove the movement parameters, appears to always do full regression. By 
default, though, fsl_regfilt performs partial regression of the specified noise 
ICs. But the difference regarding movement regression would definitely make a 
difference and seems to be one thing that can't be matched using FSL only.

So yes, this was very informative! Thank you again for your help.
-Ely

___
HCP-Users mailing list
HCP-Users@humanconnectome.org<mailto:HCP-Users@humanconnectome.org>
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


The materials in this message are private and may contain Protected Healthcare 
Information or other information of a sensitive nature. If you are not the 
intended recipient, be advised that any unauthorized use, disclosure, copying 
or the taking of any action in reliance on the contents of this information is 
strictly prohibited. If you have received this email in error, please 
immediately notify the sender via telephone or return mail.

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-10-03 Thread Stephen Smith
Hi Ely - one additoinal point - if you are wanting to apply these pipelines to 
your own data, you may want to change the (very unaggressive, basically just 
detrending as you said) approach to highpass filtering (both in general and for 
use pre-FIX).  I haven't seen many datasets where the "slow" temporal stability 
is as good as we got in HCP, so typically I would expect a shorter highpass 
cutoff to be useful.

Cheers.





> On 4 Oct 2016, at 07:07, Ely, Benjamin  wrote:
> 
> Hi Greg,
> 
> Thank you very much for your detailed response! 
> 
> I have now generated a Movement_Regressors.mat file with the correct 24 
> parameters (6 rigid body, 6 derivatives, 6 rigid body squared, 6 derivatives 
> squared). As I didn't have code handy to run highpass filtering on the 
> movement regressors, I based this file on the detrended movement regressors; 
> the HCP's highpass filtering is described as "detrending-like", so this 
> should (hopefully) give approximately the same result. I also noticed an 
> error in my original highpass filtering of the fMRI data that accounts for 
> part of the difference I was seeing; the correct sigma is 1389, not 1000 
> (cutoff = 2*TR*sigma, so a TR of 0.72s and cutoff of 2000s requires a sigma 
> of 1389; I forgot to account for the TR in my original filtering). Between 
> the two, I am able to get much closer to matching the HCP's denoised data.
> 
> Regarding your second point, I think my setup is removing all of the variance 
> in the movement parameters, but not in the noise ICs. fsl_glm, which is how I 
> remove the movement parameters, appears to always do full regression. By 
> default, though, fsl_regfilt performs partial regression of the specified 
> noise ICs. But the difference regarding movement regression would definitely 
> make a difference and seems to be one thing that can't be matched using FSL 
> only.
> 
> So yes, this was very informative! Thank you again for your help.
> -Ely
> ___
> HCP-Users mailing list
> HCP-Users@humanconnectome.org 
> http://lists.humanconnectome.org/mailman/listinfo/hcp-users 
> 

---
Stephen M. Smith, Professor of Biomedical Engineering
Head of Analysis,  Oxford University FMRIB Centre

FMRIB, JR Hospital, Headington, Oxford  OX3 9DU, UK
+44 (0) 1865 222726  (fax 222717)
st...@fmrib.ox.ac.ukhttp://www.fmrib.ox.ac.uk/~steve 

---

Stop the cultural destruction of Tibet 






___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-10-03 Thread Ely, Benjamin
Hi Greg,

Thank you very much for your detailed response!

I have now generated a Movement_Regressors.mat file with the correct 24 
parameters (6 rigid body, 6 derivatives, 6 rigid body squared, 6 derivatives 
squared). As I didn't have code handy to run highpass filtering on the movement 
regressors, I based this file on the detrended movement regressors; the HCP's 
highpass filtering is described as "detrending-like", so this should 
(hopefully) give approximately the same result. I also noticed an error in my 
original highpass filtering of the fMRI data that accounts for part of the 
difference I was seeing; the correct sigma is 1389, not 1000 (cutoff = 
2*TR*sigma, so a TR of 0.72s and cutoff of 2000s requires a sigma of 1389; I 
forgot to account for the TR in my original filtering). Between the two, I am 
able to get much closer to matching the HCP's denoised data.

Regarding your second point, I think my setup is removing all of the variance 
in the movement parameters, but not in the noise ICs. fsl_glm, which is how I 
remove the movement parameters, appears to always do full regression. By 
default, though, fsl_regfilt performs partial regression of the specified noise 
ICs. But the difference regarding movement regression would definitely make a 
difference and seems to be one thing that can't be matched using FSL only.

So yes, this was very informative! Thank you again for your help.
-Ely

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-10-03 Thread Ely, Benjamin
Hi Michael,

As you proposed, running a modified hcp_fix script that uses the HCP-supplied 
.fix list of bad components yielded results identical to the denoised data 
released by the HCP. I'm glad to have such a clear confirmation that my local 
implementation of ICA-FIX is working correctly! Fully re-running ICA-FIX 
yielded similar but not identical results, with the same number of estimated 
components and a maximum difference of only around 700 units, consistent with 
the expected non-deterministic behavior of MELODIC.

Many thanks for your help,
-Ely

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-09-28 Thread Harms, Michael







Hi Ely,
Maybe I’m missing something, but if you are trying to see if you can duplicate the FIX-denoised file already provided by HCP, wouldn’t it be good to just run a modification of ‘hcp_fix’ itself and see how the results of that compare?  The modification
 would be to comment out the ‘melodic’ call, since melodic is not deterministic, and set up that script instead to use the filtered_func_data.ica that is provided as part of the FIX-extended packages.  I *think* (Steve can correct me if wrong) that everything
 else in FIX should be deterministic.


cheers,
-MH




-- 
Michael Harms, Ph.D.

---
Conte Center for the Neuroscience of Mental Disorders
Washington University School of Medicine
Department of Psychiatry, Box 8134
660 South Euclid Ave. 
Tel: 314-747-6173
St. Louis, MO  63110 
Email: mha...@wustl.edu







From: <hcp-users-boun...@humanconnectome.org> on behalf of Stephen Smith <st...@fmrib.ox.ac.uk>
Date: Tuesday, September 27, 2016 at 8:52 PM
To: "Ely, Benjamin" <benjamin@mssm.edu>, "HCP-Users@humanconnectome.org" <HCP-Users@humanconnectome.org>,
 "Glasser, Matthew" <glass...@wustl.edu>
Subject: Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets





Hi - it sounds like maybe it's working fine within the limits of slight differences in mathematical precision between the C++ vs matlab parts of the processing - so the main question would be - have you looked in a viewer at the difference image
 - e.g. are the voxels with large differences isolated or eg at the edge of the brain?


Cheers.







On 28 Sep 2016, at 02:49, Glasser, Matthew <glass...@wustl.edu> wrote:



I think this is more of a question for the FSL list, but I don’t know fsl_glm well enough to say if what you are doing is equivalent or not.




Peace,




Matt.





From: "Ely, Benjamin" <benjamin@mssm.edu>
Date: Tuesday, September 27, 2016 at 7:20 PM
To: Matt Glasser <glass...@wustl.edu>, "Burgess, Gregory" <gburg...@wustl.edu>,
 "HCP-Users@humanconnectome.org" <HCP-Users@humanconnectome.org>
Subject: Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets






Hi Matt and Greg,


Thanks for the feedback! I've looked at the various fix .m files from the current release; based on fix_3_clean.m, I tried the following for a single resting-state run:




# highpass filter; sigma of 1000.08 = FWHM of 2355 per Smith et al 2013 NeuroImage, also consistent with comments in the fix_3_clean.m script

fslmaths rfMRI_REST1_LR.nii.gz -bptf 1000.08 -1 REST1LR_bp



# format movement parameters (manually corrected header after paste step, not shown)
Text2Vest Movement_Regressors.txt Movement_Regressors.mat
Text2Vest Movement_Regressors.txt Movement_Regressors_dt.mat

paste Movement_Regressors.mat Movement_Regressors_dt.mat > Movement_Regressors_all.mat



# regress movement parameters out of timeseries and re-add mean

fsl_glm -i REST1LR_bp.nii.gz -d Movement_Regressors_all.mat --out_res=REST1LR_bp_mc_demeaned.nii.gz --demean 
fslmaths REST1LR_bp.nii.gz -Tmean REST1LR_bp_mean
fslmaths REST1LR_bp_mc_demeaned.nii.gz -add REST1LR_bp_mean.nii.gz REST1LR_bp_mc


# regress movement parameters out of melodic mix


fsl_glm -i filtered_func_data.ica/melodic_mix -d Movement_Regressors_all.mat --out_res=melodic_mix_mc --demean


# regress unique variance from bad components (taken from .fix file) out of timeseries


fsl_regfilt -i REST1LR_bp_mc.nii.gz -d melodic_mix_mc -o REST1LR_bp_mc_softICA -f "1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 28, 29, 30, 31, 32, 33, 34, 36, 38, 39, 40, 41,
 42, 43, 44, 45, 46, 49, 50, 51, 52, 53, 54, 55, 56, 57, 61, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 81, 82, 83, 84" 


# compare against HCP's released FIX-denoised file
fslmaths rfMRI_REST1_LR_hp2000_clean -sub REST1LR_bp_mc_softICA diff_REST1LR_bp_mc_softICA


Visual inspection and fslstats indicate reasonably good agreement between my denoised file and the HCP's denoised file; the mean difference is about 0.84 units (compared to a mean signal intensity of around
 10,000), and the "robust" range of the difference is about +/- 72 units. More worryingly, though, the maximum difference is around 2000 units, and around 6000 voxels show differences greater than 500 units, so I'm not sure machine precision can account for
 the differences.


Does the above denoising scheme seem consistent with what FIX is doing? I plan to use FIX going forward, rather than trying to replicate it using the FSL command-line, but I'd like
 to understand any discrepancies between the two. 


Thanks again,
-Ely





Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-09-28 Thread Burgess, Gregory
I think there are two problems, either of which could certainly cause large 
differences in the outputs.

> # format movement parameters (manually corrected header after paste step, not 
> shown)
> Text2Vest Movement_Regressors.txt Movement_Regressors.mat
> Text2Vest Movement_Regressors.txt Movement_Regressors_dt.mat
> paste Movement_Regressors.mat Movement_Regressors_dt.mat > 
> Movement_Regressors_all.mat


It appears that you can’t rely entirely on fix_3_clean to understand what has 
happened to HCP FIX :-)  The processing you’re doing to the Movement_Regressors 
differs from “functionmotionconfounds.m”, and appears incorrect to me.

FIX creates 24 motion regressors to remove from the data. Those 24 regressors 
are a) the parameters from the motion correction (6 regressors), b) backward 
derivative of those parameters (6 regressors), c) the square of the parameters 
and backward derivatives (12 regressors).

The Movement_Regressors_all.mat that you've created will not contain those 
regressors. The Movement_Regressors.txt and Movement_Regressors_dt.txt 
effectively contain the same information, except the "dt" file is detrended and 
(I believe) demeaned. However, I never use it because it's using a simple 
linear detrend. You want to detrend the regressors with the 2000s high pass 
filter. This is also done somewhere in the code, to provide a file called 
"mc/prefiltered_func_data_mcf_conf_hp", but I can’t find where that occurs at 
this moment.

> # regress unique variance from bad components (taken from .fix file) out of 
> timeseries
>
>
> fsl_regfilt -i REST1LR_bp_mc.nii.gz -d melodic_mix_mc -o 
> REST1LR_bp_mc_softICA -f "1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 
> 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 28, 29, 30, 31, 32, 33, 34, 36, 
> 38, 39, 40, 41, 42, 43, 44, 45, 46, 49, 50, 51, 52, 53, 54, 55, 56, 57, 61, 
> 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 81, 82, 83, 84”

> # compare against HCP's released FIX-denoised file
>
> fslmaths rfMRI_REST1_LR_hp2000_clean -sub REST1LR_bp_mc_softICA 
> diff_REST1LR_bp_mc_softICA



This doesn’t seem to do what you claim. I believe this is regressing ALL of the 
variance in the noise ICs, hence it is an aggressive regression. To do the soft 
regression, you need to remove from the noise variance all of the variance in 
the motion parameters AND the variance in the signal components. That yields 
the “unique variance” to regress from the timeseries data. I don’t believe you 
are doing that here, therefore, these will not be consistent with the HCP FIX 
pipeline.



> Does the above denoising scheme seem consistent with what FIX is doing? I 
> plan to use FIX going forward, rather than trying to replicate it using the 
> FSL command-line, but I'd like to understand any discrepancies between the 
> two.
>

Hopefully this is been a useful pedagogical exercise! The FIX scripts run in 
octave and matlab, so there shouldn’t be reason to ‘rewrite’ the FIX code in 
fsl commands once you feel that you understand the code.

--Greg


Greg Burgess, Ph.D.
Staff Scientist, Human Connectome Project
Washington University School of Medicine
Department of Psychiatry
Phone: 314-362-7864
Email: gburg...@wustl.edu



The materials in this message are private and may contain Protected Healthcare 
Information or other information of a sensitive nature. If you are not the 
intended recipient, be advised that any unauthorized use, disclosure, copying 
or the taking of any action in reliance on the contents of this information is 
strictly prohibited. If you have received this email in error, please 
immediately notify the sender via telephone or return mail.

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-09-27 Thread Stephen Smith
Hi - it sounds like maybe it's working fine within the limits of slight 
differences in mathematical precision between the C++ vs matlab parts of the 
processing - so the main question would be - have you looked in a viewer at the 
difference image - e.g. are the voxels with large differences isolated or eg at 
the edge of the brain?

Cheers.



> On 28 Sep 2016, at 02:49, Glasser, Matthew  wrote:
> 
> I think this is more of a question for the FSL list, but I don’t know fsl_glm 
> well enough to say if what you are doing is equivalent or not.
> 
> Peace,
> 
> Matt.
> 
> From: "Ely, Benjamin" mailto:benjamin@mssm.edu>>
> Date: Tuesday, September 27, 2016 at 7:20 PM
> To: Matt Glasser mailto:glass...@wustl.edu>>, "Burgess, 
> Gregory" mailto:gburg...@wustl.edu>>, 
> "HCP-Users@humanconnectome.org <mailto:HCP-Users@humanconnectome.org>" 
> mailto:HCP-Users@humanconnectome.org>>
> Subject: Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets
> 
> Hi Matt and Greg,
> 
> Thanks for the feedback! I've looked at the various fix .m files from the 
> current release; based on fix_3_clean.m, I tried the following for a single 
> resting-state run:
> 
> # highpass filter; sigma of 1000.08 = FWHM of 2355 per Smith et al 2013 
> NeuroImage, also consistent with comments in the fix_3_clean.m script
> fslmaths rfMRI_REST1_LR.nii.gz -bptf 1000.08 -1 REST1LR_bp
> 
> # format movement parameters (manually corrected header after paste step, not 
> shown)
> Text2Vest Movement_Regressors.txt Movement_Regressors.mat
> Text2Vest Movement_Regressors.txt Movement_Regressors_dt.mat
> paste Movement_Regressors.mat Movement_Regressors_dt.mat > 
> Movement_Regressors_all.mat
> 
> # regress movement parameters out of timeseries and re-add mean
> fsl_glm -i REST1LR_bp.nii.gz -d Movement_Regressors_all.mat 
> --out_res=REST1LR_bp_mc_demeaned.nii.gz --demean 
> fslmaths REST1LR_bp.nii.gz -Tmean REST1LR_bp_mean
> fslmaths REST1LR_bp_mc_demeaned.nii.gz -add REST1LR_bp_mean.nii.gz 
> REST1LR_bp_mc
> 
> # regress movement parameters out of melodic mix
> 
> fsl_glm -i filtered_func_data.ica/melodic_mix -d Movement_Regressors_all.mat 
> --out_res=melodic_mix_mc --demean
> 
> # regress unique variance from bad components (taken from .fix file) out of 
> timeseries
> 
> fsl_regfilt -i REST1LR_bp_mc.nii.gz -d melodic_mix_mc -o 
> REST1LR_bp_mc_softICA -f "1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 
> 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 28, 29, 30, 31, 32, 33, 34, 36, 
> 38, 39, 40, 41, 42, 43, 44, 45, 46, 49, 50, 51, 52, 53, 54, 55, 56, 57, 61, 
> 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 81, 82, 83, 84" 
> 
> # compare against HCP's released FIX-denoised file
> fslmaths rfMRI_REST1_LR_hp2000_clean -sub REST1LR_bp_mc_softICA 
> diff_REST1LR_bp_mc_softICA
> 
> Visual inspection and fslstats indicate reasonably good agreement between my 
> denoised file and the HCP's denoised file; the mean difference is about 0.84 
> units (compared to a mean signal intensity of around 10,000), and the 
> "robust" range of the difference is about +/- 72 units. More worryingly, 
> though, the maximum difference is around 2000 units, and around 6000 voxels 
> show differences greater than 500 units, so I'm not sure machine precision 
> can account for the differences.
> 
> Does the above denoising scheme seem consistent with what FIX is doing? I 
> plan to use FIX going forward, rather than trying to replicate it using the 
> FSL command-line, but I'd like to understand any discrepancies between the 
> two. 
> 
> Thanks again,
> -Ely
> 
>  
> 
> The materials in this message are private and may contain Protected 
> Healthcare Information or other information of a sensitive nature. If you are 
> not the intended recipient, be advised that any unauthorized use, disclosure, 
> copying or the taking of any action in reliance on the contents of this 
> information is strictly prohibited. If you have received this email in error, 
> please immediately notify the sender via telephone or return mail.
> 
> ___
> HCP-Users mailing list
> HCP-Users@humanconnectome.org <mailto:HCP-Users@humanconnectome.org>
> http://lists.humanconnectome.org/mailman/listinfo/hcp-users 
> <http://lists.humanconnectome.org/mailman/listinfo/hcp-users>

---
Stephen M. Smith, Professor of Biomedical Engineering
Head of Analysis,  Oxford University FMRIB Centre

FMRIB, JR Hospital, Headington, Oxford  OX3 9DU, UK
+44 (0) 1865 222726  (fax 222717)
st...@fmrib.ox.ac.ukhttp://www.fmrib.ox.ac.uk/~steve 
<http://www.fmrib.ox.ac.uk/~steve>
---

Stop the cultural destruction of Tibet <http://smithinks.net/>






___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-09-27 Thread Glasser, Matthew
I think this is more of a question for the FSL list, but I don't know fsl_glm 
well enough to say if what you are doing is equivalent or not.

Peace,

Matt.

From: "Ely, Benjamin" mailto:benjamin@mssm.edu>>
Date: Tuesday, September 27, 2016 at 7:20 PM
To: Matt Glasser mailto:glass...@wustl.edu>>, "Burgess, 
Gregory" mailto:gburg...@wustl.edu>>, 
"HCP-Users@humanconnectome.org<mailto:HCP-Users@humanconnectome.org>" 
mailto:HCP-Users@humanconnectome.org>>
Subject: Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

Hi Matt and Greg,

Thanks for the feedback! I've looked at the various fix .m files from the 
current release; based on fix_3_clean.m, I tried the following for a single 
resting-state run:


# highpass filter; sigma of 1000.08 = FWHM of 2355 per Smith et al 2013 
NeuroImage, also consistent with comments in the fix_3_clean.m script

fslmaths rfMRI_REST1_LR.nii.gz -bptf 1000.08 -1 REST1LR_bp

# format movement parameters (manually corrected header after paste step, not 
shown)
Text2Vest Movement_Regressors.txt Movement_Regressors.mat
Text2Vest Movement_Regressors.txt Movement_Regressors_dt.mat

paste Movement_Regressors.mat Movement_Regressors_dt.mat > 
Movement_Regressors_all.mat

# regress movement parameters out of timeseries and re-add mean

fsl_glm -i REST1LR_bp.nii.gz -d Movement_Regressors_all.mat 
--out_res=REST1LR_bp_mc_demeaned.nii.gz --demean

fslmaths REST1LR_bp.nii.gz -Tmean REST1LR_bp_mean

fslmaths REST1LR_bp_mc_demeaned.nii.gz -add REST1LR_bp_mean.nii.gz REST1LR_bp_mc


# regress movement parameters out of melodic mix

fsl_glm -i filtered_func_data.ica/melodic_mix -d Movement_Regressors_all.mat 
--out_res=melodic_mix_mc --demean


# regress unique variance from bad components (taken from .fix file) out of 
timeseries

fsl_regfilt -i REST1LR_bp_mc.nii.gz -d melodic_mix_mc -o REST1LR_bp_mc_softICA 
-f "1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 
22, 23, 24, 25, 26, 28, 29, 30, 31, 32, 33, 34, 36, 38, 39, 40, 41, 42, 43, 44, 
45, 46, 49, 50, 51, 52, 53, 54, 55, 56, 57, 61, 65, 66, 67, 68, 69, 70, 71, 72, 
73, 74, 75, 76, 77, 78, 79, 81, 82, 83, 84"


# compare against HCP's released FIX-denoised file

fslmaths rfMRI_REST1_LR_hp2000_clean -sub REST1LR_bp_mc_softICA 
diff_REST1LR_bp_mc_softICA


Visual inspection and fslstats indicate reasonably good agreement between my 
denoised file and the HCP's denoised file; the mean difference is about 0.84 
units (compared to a mean signal intensity of around 10,000), and the "robust" 
range of the difference is about +/- 72 units. More worryingly, though, the 
maximum difference is around 2000 units, and around 6000 voxels show 
differences greater than 500 units, so I'm not sure machine precision can 
account for the differences.


Does the above denoising scheme seem consistent with what FIX is doing? I plan 
to use FIX going forward, rather than trying to replicate it using the FSL 
command-line, but I'd like to understand any discrepancies between the two.


Thanks again,

-Ely


The materials in this message are private and may contain Protected Healthcare 
Information or other information of a sensitive nature. If you are not the 
intended recipient, be advised that any unauthorized use, disclosure, copying 
or the taking of any action in reliance on the contents of this information is 
strictly prohibited. If you have received this email in error, please 
immediately notify the sender via telephone or return mail.

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-09-27 Thread Ely, Benjamin
Hi Matt and Greg,

Thanks for the feedback! I've looked at the various fix .m files from the 
current release; based on fix_3_clean.m, I tried the following for a single 
resting-state run:


# highpass filter; sigma of 1000.08 = FWHM of 2355 per Smith et al 2013 
NeuroImage, also consistent with comments in the fix_3_clean.m script

fslmaths rfMRI_REST1_LR.nii.gz -bptf 1000.08 -1 REST1LR_bp

# format movement parameters (manually corrected header after paste step, not 
shown)
Text2Vest Movement_Regressors.txt Movement_Regressors.mat
Text2Vest Movement_Regressors.txt Movement_Regressors_dt.mat

paste Movement_Regressors.mat Movement_Regressors_dt.mat > 
Movement_Regressors_all.mat

# regress movement parameters out of timeseries and re-add mean

fsl_glm -i REST1LR_bp.nii.gz -d Movement_Regressors_all.mat 
--out_res=REST1LR_bp_mc_demeaned.nii.gz --demean

fslmaths REST1LR_bp.nii.gz -Tmean REST1LR_bp_mean

fslmaths REST1LR_bp_mc_demeaned.nii.gz -add REST1LR_bp_mean.nii.gz REST1LR_bp_mc


# regress movement parameters out of melodic mix

fsl_glm -i filtered_func_data.ica/melodic_mix -d Movement_Regressors_all.mat 
--out_res=melodic_mix_mc --demean


# regress unique variance from bad components (taken from .fix file) out of 
timeseries

fsl_regfilt -i REST1LR_bp_mc.nii.gz -d melodic_mix_mc -o REST1LR_bp_mc_softICA 
-f "1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 
22, 23, 24, 25, 26, 28, 29, 30, 31, 32, 33, 34, 36, 38, 39, 40, 41, 42, 43, 44, 
45, 46, 49, 50, 51, 52, 53, 54, 55, 56, 57, 61, 65, 66, 67, 68, 69, 70, 71, 72, 
73, 74, 75, 76, 77, 78, 79, 81, 82, 83, 84"


# compare against HCP's released FIX-denoised file

fslmaths rfMRI_REST1_LR_hp2000_clean -sub REST1LR_bp_mc_softICA 
diff_REST1LR_bp_mc_softICA


Visual inspection and fslstats indicate reasonably good agreement between my 
denoised file and the HCP's denoised file; the mean difference is about 0.84 
units (compared to a mean signal intensity of around 10,000), and the "robust" 
range of the difference is about +/- 72 units. More worryingly, though, the 
maximum difference is around 2000 units, and around 6000 voxels show 
differences greater than 500 units, so I'm not sure machine precision can 
account for the differences.


Does the above denoising scheme seem consistent with what FIX is doing? I plan 
to use FIX going forward, rather than trying to replicate it using the FSL 
command-line, but I'd like to understand any discrepancies between the two.


Thanks again,

-Ely

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-09-16 Thread Glasser, Matthew
Hi Ely,

If you perform the same steps shown in the fix_3_clean.m file on the same data, 
you should get the same results.

Peace,

Matt.

From: 
mailto:hcp-users-boun...@humanconnectome.org>>
 on behalf of "Ely, Benjamin" 
mailto:benjamin@mssm.edu>>
Date: Friday, September 16, 2016 at 12:17 PM
To: "HCP-Users@humanconnectome.org<mailto:HCP-Users@humanconnectome.org>" 
mailto:HCP-Users@humanconnectome.org>>
Subject: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

Hi all,

I ran a test recently comparing "aggressive" vs. "soft" denoising in MELODIC on 
an HCP resting-state run, regressing out the "bad" components found in the 
rfMRI_REST1_LR_hp2000.ica/.fix file (I believe the location of this info is 
different in the newer release but I'm working off HCP500 data). Both denoising 
methods gave similar results which also looked similar to the released HCP 
ICA-FIX denoised timeseries (i.e. rfMRI_REST1_LR_hp2000_clean.nii.gz), but I 
expected the soft denoised MELODIC output to be identical, which it was not. Is 
there a step I'm missing, or did you run the ICA component regression with a 
different tool?

Thank you!
-Ely

___
HCP-Users mailing list
HCP-Users@humanconnectome.org<mailto:HCP-Users@humanconnectome.org>
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


The materials in this message are private and may contain Protected Healthcare 
Information or other information of a sensitive nature. If you are not the 
intended recipient, be advised that any unauthorized use, disclosure, copying 
or the taking of any action in reliance on the contents of this information is 
strictly prohibited. If you have received this email in error, please 
immediately notify the sender via telephone or return mail.

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


Re: [HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-09-16 Thread Burgess, Gregory
The precise process in the FIX pipelines is hopefully clear upon reviewing 
https://github.com/Washington-University/Pipelines/blob/master/ICAFIX/hcp_fix.for_fix1.06a
 (including the FIX subfunctions that it calls).

If you started from a different starting point than the hcp_fix script, there 
are a few candidate reasons why your results might not match the released FIX 
packages.
- read in different motion parameter file
- did not use 2000s highpass filter on data and on motion parameters
- ran your own MELODIC, instead of using the MELODIC ICA output in the FIX 
extended packages (I believe that the FIX scripts re-run / overwrite MELODIC by 
default)

If these don’t seem to be the issue, it might help to know a bit more about how 
the two outputs actually differ. (e.g., Is the difference within machine 
precision?)

--Greg


Greg Burgess, Ph.D.
Staff Scientist, Human Connectome Project
Washington University School of Medicine
Department of Psychiatry
Phone: 314-362-7864
Email: gburg...@wustl.edu

> On Sep 16, 2016, at 12:17 PM, Ely, Benjamin  wrote:
>
> Hi all,
>
> I ran a test recently comparing "aggressive" vs. "soft" denoising in MELODIC 
> on an HCP resting-state run, regressing out the "bad" components found in the 
> rfMRI_REST1_LR_hp2000.ica/.fix file (I believe the location of this info is 
> different in the newer release but I'm working off HCP500 data). Both 
> denoising methods gave similar results which also looked similar to the 
> released HCP ICA-FIX denoised timeseries (i.e. 
> rfMRI_REST1_LR_hp2000_clean.nii.gz), but I expected the soft denoised MELODIC 
> output to be identical, which it was not. Is there a step I'm missing, or did 
> you run the ICA component regression with a different tool?
>
> Thank you!
> -Ely
> ___
> HCP-Users mailing list
> HCP-Users@humanconnectome.org
> http://lists.humanconnectome.org/mailman/listinfo/hcp-users
>




The materials in this message are private and may contain Protected Healthcare 
Information or other information of a sensitive nature. If you are not the 
intended recipient, be advised that any unauthorized use, disclosure, copying 
or the taking of any action in reliance on the contents of this information is 
strictly prohibited. If you have received this email in error, please 
immediately notify the sender via telephone or return mail.

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users


[HCP-Users] MELODIC denoising vs. released ICA-FIX datasets

2016-09-16 Thread Ely, Benjamin
Hi all,

I ran a test recently comparing "aggressive" vs. "soft" denoising in MELODIC on 
an HCP resting-state run, regressing out the "bad" components found in the 
rfMRI_REST1_LR_hp2000.ica/.fix file (I believe the location of this info is 
different in the newer release but I'm working off HCP500 data). Both denoising 
methods gave similar results which also looked similar to the released HCP 
ICA-FIX denoised timeseries (i.e. rfMRI_REST1_LR_hp2000_clean.nii.gz), but I 
expected the soft denoised MELODIC output to be identical, which it was not. Is 
there a step I'm missing, or did you run the ICA component regression with a 
different tool?

Thank you!
-Ely

___
HCP-Users mailing list
HCP-Users@humanconnectome.org
http://lists.humanconnectome.org/mailman/listinfo/hcp-users