New style for MOEO
git-svn-id: svn://scm.gforge.inria.fr/svnroot/paradiseo@788 331e1502-861f-0410-8da2-ba01fb791d7f
This commit is contained in:
parent
7161febf9c
commit
39709d3d12
103 changed files with 2607 additions and 2521 deletions
|
|
@ -1,4 +1,4 @@
|
|||
/*
|
||||
/*
|
||||
* <moeoRouletteSelect.h>
|
||||
* Copyright (C) DOLPHIN Project-Team, INRIA Futurs, 2006-2007
|
||||
* (C) OPAC Team, LIFL, 2002-2007
|
||||
|
|
@ -47,8 +47,8 @@
|
|||
*/
|
||||
template < class MOEOT >
|
||||
class moeoRouletteSelect:public moeoSelectOne < MOEOT >
|
||||
{
|
||||
public:
|
||||
{
|
||||
public:
|
||||
|
||||
/**
|
||||
* Ctor.
|
||||
|
|
@ -56,12 +56,12 @@ public:
|
|||
*/
|
||||
moeoRouletteSelect (unsigned int _tSize = 2) : tSize (_tSize)
|
||||
{
|
||||
// consistency check
|
||||
if (tSize < 2)
|
||||
// consistency check
|
||||
if (tSize < 2)
|
||||
{
|
||||
std::
|
||||
cout << "Warning, Tournament size should be >= 2\nAdjusted to 2\n";
|
||||
tSize = 2;
|
||||
std::
|
||||
cout << "Warning, Tournament size should be >= 2\nAdjusted to 2\n";
|
||||
tSize = 2;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -72,16 +72,16 @@ public:
|
|||
*/
|
||||
const MOEOT & operator () (const eoPop < MOEOT > & _pop)
|
||||
{
|
||||
// use the selector
|
||||
return mo_roulette_wheel(_pop,tSize);
|
||||
// use the selector
|
||||
return mo_roulette_wheel(_pop,tSize);
|
||||
}
|
||||
|
||||
|
||||
protected:
|
||||
protected:
|
||||
|
||||
/** size */
|
||||
double & tSize;
|
||||
|
||||
};
|
||||
};
|
||||
|
||||
#endif /*MOEOROULETTESELECT_H_ */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue