alexrockhill's Blog

Week 2: Getting into the Implementation

alexrockhill
Published: 06/19/2021

This week I worked on translating existing code to register a CT to an MRI and warp one MRI to an average template into a mne-python example. The existing code works great, but there are quite a few dependencies so I looked into refactoring and reimplementing. That hasn't gone smoothly yet but I think I have learned quite a bit about all the algorithm implementations so that I know what needs to be done. I was able to eliminate a skimage dependency by refactoring to use the marching cubes implementation in VTK so that was the first success. I might have to add back the skimage dependency if I reimplement the histogram registration though. I am a bit stuck on getting the example to execute quickly and making it easy to understand for the user as multiple dependencies and their formats make that tough. I'm waiting for reviews to help out with that as I move on to improving the implementation of the GUI by embedding VTK plots instead of matplotlib.
View Blog Post

Week 1: Setting Up

alexrockhill
Published: 06/14/2021

This week I started a new repository, `mne-ieeg-localize` for the project! I set up tests and documentation and ported over one function from previous work and mostly raised it to MNE standards. I'm a bit stuck on test writing and testing data. For now, I think I will host the test data on Google Drive and figure out how large the file size needs to be. It will be in the neighborhood of 2 - 4 GB and the 3D image processing makes the test take on the order of tens of minutes or hours. I need to find a way to work around these issues to make sure that the tests still cover functionality while not being prohibitively long. This week I plan to finish the implementation of the coregistration and compare the Dipy affine alignment to the Nipy histogram registration. Ideally, we could remove this dependency by writing it all in numpy, but the symmetric diffeomorphic registration would be a big ask to reimplement and so Dipy is a dependency that looks to be here to stay. It's worth looking into if it's not too much to write these functions to be maintained as part of the package. I was a bit busy this week as I had my comprehensive/prelim PhD candidacy exams so I
View Blog Post

Getting Started

alexrockhill
Published: 06/07/2021

I'm excited for the ieeg localization project and ready to hit the ground running. I have been working on changing the dependency on the freesurfer mri_cvs_register function that takes 15+ hours to do a combined surface and volume registration to depend on a symmetric diffeomorphic registration implemented in Dipy. Up next, I will migrate the project into mne-tools and set up basic tests and documentation. Fortunately, I'm not stuck on anything!
View Blog Post