[Paradiseo-help] [Paradiseo-users] Correct use of moeoObjectiveVectorTraits

Arnaud Liefooghe arnaud.liefooghe at univ-lille1.fr
Mer 24 Avr 11:03:05 CEST 2013


Hello Christoph,

> 1) moeoObjectiveVectorTraits has a private static unsigned int nObj
> property. Where and when is that set, and what information is that
> setting based on?

This can be set by the user in the main function.
For instance, if you have 5 objectives to be maximized:
  std::vector<bool> objVec(5, false);
  moeoObjectiveVectorTraits::setup(5, objVec);


> 2) Can I just create my own public nObj property in a class derived from
> moeoObjectiveVectorTraits and return that in nObjectives()? Would that
> have any drawbacks or cause bugs with other parts of the framework?

No problem to do it that way; this is the second option - cf. Lesson1
in the tutorials of MOEO


> 3) Is it customary to store all available configuration data related to
> the problem in a class derived from moeoObjectiveVectorTraits?

Yes, this is used on most functions to retrieve the number of
objective functions and if each one is to be minimized or maximized.

Best regards,
Arnaud

_______________________________________________
Paradiseo-users mailing list
Paradiseo-users at lists.gforge.inria.fr
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/paradiseo-users




Plus d'informations sur la liste de diffusion Paradiseo-help