[MINC-users] mincstats -mask

Robert VINCENT minc-users@bic.mni.mcgill.ca
Thu Jul 21 10:58:04 2005


Hi All,

Considering the feedback so far, my thought would be to leave the behavior
of the program "as is", except to add a warning message along the
following lines:

"Warning: mask file specified without a mask range. Mask will be ignored."

This should not break existing behavior, while providing some guidance to
the uninitiated...

	-bert

On Thu, 21 Jul 2005, Jonathan HARLAP wrote:

> On Wed, Jul 20, 2005 at 10:51:28PM -0400, Andrew Janke wrote:
> > And thus the argument begins again... :)
>
> you knew that the original simple solution was too good to be true,
> didn't you? ;P
>
> if it helps find consistency within minc, there is an analogous
> situation in mincmath in which the -segment option will use the range
> specified by -const2, and leaving out the -const2 results in an error
> message - "Operation and constants do not match".
>
> thus it sounds like the error message solution would be consistent.
>
> now i've opened it up for "well, <toolX> uses a default instead
> of complaining..." ;)
>
> > In the end the mutual disagreement from memory was to spit out an
> > error.  Of course this will break a number of (possibly previously
> > broken) scripts.
> >
> > Although I suspect Peter might crawl out of hibernation and correct me here.
> >
> > I suggest we take a vote!
> >
> >
> > a
> >
> > On 20/07/05, Alex ZIJDENBOS <alex@bic.mni.mcgill.ca> wrote:
> > > Actually, perhaps '-binvalue 1' is a bit too restrictive. I've seen
> > > people create masks with values higher than one (e.g., using
> > > Display). I think that assuming a "mask" is made up of zero- and
> > > non-zero values (with a bit of tolerance perhaps for roundoff) would
> > > be reasonable. But if that's not general enough (I suppose that was
> > > Peter's argument?), generating an error message when the mask
> > > treatment is undefined makes sense too.
> > >
> > > volume_stats, mincstats predecessor, does the former (without
> > > tolerance though). If a mask is present but no extrema are given,
> > > it'll test for mask value != 0.
> > >
> > > -- A
> > >
> > > On Wed, Jul 20, 2005 at 05:33:38PM -0400, Andrew Janke wrote:
> > > > Sounds fair to me.
> > > >
> > > > Peter and I discussed this at length when we first wrote the thing but
> > > > never managed to come to agreement.
> > > >
> > > > What has just been suggested is what I was hammering for... :)
> > > >
> > > >
> > > > a
> > > >
> > > > On 20/07/05, Robert VINCENT <bert@bic.mni.mcgill.ca> wrote:
> > > > > Hi Alex,
> > > > >
> > > > > This appears to be unchanged.  I hadn't been aware of the problem.
> > > > >
> > > > > I think adding some kind of default behavior such as -mask_binvalue 1
> > > > > would not break anything.  But I'm curious to hear other's opinions.
> > > > >
> > > > >         -bert
> > > > >
> > > > >
> > > > > On Wed, 20 Jul 2005, Alex ZIJDENBOS wrote:
> > > > >
> > > > > > A kind soul just alerted me to something possibly confusing with
> > > > > > mincstats, being that it will (silently) ignore a -mask argument if
> > > > > > not given at least one of -mask_{floor,ceil,range,binvalue}.
> > > > > >
> > > > > > In other words, the call
> > > > > >
> > > > > >    mincstats -mask <mask.mnc> -floor <your_favorite_treshold> <in.mnc>
> > > > > >
> > > > > > does nothing with <mask.mnc>. Although this is stated in the man page,
> > > > > > I suspect it is counterintuitive to many people; it seems to me
> > > > > > mincstats should either do something sensible with the mask (i.e.,
> > > > > > default to '-mask_binvalue 1'), or barf when given a mask argument
> > > > > > which is not used.
> > > > > >
> > > > > > I have a vague recollection of this being discussed before, but has it
> > > > > > been fixed in recent releases of minc?
> > > > > >
> > > > > > -- A
> > > > > > _______________________________________________
> > > > > > MINC-users@bic.mni.mcgill.ca
> > > > > > http://www.bic.mni.mcgill.ca/mailman/listinfo/minc-users
> > > > > >
> > > > >
> > > > > _______________________________________________
> > > > > MINC-users@bic.mni.mcgill.ca
> > > > > http://www.bic.mni.mcgill.ca/mailman/listinfo/minc-users
> > > > >
> > > >
> > > >
> > > > --
> > > > Andrew Janke      (a.janke@gmail.com || www.cmr.uq.edu.au/~rotor)
> > > > Canada->Montreal                                   Cell: +1 (514) 924 2012
> > > >
> > > > _______________________________________________
> > > > MINC-users@bic.mni.mcgill.ca
> > > > http://www.bic.mni.mcgill.ca/mailman/listinfo/minc-users
> > > _______________________________________________
> > > MINC-users@bic.mni.mcgill.ca
> > > http://www.bic.mni.mcgill.ca/mailman/listinfo/minc-users
> > >
> >
> >
> > --
> > Andrew Janke      (a.janke@gmail.com || www.cmr.uq.edu.au/~rotor)
> > Canada->Montreal                                   Cell: +1 (514) 924 2012
> >
> > _______________________________________________
> > MINC-users@bic.mni.mcgill.ca
> > http://www.bic.mni.mcgill.ca/mailman/listinfo/minc-users
> _______________________________________________
> MINC-users@bic.mni.mcgill.ca
> http://www.bic.mni.mcgill.ca/mailman/listinfo/minc-users
>