Hi krishna,

First, I want to be the first to say I don't have this all figured out.  
I've been struggling with it myself -- namely trying to get surfaces 
back in true "orig" orientation, origin, etc., so that functional 
volumes need not be messed with to ensure proper mapping.  But that is a 
taller order.

Second, it might be that mapping in Freesurfer might be easier.  But 
when you need to map in Caret, there is hope.

I'm not sure, without looking at your data (which I'm not dying to do, 
but will if asked), but it might be that you just need a translated 
version of your surface, like so:

  #################################################
  # Shift surface from Freesurfer space to orig
  #################################################
  X_OFFSET=`$FREESURFER_DIR/bin/mri_info --cras ../mri/orig.LPI.nii | 
cut -f1 -d' '`
  Y_OFFSET=`$FREESURFER_DIR/bin/mri_info --cras ../mri/orig.LPI.nii | 
cut -f2 -d' '`
  Z_OFFSET=`$FREESURFER_DIR/bin/mri_info --cras ../mri/orig.LPI.nii | 
cut -f3 -d' '`
  MATRIX="1.0 0.0 0.0 $X_OFFSET 0.0 1.0 0.0 $Y_OFFSET 0.0 0.0 1.0 
$Z_OFFSET 0.0 0.0 0.0 1.0"
  caret_command -surface-apply-transformation-matrix 
Human.$CASE.$HEM_FLAG.Midthickness.coord Human.$CASE.$HEM_FLAG.topo 
Human.$CASE.$HEM_FLAG.Midthickness_orig.coord -matrix $MATRIX

... where ../mri/orig.LPI.nii is simply a rotated/flipped version of 
your orig volume in what I still call LPI orientation (left-to-right, 
posterior-to-anterior, inferior-to-superior).  I generated mine like so:

    $FREESURFER_DIR/bin/mri_convert $VOLUME.mgz --reslice_like 
$ATLAS_DIR/TEMPLATE.LPI.nii -rt nearest $VOLUME.LPI.nii

... where $ATLAS_DIR/TEMPLATE.LPI.nii is a null volume with these 
characteristics:

it.wustl.edu 4% 3dinfo ./PUBS/OHBM/2010/PALS_B12.LR/TEMPLATE.LPI.nii

Dataset File:    ./PUBS/OHBM/2010/PALS_B12.LR/TEMPLATE.LPI.nii
Geometry String: 
"MATRIX(-1,-3.55271e-15,0,134.5764,0,-1,1.111172e-08,116.8553,-2.03682e-16,9.498479e-10,1,-131.896):256,256,256"
  third  (z) = Inferior-to-Superior   [-orient LPI]
R-to-L extent:  -120.424 [R] -to-   134.576 [L] -step-     1.000 mm [256 
voxels]
A-to-P extent:  -138.145 [A] -to-   116.855 [P] -step-     1.000 mm [256 
voxels]
I-to-S extent:  -131.896 [I] -to-   123.104 [S] -step-     1.000 mm [256 
voxels]

(Off the top of my head, I'm not certain getting the cras offset from 
the LPI version is strictly required here, but I think I had a good 
reason for doing it that way in my code.)

After translating the surface by the cras offset (which I think of as 
translating from Freesurfer coordinate space to orig space), then try 
mapping to this translated surface.

I don't think it will be an issue for you, comparing your FS to Caret 
mappings, but for some people, rotating/flipping the functional volumes 
to LPI sometimes helps.

Donna

On 12/10/2010 11:36 AM, Krishna Srihasam wrote:
> Hi,
>
> So, I finally got my Freesurfer surfaces into caret. But when I try to 
> put my functional activations on the imported surfaces in caret. They 
> are out of place. I used "Map Volume to Surface" to overlay the 
> activations on top of the imported surface. I tried both "Map to 
> caret" and "Map to Spec File" and I am getting the same difference in 
> locations of activations. What am I doing wrong?
>
> I have attached two files "ActivationsonCaret.jpg" and 
> "ActivationonFreeSurfer.jpg" to highlight my problem.
>
> regards,
> krishna
>
> On 12/08/2010 12:07 PM, Donna Dierker wrote:
>> Hi Krishna,
>>
>> We haven't spent any time streamlining this process, but this script
>> worked for me a few months back:
>>
>> http://brainmap.wustl.edu/pub/donna/FREESURFER/SCRIPTS/import.sh
>> login pub
>> password download
>>
>> Edit the case name and hemisphere.  You'd have to adapt it to run both
>> hems in one go.
>>
>> Note that this just imports; it doesn't register to F99 or F6.
>>
>> Donna
>>
>> On 12/08/2010 10:40 AM, Krishna Srihasam wrote:
>>   
>>> Hi,
>>>
>>> Is there any way to convert my monkey freesurfer surfaces to caret?
>>>
>>> rgds,
>>> Krishna
>>> _______________________________________________
>>> caret-users mailing list
>>> [email protected]
>>> http://brainvis.wustl.edu/mailman/listinfo/caret-users
>>>
>>>      
>> _______________________________________________
>> caret-users mailing list
>> [email protected]
>> http://brainvis.wustl.edu/mailman/listinfo/caret-users
>>    
>
>
> ------------------------------------------------------------------------
>
>
> ------------------------------------------------------------------------
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> caret-users mailing list
> [email protected]
> http://brainvis.wustl.edu/mailman/listinfo/caret-users
>   

_______________________________________________
caret-users mailing list
[email protected]
http://brainvis.wustl.edu/mailman/listinfo/caret-users

Reply via email to