Code Monkey home page Code Monkey logo

afids-utils's Introduction

AFIDs

An open framework for evaluating correspondence in brain images and teaching neuroanatomy using anatomical fiducial placement

AFIDs

Preprint: https://www.biorxiv.org/content/10.1101/460675v2

Manuscript: http://dx.doi.org/10.1002/hbm.24693

Documentation: https://afids.readthedocs.io/en/latest/

Join our channel on

Introduction

  • The AFID protocol is an anatomical fiducial placement protocol that has been validated and used for teaching at a number of local and BHG-related events including https://github.com/BrainhackWestern/BrainhackWestern.github.io/wiki/Tutorials.
  • AFID placement is reproducible, not overtly manually intensive (20-40 minutes once trained), and more sensitive to local registration errors than standard voxel overlap measures.
  • This protocol and study framework leverages open resources and tools, and has been developed with full transparency in mind so that others may freely use, adopt, and modify.
  • 60+ raters trained to date.

afids

References and Resources

Preprint

  • Lau JC, Parrent AG, Demarco J, Gupta G, Park PJ, Ferko K, Khan AR, Peters TM. A framework for evaluating correspondence between brain images using anatomical fiducials. bioRxiv. 2018. [ref]

Conference Abstracts

  • Lau JC, Parrent AG, Demarco J, Gupta G, Park PJ, Ferko K, Khan AR, Peters TM. AFIDs: an open framework for evaluating correspondence between magnetic resonance images of the human brain using fiducial placement. F1000 Research. Demo presented at INCF NeuroInformatics in Montreal, QC, Canada. 2018. [ref]

Open Datasets

  • Agile12v2016: Lau JC, MacDougall KW, Arango MF, Peters TM, Parrent AG, Khan AR: Ultra-High Field Template-Assisted Target Selection for Deep Brain Stimulation Surgery. World Neurosurg 103:531–537, 2017. [download] [ref]
  • Colin27: Holmes CJ, Hoge R, Collins L, Woods R, Toga AW, Evans AC: Enhancement of MR Images Using Registration for Signal Averaging. J Comput Assist Tomogr 22:324–333, 1998. [download] [ref]
  • MNI152NLin2009bAsym: Fonov V, Evans AC, Botteron K, Almli RR, McKinstry RC, Collins LL, et al: Unbiased average age-appropriate atlases for pediatric studies. Neuroimage 54:313–327, 2011. [download] [ref]
  • OASIS1: Marcus DS, Fotenos AF, Csernansky JG, Morris JC, Buckner RL: Open Access Series of Imaging Studies: Longitudinal MRI Data in Nondemented and Demented Older Adults. J Cogn Neurosci 22:2677–2684, 2010. [download] [ref]

Software

  • 3D Slicer: Fedorov A, Beichel R, Kalpathy-Cramer J, Finet J, Fillion-Robin JC, Pujol S, et al: 3D Slicer as an image computing platform for the Quantitative Imaging Network. Magn Reson Imaging 30:1323–1341, 2012. [download] [ref]

Historical References

  • Talairach1957: Talairach J, David M, Tournoux P, Corredor H, Kvasina T: Atlas d’anatomie Stéréotaxique. Repérage Radiologique Indirect Des Noyaux Gris Centraux Des Régions Mésencephalosousoptique et Hypothalamique de l’homme. Paris, France: Masson & Cie, 1957
  • Talairach1988: Talairach J, Tournoux P: Co-Planar Stereotaxic Atlas of the Human Brain: 3-D Proportional System: An Approach to Cerebral Imaging. ed 1, Thieme, 1988.

Other Resources

afids-utils's People

Contributors

github-actions[bot] avatar kaitj avatar tkkuehn avatar

Stargazers

 avatar

afids-utils's Issues

[TEST] Test Splitting

Describe the feature you'd like to see
Given the length to generate some of the tests, would be a good idea to split the tests up (re: see snakebids)

