[Geeks] volgenmodel -- or howidunit.
Andrew Janke
a.janke at gmail.com
Wed Oct 22 02:29:11 EDT 2008
Hi all,
As of late I have been asked many times for how I do automated
recursive nonlinear model generation. Previously I did this via a
directory of interrelated scripts as I was still fiddling with the
process (and will likely continue to do so :).
So I decided to sit down and do a complete rewrite if only to clear my
head, I have taken a bit of poetic licence on the "correct" process, I
also happen to know that Vlad has a "makeamodel" ruby script thing
that I think some are also using so this will just add to the
confusion....
In any case I have attached a (very) beta version that should be able
to make a nonlinear model for you with some fairly sensible default
parameters, it does have batch ability but this is largely untested as
of yet. Using it may well make your whites brown. There is no, repeat
NO support for this version but it might appease those who have been
bugging me about this...
Typical usage:
$ volgenmodel -output_model funky-model.mnc -workdir ./work
infile1.mnc infile2.mnc infile3.mnc infile4.mnc ....
If you want to open a wormhole try this:
$ volgenmodel -batch -output_model funky-model.mnc -workdir ./work
infile1.mnc infile2.mnc infile3.mnc infile4.mnc ....
the main reason for the early disclosure is that I want feedback on
the mcomplete() and do_cmd_batch() functions in there, I note that
do_cmd() now has some fairly widespread usage so am interested in if
this is also what people might be after. The purpose of mcomplete is
to get around the problem of using MINC calls in perl scripts with
something like this:
$outfile = "out.mnc";
if(-e $outfile){
print "Exists, doing nothing\n";
}
else{
&do_cmd("mincmath ...$outfile");
}
The problem being if $outfile exists but is broken for some reason and
thus your script breaks. The idea is to instead do this:
$outfile = "out.mnc";
if(&mcomplete($outfile)){
print "Exists (and is good), doing nothing\n";
}
else{
&do_cmd("mincmath ...$outfile");
}
--
Andrew Janke - andrew.janke at anu.edu.au
Department of Geriatric Medicine, ANU
(a.janke at gmail.com || http://a.janke.googlepages.com/)
Canberra->Australia +61 (402) 700 883
-------------- next part --------------
A non-text attachment was scrubbed...
Name: volgenmodel
Type: application/octet-stream
Size: 14340 bytes
Desc: not available
Url : http://www2.bic.mni.mcgill.ca/pipermail/geeks/attachments/20081022/6581adee/attachment.obj
More information about the Geeks
mailing list