dorianps / LINDA

Lesion Identification with Neighborhood Data Analysis
Apache License 2.0
20 stars 4 forks source link

CH2 Template not the same #18

Closed muschellij2 closed 5 years ago

muschellij2 commented 5 years ago

I made a quick package from the penn60 patients: https://github.com/muschellij2/penn60. Is that the correct citation in the README?

The ch2.nii.gz file is not identical to the Colin27 (the 1998 one) on: http://www.bic.mni.mcgill.ca/ServicesAtlases/Colin27. The code below shows a high correlation, but this isn't exactly the same. What's the difference? I saw that one may be scaled by min/max? But other than that - what processing was done on it?

library(ANTsRCore)
#> 
#> Attaching package: 'ANTsRCore'
#> The following object is masked from 'package:stats':
#> 
#>     var
#> The following objects are masked from 'package:base':
#> 
#>     all, any, apply, max, min, prod, range, sum
ch2 = antsImageRead(system.file("extdata", "pennTemplate", "ch2.nii.gz",
                                package = "LINDA"))
destfile = tempfile(fileext = ".zip")
url = "http://packages.bic.mni.mcgill.ca/mni-models/colin27/mni_colin27_1998_nifti.zip"
download.file(url = url, destfile = destfile)

unz = unzip(zipfile = destfile, exdir = tempdir())
img_file = unz[grepl("lin[.]nii", unz)]
img = antsImageRead(img_file)

all.equal(as.array(img), as.array(ch2))
#> [1] "Mean relative difference: 0.9999755"

cor(as.array(img), as.array(ch2))
#> [1] 0.9885375

Created on 2018-11-07 by the reprex package (v0.2.1)

dorianps commented 5 years ago

I don't remember changing ch2 at all, just took it somewhere.

The penn template is not from 60 participants, but from 115:

we used a mixed template built from 208 elderly subjects (115 elderly controls and 93 patients with various diseases, such as, Parkinson's, fronto-temporal dementia, mild cognitive impairment, and Alzheimer; template available online with the LINDA toolkit). The template was built with the ‘buildtemplateparallel.sh’ script in ANTs.

I also did not create this template myself, it was created by some collaborators.

dorianps commented 5 years ago

Btw, I think there are a few versions of ch2 out there, some with 181 slices, some with 182. I used one that fitted the lesion maps I had, which were registered or drawn on ch2 years before.

muschellij2 commented 5 years ago

Changed to https://github.com/muschellij2/penn115

dorianps commented 5 years ago

Closing.