mrgrid does not exist in mrtrix3 on HPC

Hello,
I’m working in a HPC (tcsh) and I’d need to run the mrgrid command. However in the existing installation the command does not exist in the bin folder and does not work despite correctly sourcing mrtrix3 (mrinfo works).
So I re-installed it in my local server with the code below but the issue persists and is exactly the same.

git clone https://github.com/MRtrix3/mrtrix3.git
cd mrtrix3
./configure
./build

Any idea on how I may use mrgrid? Thank you very much!

Best,
Giorgio

PS here’s some info on the version i’m using (3.0 seems to be the latest to me…):

 **mrtrix3/bin**> mrinfo --version
== mrinfo 3.0_RC2-117-gf098f097 ==
64 bit release version, built Feb 26 2018, using Eigen 3.2.92
Author(s): J-Donald Tournier (d.tournier@brain.org.au) and Robert E. Smith (robert.smith@florey.edu.au)
Copyright (c) 2008-2017 the MRtrix3 contributors.
1 Like

Hi Giorgio,

It looks like the version of MRtrix you’re using isn’t the one you compiled. A clean git clone should report version 3.0.4-48-gfdec23df (or similar). Version 3.0_RC2 is several years old, and indeed the executable you’ve got the version information from reports it was compiled (built) in Feb 2018…

I suspect your PATH is set to the location of an older installation, and that’s what it will use until you change that. You can easily check the exact location of the executable that the system will use using the which command, e.g.:

$ which mrinfo
/home/donald/mrtrix3/bin/mrinfo

If you need to invoke the specific executable you’ve just compiled, you can ensure the correct one is used by specifying the full path to it, e.g. (depending on where your installation is):

$ ~/mrtrix3/bin/mrinfo

You can also set the PATH for your own account using our set_path script:

$ cd mrtrix3/
$ ./set_path

which should set that variable appropriately to ensure it finds the executables you compiled first. Note that it will only take effect once you restart your terminal (and assuming you’re using the bash shell). You can also set the PATH yourself using whichever means work for you – if you need more information, the PATH is a standard Unix concept, you’ll find plenty of information on what it does and how to manipulate it online.

I hope that helps,
Donald.

Sorry, just spotted this. Indeed, our ./set_path script only caters for the bash shell… For the tcsh, you can easily replicate by adding this line to your ~/.cshrc (edited as appropriate):

setenv PATH '/home/your_username/mrtrix3/bin\:$PATH'

I think something like that’ll work… I don’t use tcsh myself, but there are lots of online tutorials available, e.g. this one.