FANDOM


fsl_for_linux_old
# # #
14_11_13
#
It is an old, go-around solution for configuring fsl under linux.
# #

Aka removing "fsl5.0-" from the fsl commands


#

CAUTION: for now it works only for the root user (as applied to shell (bash) scripts, *.sh files)


#

to enter root terminal type the following command:

sudo su

and type you password as asked


#


1. Copy ".fsl_inte" file into your /home/$USER directory

File shared at grik's gdrive adress:

https://drive.google.com/file/d/0B5xQZSdqP66STGZNOERmUTlzcjQ/view?usp=sharing


#


2. Add "source .fsl_inte" line at the end of your /home/$USER/.bashrc file by typing or copy-pasting the following command:

echo "source .fsl_inte" >> /home/$USER/.bashrc


#


3. Copy ".fsl_inte" file into your /root directory

File shared at grik's gdrive adress:

https://drive.google.com/file/d/0B5xQZSdqP66STGZNOERmUTlzcjQ/view?usp=sharing


#
To reach your /root directory you have to type:

sudo su
cd ~/


#


4. Add "source /root/.fsl_inte" line at the end of your /root/.bashrc file by typing or copy-pasting the following command:

echo "source /root/.fsl_inte" >> /root/.bashrc



#


5. To be able to use these aliases in your shell scipts you have to add the two following lines at the beginning of each of your fsl script:

shopt -s expand_aliases
source ~/.fsl_inte 


#

Script example:

#!/bin/bash

shopt -s expand_aliases
source ~/.fsl_inte 

lista=$(ls -1 | grep "sub003")
 
    for i in $lista
        do
 
            cd $i/anatomy
 
                flirt -in highres001.nii.gz -ref /usr/share/fsl/5.0/data/standard/MNI    152_T1_2mm -out T1w -omat T1w.mat -cost mutualinfo -dof 12 -interp spline
 
            cd ../..

        done


# # #

Ad blocker interference detected!


Wikia is a free-to-use site that makes money from advertising. We have a modified experience for viewers using ad blockers

Wikia is not accessible if you’ve made further modifications. Remove the custom ad blocker rule(s) and the page will load as expected.

Więcej z Fandomu

Losowa wiki