Dear Lorenzo,

I'm glad to hear that the solution worked and thank you for correcting the path.

Best regards,

Kiyotaka


2019/02/21 23:56 Lorenzo <[log in to unmask]>:

Thank you Kiyotaka, it worked!

However, in case it could be useful to someone, at least in my case, I had to write

. /etc/fsl/5.0/fsl.sh

as it was the correct path in my computer.

Thank you again for the help and for the explanation.

Best,

Lorenzo Mancuso

Il 21/02/2019 15:23, Kiyotaka Nemoto ha scritto:
Dear Lorenzo,

1) Quick answer:

Since you use Lubuntu 18.04, open terminal and type

leafpad ~/.bashrc

to open a text editor.

Then add the following line to .bashrc

. /etc/fsl/fsl.sh

(Don't forget the period at the beginning of the line)

Save and close the file, then reboot your PC.

Then you will be able to use fslutils.


2) Background for the answer:

For Debian and Ubuntu families, two different versions of FSL are available. One is from FSL team, and the other is from Neurodebian.
Neurodebian FSL is available up to 5.0.9, which you install on your system.

In order to use fslutils on neurodebian FSL, you need to add '. /etc/fsl/fsl.sh' to your ~/.bashrc .

As of installation of original FSL (from FSL team), you need to use fslinsataller.py which you can get after registration on FSL website.
fslinstaller.py requires python2, which is not shipped with Ubuntu 18.04 (it comes with python 3), so you need to install python2 first.

sudo apt install python (This is described in https://fsl.fmrib.ox.ac.uk/fsl/fslwiki/FslInstallation/Linux)

However, as your error message says, it seems fslinstaller.py does not support 32-bit version of Ubuntu any more (though I may be wrong),
so solution for your system is to use FSL from Neurodebian.

Hope this helps,

Kiyotaka


2019/2/21 22:53 Lorenzo Mancuso <[log in to unmask]>:
Dear Tim,

yes, I'm using the default Ubuntu shell. It seems to me that there is some installation issue, as the output of echo $FSL_DIR (and also of echo $FSLDIR, as suggested in the wiki page) returns an empty line. This is the output for echo $PATH:

/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/usr/lib/jvm/java-8-oracle/bin:/usr/lib/jvm/java-8-oracle/db/bin:/usr/lib/jvm/java-8-oracle/jre/bin

A thing that I forgot to mention is that FSL is named on my computer as fsl-5.0-core, which seems a bit odd to me. I tried to reinstall using the python script, but I did not found on the internet a script for FSL 5.0, and the script for FSL 6.0 gives an error (ubuntu i686 not supported). I reinstalled through apt-get, and I noticed a series of errors related to the grub that I did not spot last time I installed it. The output is partially in Italian but I hope that the global sense of it is understandable:

errore: memoria esaurita.
errore: syntax error.
errore: Incorrect command.
errore: syntax error.
Errore di sintassi alla riga 303
Errori di sintassi sono stati rilevati nel file di configurazione
di GRUB generato. Assicurarsi che non vi siano errori in
/etc/default/grub e /etc/grub.d/* o segnalare un bug allegando
il file /boot/grub/grub.cfg.new.
dpkg: errore nell'elaborare il pacchetto grub-pc (--configure):
  installed grub-pc package post-installation script subprocess returned
error exit status 1
Elaborazione dei trigger per man-db (2.8.3-2ubuntu0.1)...
Configurazione di fsl-5.0-core (5.0.9-5~nd18.04+1)...
Si sono verificati degli errori nell'elaborazione:
  grub-pc
E: Sub-process /usr/bin/dpkg returned an error code (1)

It says that it detects syntax errors in the GRUB configuration file, and that there is an error in the elaboration of the package grub-pc.

I also added to the .profile file the lines reported in FAQ wiki (FSLDIR=/usr/local/fsl ecc.), however it did not help as there is no fsl directory in /usr/local. I found two directories named fsl, one in /usr/lib containing only the directory 5.0, and another in /usr/share containing the directories 5.0 and data. I don't know if one of these two is my installation folder (the one in share looks more convincing). I tried to change the content of .profile writing share or lib instead of local but nothing changed: echo $FSLDIR always returns an empty line and fslmaths is always a command not found.


There is some solution to all this? Thank you in advance for any answer

Sincerely

Lorenzo Mancuso


Il 18/02/2019 22:14, Tim Schäfer ha scritto:
> Dear Lorenzo,
>
> it could be that all that's missing is that your shell is not setup correctly, i.e., the FSL environment variables may not be set correctly and the FSL bin directory may not be part of your PATH.
>
> 1) Which shell are you using? I assume bash, the Ubuntu default shell?
>
> 2) Could you report the output of the following 2 commands:
> -  echo $FSL_DIR
> -  echo $PATH
>
> I do not know about the neurodebian package, but if you installed from the python script and did not change the default location, your FSL installation should be in /usr/local/fsl/. In that case, you should be able to run flsmaths by typing:
>
>    /usr/local/fsl/bin/fslmaths
>
> (But you should definitely get the shell setup fixed.)
>
> Best,
>
> Tim

########################################################################

To unsubscribe from the FSL list, click the following link:
https://www.jiscmail.ac.uk/cgi-bin/webadmin?SUBED1=FSL&A=1



--
Kiyotaka Nemoto, M.D., Ph.D.
Associate Professor
Department of Psychiatry
Division of Clinical Medicine, Faculty of Medicine
University of Tsukuba
1-1-1Tennodai Tsukuba, Ibaraki 305-8575, Japan
E-mail: [log in to unmask]

Mail priva di virus. www.avg.com


To unsubscribe from the FSL list, click the following link:
https://www.jiscmail.ac.uk/cgi-bin/webadmin?SUBED1=FSL&A=1



--
Kiyotaka Nemoto, M.D., Ph.D.
Associate Professor
Department of Psychiatry
Division of Clinical Medicine, Faculty of Medicine
University of Tsukuba
1-1-1Tennodai Tsukuba, Ibaraki 305-8575, Japan
E-mail: [log in to unmask]


To unsubscribe from the FSL list, click the following link:
https://www.jiscmail.ac.uk/cgi-bin/webadmin?SUBED1=FSL&A=1