Skip to content

smoia/ohbm2023noisetutorial

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Material for the OHBM 2023 Educational Course Tutorial "One person’s signal is another person's noise: hands-on tutorial to remove physiological fluctuations from MRI data"

In this repository you can find the data to follow OHBM 2023 Educational Course Tutorial One person’s signal is another person's noise: hands-on tutorial to remove physiological fluctuations from MRI data, part of the Educational Course Physiologic fMRI signals: friend or foe? How and why to measure, model, and account for physiology (see also here for the other tutorials in the same Educational Course)

Laptop setup

To follow this tutorial, you will need a laptop, requiring a little bit of setup beforehand.

0. Prerequisites

You will need a laptop with python installed, as well as pip. Python version should be 3.7 or above. You also need to download the files in this repository, either zipped in a package or by locally cloning the repository.

1. Optional - Set up a virtual environment

The best way to ensure the software functioning without changing anything in your system is using a virtual environment. For that, first install virtualenv:

pip install -U virtualenv

(Note you might need to use pip3 instead of pip, depending on your OS and setup, to work with python 3)

Then, create and activate the virtual environment - in this case I called it OHBM2023noise, but you can use a different name:

virtualenv OHBM2023noise
source OHBM2023noise/bin/activate

Note that the first command above will create a folder where you called it from, and the second command assumes this is the case - if you want you can specify a different path though.

Once you activated the virtual environment, you can proceed with package installation

2. Package installation

You will need to install a few python packages. First and foremost, wxPython. Its installation depends on the OS you are using. While you can find detailed instructions here, following is the summary.

Install wxPython on Windows and macOS

pip install -U wxPython

(Note you might need to use pip3 instead of pip, depending on your OS and setup, to work with python 3)

Install wxPython on Linux

Check this folder for the right python package, depending on the version of GTK you are using, as well as your OS, then using the link to the right folder, install wxPython version 4.2.0, if possible. In this example, I will assume we're working with GTK3 on Ubuntu 20.04:

pip install -U \
    -f https://extras.wxpython.org/wxPython4/extras/linux/gtk3/ubuntu-20.04 \
    wxPython==4.2.0

(Note you might need to use pip3 instead of pip, depending on your OS and setup, to work with python 3)

Install all other packages

You also need to install peakdet and phys2denoise. Optionally, you can also install ipython, a nice CLI environment to work with python.

The fastest option is to use the requirements.txt file in this repository:

pip install -U -r path/to/requirements.txt

(Note you might need to use pip3 instead of pip, depending on your OS and setup, to work with python 3)

Alternatively, you can install directly what you need. Please ensure to install matplotlib version 3.6.3 or below, otherwise you will incur into a deprecation error:

pip install -U peakdet phys2denoise matplotlib==3.6.3 ipython

(Note you might need to use pip3 instead of pip, depending on your OS and setup, to work with python 3)

3. Check the installation

Within the virtual environment, you can either call pip to list your packages (pip list or pip3 list), or open ipython and import peakdet and phys2denoise

import peakdet
import phys2denoise

If you have no issues doing that, you're all good to go!

Note that peakdet's GUI might not work in GUI-like environments like Jupyter notebooks or Spyder

4. Download files for the tutorial

You can downlaod some files that contain data for the tutorial - we will be using these files during the live tutorial.

You can download the physiological files here and here. There is BOLD fMRI data associated to these physiological files to play with, as well as motion paramters ready for denoising, here. The results and intermediate steps of the tutorial can be found here.

You can also download the full folder with all files here.

If you have your own data, feel free to also bring it with you! I would suggest to download the tutorial data as well, just in case there is any issue.

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages