siRelax

Questions about Anatomist manipulation

Moderators: denghien, riviere

User avatar
Olivier Coulon
Posts: 176
Joined: Fri Feb 27, 2004 11:48 am
Location: MeCA research group, Institut de Neurosciences de La Timone, Marseille, France
Contact:

siRelax

Post by Olivier Coulon »

Hi there,
I suppose my question is mostly for Denis here (again :wink: ).
I am trying to use the siRelax command and I have a few questions about the parameter file.
I am building a parameter file using the siRelax.stx syntax, found in sigraph-main/shared/config/
You (Denis) once told me that I could give several graphs instead of one as an input. Should I just consider that the graphFile attribute is a vector of strings, then ?
What about the labelsMapFile attribute ? It is irrelevant for my process, but it has a default value. Should I just ignore it and consider that my models will never use it ? Is it looked for during the relaxation ? (I just want to make sure that it will not disturb the minimisation in a way I don't understand).
That's all for now, thank you very much in advance.

Olivier
Olivier Coulon
Institut de Neurosciences de La Timone,
Aix-Marseille Université,
Marseille, france
https://meca-brain.org
User avatar
riviere
Site Admin
Posts: 1361
Joined: Tue Jan 06, 2004 12:21 pm
Location: CEA NeuroSpin, Saint Aubin, France
Contact:

Post by riviere »

Hi Olivier,
Yes, the relaxation process has been modified to accept several graphs as input. The parameters format doesn't currently allow vectors of strings (this limitation will disapear when we use XML parameter files, soon), so you have to separate filenames by a '|' (pipe character):

Code: Select all

graphFile toto.arg|tutu.arg|ploplo.arg
All graphs are concatenated into a single one.

labelsMapFile specifies a translation file for labels, it is common to many cortical folds algorithms, but in your case it won't be used. In siRelax, I guess it is only useful when initializing labels with existing values (before starting the relaxation) if it is even used at all...
During the relaxation, labels are taken from the model graph.

Denis
User avatar
Olivier Coulon
Posts: 176
Joined: Fri Feb 27, 2004 11:48 am
Location: MeCA research group, Institut de Neurosciences de La Timone, Marseille, France
Contact:

Post by Olivier Coulon »

Thank you Denis.
Olivier Coulon
Institut de Neurosciences de La Timone,
Aix-Marseille Université,
Marseille, france
https://meca-brain.org
User avatar
Olivier Coulon
Posts: 176
Joined: Fri Feb 27, 2004 11:48 am
Location: MeCA research group, Institut de Neurosciences de La Timone, Marseille, France
Contact:

Post by Olivier Coulon »

HI,
I am back with some more problems.
When I call :

Code: Select all

 siRelax paramFile.tree
I get the following message :

Code: Select all

missing semantic attribute label
terminate called after throwing an instance of 'carto::invalid_format_error'
what() :  missing semantic attribute label
I used the syntax defined by the file : sigraph-main/shared/config/siRelax.stx
and my parameter file looks like that :

Code: Select all

*BEGIN TREE siRelax
modelFile		(path)/functionalsketchmodel.arg
graphFile		(path)/graph1.arg|(path)/graph2.arg|...
output			 /home/olivier/data/spmt-stats/labelled.arg
save			 1
temp			 20000.0
mode			gibbs
rate			  0.99
tempICM		      1000.0
gibbsChange	     1
verbose			1
plotfile		/home/olivier/data/spmt-stats/energy.log
*END
As far as I understand, a 'label' attribute is expected which does not appear in the syntax. Any idea about what's wrong ?
Yhanks in advance,

Olivier
Olivier Coulon
Institut de Neurosciences de La Timone,
Aix-Marseille Université,
Marseille, france
https://meca-brain.org
User avatar
riviere
Site Admin
Posts: 1361
Joined: Tue Jan 06, 2004 12:21 pm
Location: CEA NeuroSpin, Saint Aubin, France
Contact:

Post by riviere »

Hi Olivier,

I guess the missing attribute is not in the parameters file but in one of the graphs loaded for the relaxation. Either the data graphs (but I think label is not mandatory), or, more probably, the model graph.

Denis
User avatar
Olivier Coulon
Posts: 176
Joined: Fri Feb 27, 2004 11:48 am
Location: MeCA research group, Institut de Neurosciences de La Timone, Marseille, France
Contact:

Post by Olivier Coulon »

Yes, that's what it was, I don't use the label attribute and I did not realise it was mandatory in the nodes of the model graph.
As always : thank you Denis,

Olivier
Olivier Coulon
Institut de Neurosciences de La Timone,
Aix-Marseille Université,
Marseille, france
https://meca-brain.org
User avatar
Olivier Coulon
Posts: 176
Joined: Fri Feb 27, 2004 11:48 am
Location: MeCA research group, Institut de Neurosciences de La Timone, Marseille, France
Contact:

tree files that define models for siRelax

Post by Olivier Coulon »

Hi there,
what are the syntax files for tree files that define models (for siRelax) ?
I looked in the siRelax/main/shared/ directory but still can't find one ?
Thanks ,

Olivier
Olivier Coulon
Institut de Neurosciences de La Timone,
Aix-Marseille Université,
Marseille, france
https://meca-brain.org
User avatar
Olivier Coulon
Posts: 176
Joined: Fri Feb 27, 2004 11:48 am
Location: MeCA research group, Institut de Neurosciences de La Timone, Marseille, France
Contact:

Post by Olivier Coulon »

Me again,
I found it in :

shared/main/nomenclature/syntax/adap.stx

Sorry about the previous question, I should have looked there before...

Olivier
Olivier Coulon
Institut de Neurosciences de La Timone,
Aix-Marseille Université,
Marseille, france
https://meca-brain.org
User avatar
riviere
Site Admin
Posts: 1361
Joined: Tue Jan 06, 2004 12:21 pm
Location: CEA NeuroSpin, Saint Aubin, France
Contact:

Post by riviere »

Yes that's it: it's not specific to siRelax but common to all model graphs and programs using them (including anatomist). So it's in the shared part.
Denis
User avatar
Olivier Coulon
Posts: 176
Joined: Fri Feb 27, 2004 11:48 am
Location: MeCA research group, Institut de Neurosciences de La Timone, Marseille, France
Contact:

Post by Olivier Coulon »

Hello Denis and others,
some more questions about siRelax :
- every N iterations, with N a parameter, the annealing does three "special" iterations :
Void pass
CONN_VOID
CONNECT
What are those ? I can't figure out what they do. Is there a way to turn those "extensions" off ?

Thanks in advance,

Olivier
Olivier Coulon
Institut de Neurosciences de La Timone,
Aix-Marseille Université,
Marseille, france
https://meca-brain.org
User avatar
Jean-Francois Mangin
Posts: 337
Joined: Mon Mar 01, 2004 10:24 am
Location: Neurospin, CEA, France
Contact:

Post by Jean-Francois Mangin »

Well,
the annealing schedule dedicated to the sulci is not based on a standard Gibbs sampling. It is a bit tricky to explain in a few words but we added some iterations inspired from some other dynamics usually used to sample phase transitions of spin glasses. Practically, these specific iterations consists in looping on the labels (sulci): for each label, we consider the following transitions: turn the whole label to unknown, turn one of the connected components of the label to unknown. The idea is to get rid of the local minima related to the fact that a label can be made up of a a lot of nodes. Therefore, local modifications of one single node fail at discovering a way to escape. With a more intuitive language, a wrong choice for a sulcus can nor be removed easily one node after another. In return, globally, mistakes are easier to detect.

A last point, this dynamics means our algorithm is not a conventional annealing. The transitions, indeed, are nor reversible.

I do not know where is the mecanism to turn that off. Knowing Denis'habit, I would gamble on a configuration file with the tree/graph format. Denis is skiing this week...
User avatar
Olivier Coulon
Posts: 176
Joined: Fri Feb 27, 2004 11:48 am
Location: MeCA research group, Institut de Neurosciences de La Timone, Marseille, France
Contact:

Post by Olivier Coulon »

Thanks Jeff,
there is a parameter file for siRelax that can be used to define all options. That is what I am using. And there seems to be a way to turn off the aznnealing extension but I do not know the exact syntax for that. Since Denis generates the parameter file "on the fly" in the Brainvisa recognition process, I do not have any example showing how to define each parameter. Anyway, little by little I understand.
I would also know how to set the 'unknown' label to another value ('0'). It is possible as an option but I don't know how to set it up in the parameter file. Maybe you know ?
I don't think you should let Denis go skiing, it's a very dangerous activity and he is very precious to me at the moment :wink:
Thanks for your answer,

Olivier
Olivier Coulon
Institut de Neurosciences de La Timone,
Aix-Marseille Université,
Marseille, france
https://meca-brain.org
User avatar
Jean-Francois Mangin
Posts: 337
Joined: Mon Mar 01, 2004 10:24 am
Location: Neurospin, CEA, France
Contact:

Post by Jean-Francois Mangin »

The parameter file should be written in the /tmp in think, otherwise I may found one somewhere tomorrow. Today I work from home. I know nothing about the unknown option...
User avatar
Olivier Coulon
Posts: 176
Joined: Fri Feb 27, 2004 11:48 am
Location: MeCA research group, Institut de Neurosciences de La Timone, Marseille, France
Contact:

Post by Olivier Coulon »

It's alright Jeff, don't bother looking for oàne. I can see what the brainvisa process is generating, my only problem is that it is using a lot of default values so not all the options are explicitely set up. I guess I have to wait for Denis' return.
thanks a lot,

Olivier
Olivier Coulon
Institut de Neurosciences de La Timone,
Aix-Marseille Université,
Marseille, france
https://meca-brain.org
User avatar
riviere
Site Admin
Posts: 1361
Joined: Tue Jan 06, 2004 12:21 pm
Location: CEA NeuroSpin, Saint Aubin, France
Contact:

Post by riviere »

Hi,
I'm back (in one piece, nothing broken!)...
The process in BrainVisa only uses a simplified mode of siRelax: it doesn't feed some parameters which have a default value in siRelax.
You already have found the list of parameters in sigraph/shared/config/siRelax.cfg: here you need to specify voidMode, voidLabel and/or voidOccurency. You can use:

Code: Select all

voidMode NONE
voidLabel 0
I don't know if the default void passes are of any interest for your application or not - they may be.
Trick: in Anatomist, there is a recognition module which performs the relaxation with a colored 3D display while it runs. The configuration panel for it shows a (quite) complete set of options and basic help on tooltips. To use it, load in Anatomist both a data graph and a model graph, make a fusion with them (FusionGraph), and then on the new object (AFGRAPH), you can get the annealing panel.
Does it help ?
Denis
Post Reply