[Neurodebian-users] fsl-5.0-gpu

Jonathan Berrebi Jonathan.Berrebi at ki.se
Wed Feb 26 12:51:44 UTC 2014


With great pleasure Michael!

I join as attachment a patch for the three files. Please notice that it's only for bedpostx_gpu. There are other routines than seem to be parallelised by fsl-5.0-gpu. I wil have a look at them later. I'll answer Alex as well since there are some slight differences between the results from CPU and GPU.

Best,

Jonathan


________________________________
De : Michael Hanke [michael.hanke at gmail.com]
Envoyé : mardi 25 février 2014 21:25
À : Jonathan Berrebi
Cc : Alex Waite; neurodebian-users at lists.alioth.debian.org
Objet : Re: [Neurodebian-users] fsl-5.0-gpu

Hey,

would you mind submitting a patch for all changes you had to make?

Thanks,

Michael


On Tue, Feb 25, 2014 at 9:10 PM, Jonathan Berrebi <Jonathan.Berrebi at ki.se<mailto:Jonathan.Berrebi at ki.se>> wrote:
Thank you Alex and Yury!

I replaced all the #/bin/sh with #/bin/bash in the bedpostx_gpu and bedpostx_postproc_gpu.sh and fsl_sub files. I think it worked now. It took 6 hours on a 96 cores GPU instead of one day on Intel Xeon. The only warning I get is on the monitor "routine" ${subjdir}.bedpostX/monitor about zeropadding:

<<FP02.bedpostX/monitor: line 21: /bin/zeropad: No such file or directory>>

I will check that the results are numerically not different than when they CPU computed.

Once thing though is that I had to stop gdm3 in order to get it to work. I really tried to use the intel HD 3000 integrated GPU for the Graphics by changing the settings in the bios. But then the nvidia-detect routine did not detect the GPU. So I thought it wouldn't work. Then I even installed bumblebee  and changed the settings in the bios into Optimus but that become more a bumblebee than a fsl/cuda problem so I gave up. I might retry later.

Thank you for your help,

Jonathan

________________________________________
De : Neurodebian-users [neurodebian-users-bounces+jonathan.berrebi=ki.se at lists.alioth.debian.org<mailto:ki.se at lists.alioth.debian.org>] de la part de Alex Waite [alexqw85 at gmail.com<mailto:alexqw85 at gmail.com>]
Envoyé : mardi 25 février 2014 09:52
À : neurodebian-users at lists.alioth.debian.org<mailto:neurodebian-users at lists.alioth.debian.org>
Objet : Re: [Neurodebian-users] fsl-5.0-gpu

> The result of cat /etc/proc/cpuinfo | grep 'model name' is
> Intel(R) Core(TM) i7-2630QM CPU @ 2.00GHz which includes an Intel® HD Graphics 3000. So I don't need the NVIDIA GPU to have graphics on my laptop.

Excellent.

> However the nvidia-settings program shows that the nvidia gpu is in used.
 > [snip]

You may need to take a look in your BIOS to change the primary GPU to
the Intel one. Also, make sure that you're no longer telling X to load
the nvidia driver (/etc/X11/xorg.conf.d/20-nvidia.conf).

I think this should work. The computer will use the intel GPU from boot,
X will automatically load the Intel driver, and the nvidia GPU will not
be used for display.

> Then I got a message "Bad substitution" when bedpostx_gpu entered bedpost_postproc_gpu.sh at line 67:
>
> subjdir=${@:${#@}}
>
> I don't know bash programming so much so I har coded subjdir and it still does not work. But at least I can really hear the fan of my GPU for a short while and the screen freezes as well which are good signs I guess. But the jobs stop
>
> /usr/share/fsl/5.0/bin/bedpostx_postproc_gpu.sh: 71: /usr/share/fsl/5.0/bin/bedpostx_postproc_gpu.
> sh: [[: not found
 >
 > So again it is the bash programming at the beggining of the
bedpostx_postproc_gpu.sh that seems to be an issue.

I agree with Yury that these are bashisms in the code. No need to hard
code the subjdir.

The shebang of the shell script declares /bin/sh as the interpreter. For
awhile there, many distros (Debian included) made the poor decision to
point /bin/sh to /bin/bash. The thing is that bash has many more
features than sh, and this lead a bunch of people to write sh scripts
that actually rely on bash features. Now debian (and many other distros)
point /bin/sh to /bin/dash (a small, fast, POSIX compliant shell meant
to mimic sh's behavior). It lacks many of the features of bash, hence
the problem here.

Change the first line of that script to:
#!/bin/bash

> I will look at that tomorrow. Thank you for the help,

Always happy to help out.

---Alex


_______________________________________________
Neurodebian-users mailing list
Neurodebian-users at lists.alioth.debian.org<mailto:Neurodebian-users at lists.alioth.debian.org>
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/neurodebian-users
_______________________________________________
Neurodebian-users mailing list
Neurodebian-users at lists.alioth.debian.org<mailto:Neurodebian-users at lists.alioth.debian.org>
http://lists.alioth.debian.org/cgi-bin/mailman/listinfo/neurodebian-users



--
Michael Hanke
http://mih.voxindeserto.de

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/neurodebian-users/attachments/20140226/4f9535bc/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: bedpostx_gpu_patch.tar.gz
Type: application/x-gzip
Size: 9203 bytes
Desc: bedpostx_gpu_patch.tar.gz
URL: <http://lists.alioth.debian.org/pipermail/neurodebian-users/attachments/20140226/4f9535bc/attachment.bin>


More information about the Neurodebian-users mailing list