[MINC-users] mincaverage -avgdim result header

Peter Neelin peter.neelin at gmail.com
Mon Mar 26 23:02:26 EDT 2012


On Mar 26, 2012 9:27 AM, "Vladimir S. FONOV" <vladimir.fonov at gmail.com>
wrote:
> > The expectation is that if you are
> > going to code at the netcdf level (core minc libraries and anything that
> > talks about dimensions and variables, like mincinfo) you should
understand
> > basic netcdf. It's not really documented in minc because it's
documented in
> > netcdf.
>
> This just blew my brain...
>
> 1. what about minc2 - does one have to use HDF5 calls to work with it?

As I understand it, HDF5 provides a netcdf interface. That's how minc works
with it. Remember, I'm talking about writing code that uses the lowest
level minc. Plus using mincinfo since I took the shortcut of just exposing
a bunch of netcdf calls through it, since netcdf did not provide any
command-line tool. I foolishly exposed low-level stuff to the command-line
through mincreshape as well. Back when I didn't think so much about
encapsulation and abstraction.

> 2. practical observation - most minc users don't  care/read minc API
> documentation. For them it is just another file format, like nifti or
> nrrd. Most of the high-level perl code that I've seen uses system
> calls to minc tools to work with the files. Does it mean that this is
> incorrect approach?

Not at all. It is in fact the right thing to do. Most minc programs are
abstractions on top of low-level minc and netcdf. Mincinfo isn't really.
But I would still suggest that it's worth learning something about the
basic file format if you are going to do anything fancy that tries to grok
the file format. It's sort of like playing with DICOM using dcmtk without
understanding anything about groups, elements, VRs, etc. These are the
basic concepts of the format.

On the other hand, using mincresample or mincaverage or minccalc, you
should mostly be able to ignore a lot of the lower-level stuff.
(Unfortunately, the abstraction is still rather leaky, so you are still
exposed to a lot of the low-level stuff like typing and dimension ordering)

Peter
--
Peter Neelin
peter.neelin at gmail.com


More information about the MINC-users mailing list