[ENH] Handling of different coordinate systems

Describe the feature you'd like to see
At some version of Slicer, I believe the coordinate system either switched or could be toggled to be LPS or RAS. We had previously implemented something to handle this in the afids-validator, reading in the coordinate system and flipping the coordinates as needed when reading in files.

We should probably implement it here too.

[ENH] Attrs Validator

Describe the feature you'd like to see

Internal validation of AFIDs files upon loading. Some further discussion should be had here as well. During the sprint, the use of this for non-standard fiducials was discussed. I think if that is the case, we can have something similar to pybids where we have this validation implemented and performed by default, with the option of turning it off. Open to other suggestions.

[ENH] Additional features for 3D plotting

From #20, this is PR to separate additional features that we would like to see included for plotting in 3D:

  • Overlay of a surface mesh of brain
  • Inclusion of segmentations (e.g. ventricles, STn, etc.)
  • Intersection planes if nifti is provided

[ENH] Add pyright

Describe the feature you'd like to see
With this library being type hinted, pyright would be a helpful addition.

[ENH] Handling transformations

Describe the feature you'd like to see

Updating the methods for handling transformations between world and voxel coordinates.

RAS and LPS conventions across afids-utils

Coodinate system defaulting and notation

Switch convention such that 0 = RAS and 1 = LPS

Additional context
Slicer has moved to defauling coordiantes in LPS convention now (4.10 onwards)

[MAINT] Refactoring metadata retained

Describe the feature you'd like to see
Had some discussion about dropping some metadata that was irrelevant for the usage of afids_utils. Namely, storing the slicer_version does not provide any added benefit, and actually is only relevant to .fcsv files. Open to hearing people's thoughts before dropping this though.

Loading of fcsv agnostic to AFID order

I am trying to load an fcsv file which has some "jumbled" ordering of AFIDs (i.e., AFID 19 placed at 4th position but still contains the correct label). The load method seems to fail due to that (see attached screenshot). Perhaps creating a load method with some agnostic features to the loaded file may be a good thing to include.
Screenshot 2023-09-30 at 7 29 27 PM

[ENH] Add check for `afids_to_fcsv`

Describe the feature you'd like to see
Currently the afids_utils.io.afids_to_fcsv function writes a (32, 3) NumPy array to an fcsv file based on the template. The 32 AFIDs expected in this function is not a hard rule and is based off of the number of AFIDs expected in the provided template. In the future, we may expect a different number of AFIDs due to subsetting of existing fiducials or even for different species.

To that end, a couple of checks should be implemented in this function to:

  1. Confirm that the number of AFIDs (e.g. 32) matches the number of expected number of AFIDs in the template
  2. Check that the second dimension is equal to the 3 expected spatial dimensions (x, y, z)

[ENH] AFID QC plots

Describe the feature you'd like to see

  • Orthogonal planes with points highlighted
  • Summary plots
  • 3D interactive
    • Glass brain
    • Optional intersecting planes (similar to slicer) if nifti is provided
    • Inclusion of segmentations

Integrate automatic typehinting

Describe the feature you'd like to see
Make use of the sphinx extension autodoc_docstring_signature (or whichever extension is relevant) to automatically pick up type hints and drop the repeated type hint that is manually written in the docstrings.

[DOC] Create readthedocs

Describe the feature you'd like to see

Create a readthedocs and incorporate docstrings of existing functions

[ENH] Handling external transformations

Describe the feature you'd like to see
Some discussion was had about being able to apply external transformations (e.g. ANTs) to the fiducials.

Additional consideration is whether the afids need to be in a certain coordinate system.

[ENH] JSON AFIDs handling

Describe the feature you'd like to see

A similar implementation as to the fcsv handling, but for handling AFIDs saved in Slicer JSON files.

[DOC] Update README

Describe the feature you'd like to see

Fill out the README to be more descriptive about the project. This should include any status / doi badges

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.