-
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
How should negative component weights be treated? #318
Comments
I'm not sure what the good solution here is. Since you're the one who looked into it, do you happen to know if there are any patterns in negatively-weighted components? |
For the most part, negative weights don't seem to have much structure, but in the global signal components both positive and negative weights seem to follow patterns. It's really hard to know for sure based on my own anecdotal evidence. However, I discussed this a bit with @smoia, and he really doesn't think it should matter- most fMRI ICA methods don't even seem to care about directionality of the components (except MELODIC, apparently). Regardless, we can at least fix what is definitely a bug where positively and negatively weighted voxels are treated the same when performing cluster-extent thresholding. I've done this in #331. |
I'm not so sure this is a bug.... Since the ICA signs are arbitrary it really is just detecting that there is some signal there. It's safe to assume they come from different components, but I'm not sure it's a problem to have 2+ components in the same cluster. That could still happen if they're of the same sign, right ? |
If the goal of component selection is to identify which components are S0-based and which are R2-based, and one of the metrics we use to separate noise from signal is how clustered voxels weighting on each component are, then I think treating distinct sources of signal as the same is a problem. My intuition is that it is a small problem that will not affect things very much, since our minimum cluster size for cluster extent thresholding is generally only about 20 voxels, but I think it must still be an issue. |
@tsalo, I know I should know and I'm sorry I don't, but can you explain a bit better this last problem? There might be another issue related to the sign of the components, and it's that no matter what the sign of the components is, I think it should be consistent throughout all the components. |
@smoia The 20 voxel threshold is really The cluster-extent thresholding currently uses what AfNI calls "two-sided" thresholding (positive and negative voxels are combined to form clusters). I agree that they should be clustered separately, since they indicate different things (as implemented in #331). I'll be interested to learn more about this potential reconstruction issue. It's not something I was aware of before. |
Thank you for the clarification @tsalo ! I would still change the threshold but hey, no biggie. |
We flip components separately. Since the components are initially arbitrarily signed, some might need to be flipped, while others might not, to best match the data. |
@tsalo could you please tell us where this is done in the code? |
Thank you @tsalo ! @eurunuela and I are looking into it a bit too. Let you know if we have any news. |
Sorry for the delay in replying. It is perfectly appropriate to flip the sign of single components (for instance so that the maximum absolute value of the weights is made positive, or the histogram is shifted towards positive values). The reconstruction simply needs to take this into account, but in my opinion, since the reconstruction (or denoising) can be simply done by nulling the noise components to zero, the sign does not really matter because X*0 = 0, regardless of the sign of X. Hope this helps. |
Since component flipping doesn't pose a problem for reconstruction, how do we feel about negatively weighted voxels? Is the consensus that it's okay to treat those voxels equivalently to positively weighted ones when calculating dependence metrics? If so, I'd just like to make sure I know what the rationale for that is. Is it:
Once we have a consensus on the reason, I can close this issue and add an overall summary. |
@smoia @eurunuela any further thoughts? |
Summary
In dependence_metrics, we compute component-wise metrics using weighted averages, where the weights are determined by how strongly the component loads on a given voxel. However, we treat negative weights the same as positive weights, which does not make sense to me. In fMRI data, components should be signed (i.e., a given signal over time and its opposite form should not be treated equivalently), which is indeed why we attempt to identify the right signs for components (as detailed in #316). Therefore, does it make sense to treat voxels loading highly negatively on a component the same as voxels loading highly positively when computing brain-wide metrics?
Additional Detail
Here is the code where we compute the weighting map used for the weighted averages:
tedana/tedana/model/fit.py
Lines 184 to 187 in 65f89e1
We square the weight maps so that negative and positive weights are treated equally. Should we instead zero out those negatively weighted voxels when calculating the metrics?
The text was updated successfully, but these errors were encountered: