-
Notifications
You must be signed in to change notification settings - Fork 95
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Revisit make_adaptive_mask #113
Comments
Given a recent problem case that appears to have at least partially caused by poor automatic masking, I think we should make sure to circle back to this issue. In the linked case, |
Does anyone have any concerns about updating the workflow to use |
It seems that having a standardized automated way to get things started is very useful. As long as the masking isn't removing too much, such that the denoised output data isn't useful, it seems fine to have something that prevents the 'whole bounding-box' problem. |
Sounds good to me. I've opened a new PR, #226, with the change. It doesn't solve all of the issues with |
Here's an idea for how we could improve There are probably a lot of ways in which we can improve this first pass (e.g., not using the mean, setting tolerances for the differences, etc.), but what does everyone think of the general logic? |
This is interesting to me - is there any particular spatial distribution of these bad echo voxels? That plot suggest that the 'bad echo' is very stable - always an increase across the entire timeseries, if I'm reading it correctly. The logic seems sound - but I am very curious as to why and where these baddies exist and if there is any useful information in that. |
At least in the five-echo test dataset, they seem to mostly be in the ventricles. |
Thanks! I was expecting there, or cardiac regions - but still not clear to me why it would be so consistent. In any case, that's really neat. Wonder if that info could be useful in some way, perhaps overlay with those areas as another metric for ICA acceptance/rejection, or just for generating a noise regressor. |
I was thinking of using the T2*/S0 log-linear model fit in calculating existing metrics, by deweighting the contributions of voxels with poor fit (see #230). Once I realized we could also use the more obvious artifact detailed here in |
Alternatively, what if we used only good echoes to calculate the pseudo F-statistics for each voxel? |
@dowdlelt I think in an in-person conversation you were saying something about the log-linear fit; would any of your findings contribute to this issue? |
I proposed some improvements to the adaptive mask generation in #231, but I don't know that anyone was interested in them. Those improvements just looked at the overall scale for the different echoes within a voxel to see if the mean value increased from one echo to the next at any point (which shouldn't happen). I don't think anyone has looked at fit quality as a metric of "good" signal yet, but it would be great to see if @dowdlelt has made any progress there. I think that adaptive mask generation improvement has taken a back seat to metric calculation and component selection (for good reason). Perhaps it would be best to label this as low-priority (i.e., an enhancement that we might get to at some point) or to open two new issues: one for the improvement I proposed and one requesting an investigation of fit quality on echo signal. |
After waffling back and forth, I think I'd prefer to close this and open two issues as you suggested. Would you mind writing the issues, @tsalo ? We will then mark them both as low-priority and close this one if you agree with going that way. |
I've opened #312, although I can't figure out how to investigate fit quality's effect on echo signal so I haven't opened the second issue. |
I think this is ready to close -- please re-open @tsalo if you disagree ! |
Per discussion in #102, we want to take a closer look at how
make_adaptive_mask
determines which voxels have sufficient signal at each TE. The threshold applied below appears to be arbitrary:tedana/tedana/utils/utils.py
Lines 195 to 210 in 0c5f93d
As mentioned in #102, @rmarkello also thinks that the thresholds are hard-coded based on a three-echo dataset, so we'll want to look into that as well.
We have access to a five-echo dataset from @handwerkerd, so we can use that to investigate the method by which the signal quality threshold is determined and see if there's a better method out there. We can also use the quality of the log-linear fit to the decay model, and perhaps calculate TSNR for each echo's time series.
Does anyone have any thoughts on how we should do this?
BTW I've started looking into using TSNR to make an adaptive mask here.
The text was updated successfully, but these errors were encountered: