New User

97 views
Skip to first unread message

ab698

unread,
Sep 25, 2008, 10:13:23 AM9/25/08
to GCVA
Hi Chris and y'all!!!!1

Dumb question number 1. Does this code work with nifit-1.

If it does then what's this error message all about ?!?

Cheers
Anna

error message
-------------------------------------------------------------------
Stdsm155.ATgry.nii
Stdsm159.ATgry.nii

Merging all pathnames to a single array variable...

Pathnames for target images are now merged.

Uploading a raw image from Stdsm000.ATgry.nii
??? Bad image handle dimensions.

Error in ==> spm_read_vols at 34
Y(:,:,p,i) = spm_slice_vol(V(i),spm_matrix([0 0 p]),V(i).dim(1:2),0);

Error in ==> upload_images_f at 68
target_images(:, :, :, i) =
spm_read_vols(spm_vol(image_paths_for_all_tasks(i, :)));

Error in ==> PCA_suite_f at 204
[vars.target_images, vars.meanful_set, vars.dim, vars.nOfTasks
vars.image_paths] ...

Chris

unread,
Sep 25, 2008, 11:32:13 AM9/25/08
to GCVA
hi Anna,

I am thrilled you're using it and use the website to document any
correspondence.

I am not sure what's going on. Do you have SPM 5 working properly?
If
so, it should be able to deal with NIFTY without any problems.

You could check with the

spm_vol

command what the image dimensions of your data array are, and whether
there are any inconsistencies. If the worst comes to the worst, send
me a
few of your images and I'll check it out.

bests - Chris

Anna Barnes

unread,
Sep 25, 2008, 1:35:50 PM9/25/08
to Christian Habeck, gc...@googlegroups.com
Okey dokey I'll look into it a bit more. I don't remember having
probs with it before with nifti images so it must be these particular
images.

Cheers
A :)

On 25 Sep 2008, at 16:26, Christian Habeck wrote:

> hi Anna,
>
> I am thrilled you're using it and use the website to document any
> correspondence.
>
> I am not sure what's going on. Do you have SPM 5 working properly?
> If so, it should be able to deal with NIFTY without any problems.
>
> You could check with the
>
> spm_vol
>
> command what the image dimensions of your data array are, and

> whether there are any inconsistencies. If the wors comes to the

> worst, send me a few of your images and I'll check it out.
>
> bests - Chris
>

> --
> Christian Habeck
> Taub Institute
> Columbia University
> ch...@columbia.edu
>

Anna Barnes

unread,
Sep 25, 2008, 2:05:40 PM9/25/08
to Christian Habeck, gc...@googlegroups.com
Had a check of the header and stuff and discovered that while I can view the image in MRICro and imageJ its just a blank white volume when displaying it in SPM5.

nifti Header looks like.  Any thoughts ?


header file 'Stdsm000.ATgry.nii', num_fields = 43

all fields:
  name                offset  nvals  values
  ------------------- ------  -----  ------
  sizeof_hdr             0      1    348
  data_type              4     10    
  db_name               14     18    
  extents                 32      1    0
  session_error         36      1    0
  regular                 38      1    r
  dim_info               39      1    0 [freq=0, phase=0, slice=0] 
  dim                     40      8    3 91 109 91 1 1 1 1
  intent_p1             56      1    0.0
  intent_p2             60      1    0.0
  intent_p3             64      1    0.0
  intent_code           68      1    0
  datatype               70      1    4 [INT16] 
  bitpix                   72      1    16
  slice_start            74      1    0
  pixdim                  76      8    0.0 2.0 2.0 2.0 1.0 1.0 1.0 1.0
  vox_offset           108      1    352.0
  scl_slope             112      1    0.00326
  scl_inter              116      1    0.0
  slice_end            120      1    0
  slice_code           122      1    0 [Unknown] 
  xyzt_units           123      1    10 [space='mm', time='s'] 
  cal_max              124      1    8834.0
  cal_min               128      1    60.0
  slice_duration       132      1    0.0
  toffset                136      1    0.0
  glmax                140      1    0
  glmin                 144      1    0
  descrip               148     80    NIFTI-1 Image
  aux_file               228     24    
  qform_code           252      1    4
  sform_code           254      1    4
  quatern_b            256      1    0.0
  quatern_c            260      1    1.0
  quatern_d            264      1    0.0
  qoffset_x            268      1    90.0
  qoffset_y            272      1    -126.0
  qoffset_z            276      1    -72.0
  srow_x               280      4    -2.0 0.0 0.0 90.0
  srow_y               296      4    0.0 2.0 0.0 -126.0
  srow_z               312      4    0.0 0.0 2.0 -72.0
  intent_name          328     16    
  magic                344      4    n+1

The file is in native machine endian.

--
Anna Barnes, PhD
Research Associate (+441223 764676)

Brain Mapping Unit (Sir William Hardy Bldg.)
Dept. of Psychiatry. 
c/o Experimental Psychology
University of Cambridge. 
Downing Site, Downing St. 
Cambridge, CB2 3EB




On 25 Sep 2008, at 16:26, Christian Habeck wrote:

hi Anna,

I am thrilled you're using it and use the website to document any correspondence.

I am not sure what's going on. Do you have SPM 5 working properly?  If so, it should be able to deal with NIFTY without any problems.

You could check with  the

spm_vol

command what the image dimensions of your data array are, and whether there are any inconsistencies. If the wors comes to the worst, send me a few of your images and I'll check it out.

bests - Chris

ab698 wrote:

Chris

unread,
Sep 25, 2008, 2:36:13 PM9/25/08
to GCVA
Not immediately, but is this is the only file that doesn't work, or
does this happen for EVERY file?

Anna Barnes

unread,
Sep 28, 2008, 5:22:38 AM9/28/08
to Christian Habeck, gc...@googlegroups.com
Hi guys
got the previous problem sorted out by switching to a 32 bit machine.

However, my boot strapping crashed at resample 32 because MATLAB was out of memory. What are the recommended memory settings fro Matlab and how do I go back to just the resampling step. I saved my vars file and then tried to load it back in at it gave me an error about non-existent target images !!!  Apart from that everything worked fine.

Cheers
Anna

--
Anna Barnes, PhD
Research Associate (+441223 764676)

Brain Mapping Unit (Sir William Hardy Bldg.)
Dept. of Psychiatry. 
c/o Experimental Psychology
University of Cambridge. 
Downing Site, Downing St. 
Cambridge, CB2 3EB




On 25 Sep 2008, at 16:26, Christian Habeck wrote:

hi Anna,

I am thrilled you're using it and use the website to document any correspondence.

I am not sure what's going on. Do you have SPM 5 working properly?  If so, it should be able to deal with NIFTY without any problems.

You could check with  the

spm_vol

command what the image dimensions of your data array are, and whether there are any inconsistencies. If the wors comes to the worst, send me a few of your images and I'll check it out.

bests - Chris

ab698 wrote:

Chris

unread,
Sep 29, 2008, 12:07:12 PM9/29/08
to GCVA
Hi Anna,

that sounds good vis-a-vis the comparison of results. The target
images were left out, otherwise the vars-structure would have been too
big. We thought that the actual data would not be needed for
comparison purposes....

Yes, this could be a bit of a memory hog. On a 4GB Linux machine this
all runs ok on our end. How many subjects do you have? You could try
to threshold the data array more conservatively and leave out more
voxels in your analysis. Does it crash immediately, or only after a
few iterations?

If you can't get it working even for low subject AND voxel numbers,
we'll have to try to reprogram the package, or rather: figure out
where memory could be saved. This might be a problem not only for you.

Chris
Reply all
Reply to author
Forward
0 new messages