[MINC-users] using pyminc to convert a philips/ugm file

Graeme O'Keefe graeme.okeefe at petnm.unimelb.edu.au
Fri Sep 16 00:57:05 EDT 2011


thanks Andrew,

for now, my workaround is to use rawtominc.

ie. something like this.

cat p2151s0_VAL_PIBdy28.raw | rawtominc -float -ofloat -xstep 2 -ystep 2 -zstep 2 -xstart -128 -ystart -128 -zstart -45 p2151s0_VAL_PIBdy28.mnc 28 90 128 128 -frame_widths "30,30,30,30,60,60,60,60,60,60,60,60,60,180,180,180,300,300,300,300,300,300,300,300,300,300,600,600" -frame_times "0,30,60,90,120,180,240,300,360,420,480,540,600,660,840,1020,1200,1500,1800,2100,2400,2700,3000,3300,3600,3900,4200,4800"

regards,

Graeme

On 15/09/2011, at 10:52 AM, Andrew Janke wrote:

> Hi Graeme,
> 
> On 14 September 2011 21:25, Graeme O'Keefe
> <graeme.okeefe at petnm.unimelb.edu.au> wrote:
>> I'm trying to use pyminc to convert a dynamic PET scan in Philips format (UGM) to minc2.
>> 
>> The time-step is not constant.
>> 
>> Would anyone be able to tell me how I would save a "tspace" vector containing the times of each frame using volumeFromDescription?
> 
> I can't answer for pyminc but see you don't have an answer yet the
> pyminc types so in the meantime this might work for you as a hack
> solution via a system() call. From the command line you would do this:
> 
>   mincinfo -varvalue time out.mnc
> 
> This will return a newline separated vector, providing that
> 
>   mincinfo -attvalue time:spacing out.mnc
> 
> returns 'irregular'.
> 
> 
> a
> _______________________________________________
> MINC-users at bic.mni.mcgill.ca
> http://www.bic.mni.mcgill.ca/mailman/listinfo/minc-users
> 




More information about the MINC-users mailing list