Inputs and outputs of nilearn.glm.cluster_level_inference

Hey everyone,

I hope y’all are doing fine.
I had a bit of fun with nilearn.glm.cluster_level_inference and observed some puzzling outputs I can’t quite understand. Thus, I thought I would reach out here and ask the hivemind.

I would like to use nilearn.glm.cluster_level_inference as an alternative to cluster thresholding/correction and was happy to see a nilearn implementation of Rosenblatt et al. 2018. I would like to use this method to provide additional information to contrasts of interest, ie in addition to “classically” thresholded images.

I started following this tutorial and everything seemed fine. However, I realized I erroneously used fpr-corrected images as input. After correcting my mistake and using z-maps as input the proportion_true_discoveries_img is empty and I also get an UserWarning: Given img is empty. warning. .

Here are the images for reference. At first the z-map and the respective proportion_true_discoveries_img:

z_map_all_imagineGtSuppress_zmap_mni

Second, the fpr-corrected z-map and respective proportion_true_discoveries_img:

Does anyone maybe have an idea what’s going on here? Sorry if my explanation is somewhat confusing, please just let me know if you have questions/need more information.

Cheers, Peer

P.S.: I saw that the code of nilearn.image.threshold_stats_img has an "all-resolution-inference" option, which, however, is not used. Is this functionality that might be added in one of the next releases?

Hi Peer,
I’m happy to help. Do you have a small script to reproduce the thing ?
Best,
Bertrand

Hey @bthirion,

thanks so much for the response, I highly appreciate it.

Unfortunately, I can’t share the images publicly but if ok, I would send you an Email with the data and code and then update here with the outcome/solution?

Thanks again.

Cheers, Peer

Or maybe you can reproduce your issue on a public image ?
Do as you prefer. Best,
Bertrand

Hey @bthirion,

thanks for the reply.

I tried the code on a few different public images and it works as expected (as far as I can tell). The problem only arises when I use the above shown z-map I get through SecondLevelModel. Thus, I assume something is off with the z-map but I can’t figure it out. Unfortunately, I can’t share the map publicly yet, sorry.

I would send you an E-Mail and afterwards update this thread so folks see the solution (hopefully).

Thanks and sorry again.

Cheers, Peer

Hey everyone,

sorry for the late update.

@bthirion and I had a closer look and it appears that my map had too low z-scores and their distribution was not feasible, ie the map didn’t have a large enough number of high z-scores.

@bthirion also mentioned another tool: notip that might be interesting for other folks who would also like to employ respective methods.

Thanks again.

Best, Peer

1 Like