eXTReMe Tracker
Sep 122016
 

Updated 2017.03.28

  • Freesurfer 6.0 is now a stable release and there are couple of additional dependencies that weren’t required in the beta release of freesurfer. I have changed the post to reflect the list of libraries that need to be installed.

There is good news for those who use neuroimaging tools such as AFNI, FSL and FreeSurfer on their Windows machines. The limitation is that they can only be run on Windows 10 with anniversary update. Does it use a Virtual Machine? No. It runs “natively” on Windows 10, so you can save, print, resize or hide any interface just like a Windows program.

Freeview running in Windows 10

Freesurfer on Windows 10

Before I get into how to install FreeSurfer, I must thank the author at K-Lab for the post on “How to run FSL on Windows 10“. That post describes how to install BASH on Windows 10 in the first few steps. Sadly it is not available for Windows 7/8. It uses Ubuntu 14.04 LTS which will be supported by Canonical until 2019. We hope by then Windows would incorporate the Ubuntu 16.04 LTS as the default distribution.

I’ll repeat a few things (steps 1-5) that Lin4Neuro wrote on how to get BASH and X-server on Windows 10.

  1. Install Linux BASH shell on Windows 10:
    There is detailed tutorial with screenshots on how to do this at the following site.
    How to Install and Use the Linux Bash Shell on Windows 10
  2. Install the updates:
    Before adding any tools, you should first download and install the updates for Ubuntu. Run the following commands at the terminal

    sudo apt-get update
    sudo apt-get upgrade
  3. Install the X server:
    With bash you can run applications on a command line but in order to run any GUIs for neuroimaging tools you’ll need a X-server for windows. The most popular software for this is Xming. You can download and install it with default settings.
    Xming X server for Windows
  4. Running X server:
    Run Xming by searching it from start menu. When it is loaded you should see this when you go to show hidden icons button at the bottom right corner of your desktop.
    xming_server
  5. In order for X server to work with BASH run the following command at the terminal
    echo "export DISPLAY=localhost:0.0" >> ~/.bashrc

    This will add the environment variable for display to the .bashrc file.


  6. Downloading Freesurfer (Release 6.0):
    You can obtain your copy of Freesurfer from their web page. To download FreeSurfer type this command at the terminal:

    ftp://surfer.nmr.mgh.harvard.edu/pub/dist/freesurfer/6.0.0/freesurfer-Linux-centos6_x86_64-stable-pub-v6.0.0.tar.gz

    Hint: You can copy the link with your mouse and when you right-click at the terminal, it will be automatically pasted so you don’t have to type it in manually.
    This is a large file (~4.6GB) so it may take some time to download it based on your network speed.

  7.  It is customary to install it at /usr/local/ so let’s extract it to that directory.
    sudo tar -xzf freesurfer-Linux-centos6_x86_64-stable-pub-v6.0.0.tar.gz -C /usr/local/

    You will require your admin password (for Ubuntu, not Windows) to extract it to /usr/local. Again, this step can take few minutes since we are extracting a file that’s several gigabytes in size. Once extracted, we’ll have to change permissions on that folder.

    sudo chmod -R 755 /usr/local/freesurfer

    This allows you to edit or create files in that folder.

  8. Obtain the FreeSurfer license:
    In order to run the FreeSurfer applications you need to register and obtain a license from their website.
    FreeSurfer Registration
    Once you have the license emailed to you, copy the contents between the lines that read “cut here” and create a license.txt file.

    sudo nano /usr/local/freesurfer/license.txt

    fs_lic
    Paste the contents with right-click
    Press ctrl+X to exit
    Press y to accept and save it as license.txt
    Hit Enter

  9. Add FreeSurfer path to .bashrc:
    echo "export FREESURFER_HOME=/usr/local/freesurfer" >> ~/.bashrc
    echo "source \$FREESURFER_HOME/SetUpFreeSurfer.sh" >> ~/.bashrc
  10. Dependencies: libjpeg.so.62, libgomp1, etc.
    Generally there are a few dependencies including the tcsh shell that aren’t included by default in the ubuntu distribution.  But they can be installed using:

    sudo apt-get install build-essential libjpeg62 libxss1 libgomp1 tcsh

    There may be some other dependencies that may be needed as time goes on. The best way to get the needed ones is to type in sudo apt-get install <partial-name-of-needed-file> and then hit tab to see if it recognizes and autocompletes the name of that dependency. It will work in most cases.

  11. Final check:
    Check that the Xming server is running and it says Xming Server:0.0 when you hover the mouse on the Xming icon in the lower right hand corner. Type bash at the terminal. You should see the following:

    -------- freesurfer-Linux-centos6_x86_6.0 --------
    Setting up environment for FreeSurfer/FS-FAST (and FSL)
    FREESURFER_HOME   /usr/local/freesurfer
    FSFAST_HOME       /usr/local/freesurfer/fsfast
    FSF_OUTPUT_FORMAT nii.gz
    SUBJECTS_DIR      /usr/local/freesurfer/subjects
    MNI_DIR           /usr/local/freesurfer/mni
  12. Test your installation:
    Check if everything works by going through some of the examples listed on the FreeSurfer website.
    FreeSurfer examples
    If everything has been installed correctly you should be able to run command line functions and open GUIs just like on a Mac or Linux machine.
    tksurfer_win10If you have any questions about the installation, please post a comment. If you have questions about FreeSurfer please visit the FreeSurfer user community mail archives.
Jan 232009
 

The recently released Windows 7 Beta (Build 7000) has several improvements in its GUI. Many of these features have been discussed at length in several blogs. Among other things, there is a deafult option to stack all program tabs in the taskbar keeping it from running out of space.  There is a mouse-over feature that shows a preview of that program and brings that program to the foreground when the mouse is moved over that preview.

Then there is one tiny feature in the Windows Explorer that should have been implemented long time ago, but its good to finally see it in this release.

Organize >> Folder and Search Options >> View >> Use Check boxes to select items

Windows Explorer Checkbox Option

Windows Explorer Checkbox Option

Once that option is selected, a checkbox is displayed in front of the file each time the mouse hovers over it. This options overcomes the need to select individual files by keeping the ‘Control’ key press at all times.

Checkbox is displayed in front of file icon

Checkbox is displayed in front of file icon

This is one of the features I’d like to see ported over into Gnome for use in Linux distros.