<div dir="ltr"><div>Hi Paul, </div><div><br></div><div>Thanks for your email. I think this should do it:</div><div><br></div><div> import nibabel as nib<br></div> img = nib.load('aparc+aseg.nii.gz')<div> data = img.get_fdata()</div><div><br></div><div>At this point, `data` should be a numpy array with the values stored in that file. </div><div><br></div><div>Hope that helps, </div><div>Ariel</div></div><div dir="auto"><br></div><div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Mon, Mar 29, 2021 at 2:11 PM Paul Reiners via Neuroimaging <<a href="mailto:neuroimaging@python.org" target="_blank">neuroimaging@python.org</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">This is my question: <a href="https://psychology.stackexchange.com/q/26872/28113" target="_blank">https://psychology.stackexchange.com/q/26872/28113</a></div>
_______________________________________________<br>
Neuroimaging mailing list<br>
<a href="mailto:Neuroimaging@python.org" target="_blank">Neuroimaging@python.org</a><br>
<a href="https://mail.python.org/mailman/listinfo/neuroimaging" rel="noreferrer" target="_blank">https://mail.python.org/mailman/listinfo/neuroimaging</a><br>
</blockquote></div></div>