Graph Transfert Labels

AIMS library and commands usage

Moderators: riviere, denghien

User avatar
François Leroy
Posts: 30
Joined: Wed Feb 22, 2006 5:22 pm

Graph Transfert Labels

Postby François Leroy » Wed Nov 12, 2008 11:33 am


I cannot update a cortical fold graph "graph1.arg" by a modified graph version "graph2.arg".
"graph1" and "graph2" have all their fold labeled. "graph1" folds have proper names except for a set of folds, say foldA foldB and foldC.
I would like to update "graph1" by getting foldA foldB and foldC from "graph2", where these three folds are properly labelled.
Is there a way to do it, such as using the AimsGraphTransfertLabels command ?

I have tried the following : AimsGraphTransfertLabels -i graph1.arg -j graph2.arg -o graph3.arg.
However, when I look into the graph result "grap3.arg", foldA, B and C are not updated with graph2 names.
Is there a some command option to set to make it work ? Or should I use another AimsCommand?

Thanks for your help,

User avatar
Site Admin
Posts: 1361
Joined: Tue Jan 06, 2004 12:21 pm
Location: CEA NeuroSpin, Saint Aubin, France

Re: Graph Transfert Labels

Postby riviere » Wed Nov 12, 2008 11:53 am

Hi François,

Hm, AimsGraphTransferLabels overrides existing labels with the ones from another graph, so it will not do what you want.
If I understand, both graphs have the same structure (same nodes/relations, they are only labelled differently).
AimsGraphMerge may do a part of what you need, but it would rather complete nodes with missing attributes (nodes with no label attribute for instance): in this case unnamed sulci should have no label attribute rather than "unknown". This means it would not work using the "name" attribute (for manual labelling) because this one is mandatory and cannot be missing.
Then I guess you will have to write a little program (or python script) to do that, I think it should be 15-20 lines of code...


Return to “AIMS”

Who is online

Users browsing this forum: No registered users and 1 guest