Commit b1e2eea3 authored by Frédéric Krüger's avatar Frédéric Krüger

Modification des parametre (passage a true/false)

parent 99111d81
......@@ -631,36 +631,41 @@ Parameter
strcat(sIP_FILE,$4->sName);
}
| PRINT_STATS NUMBER2{
if((int)$2>=1)
bPRINT_STATS=1;
else
bPRINT_STATS=0;
}
| PLOT_STATS NUMBER2{
if((int)$2>=1)
bPLOT_STATS=1;
else
bPLOT_STATS=0;
}
| GENERATE_CSV_FILE NUMBER2{
if((int)$2>=1)
bGENERATE_CSV_FILE=1;
else
bGENERATE_CSV_FILE=0;
}
| GENERATE_GNUPLOT_SCRIPT NUMBER2{
if((int)$2>=1)
bGENERATE_GNUPLOT_SCRIPT=1;
else
bGENERATE_GNUPLOT_SCRIPT=0;
}
| GENERATE_R_SCRIPT NUMBER2{
if((int)$2>=1)
bGENERATE_R_SCRIPT=1;
else
bGENERATE_R_SCRIPT=0;
}
| PRINT_STATS IDENTIFIER2{
if (!mystricmp($2->sName,"False")) bPRINT_STATS=0;
else if (!mystricmp($2->sName,"True")) bPRINT_STATS=1;
else {
fprintf(stderr,"\n%s - Warning line %d: Print stats must be \"True\" or \"False\".\nDefault value \"False\" inserted.\n.",sEZ_FILE_NAME,EASEALexer.yylineno);nWARNINGS++;
bPRINT_STATS=0;
}}
| PLOT_STATS IDENTIFIER2{
if (!mystricmp($2->sName,"False")) bPLOT_STATS=0;
else if (!mystricmp($2->sName,"True")) bPLOT_STATS=1;
else {
fprintf(stderr,"\n%s - Warning line %d: Generate stats must be \"True\" or \"False\".\nDefault value \"False\" inserted.\n.",sEZ_FILE_NAME,EASEALexer.yylineno);nWARNINGS++;
bPLOT_STATS=0;
}}
| GENERATE_CSV_FILE IDENTIFIER2{
if (!mystricmp($2->sName,"False")) bGENERATE_CSV_FILE=0;
else if (!mystricmp($2->sName,"True")) bGENERATE_CSV_FILE=1;
else {
fprintf(stderr,"\n%s - Warning line %d: Generate csv file must be \"True\" or \"False\".\nDefault value \"False\" inserted.\n.",sEZ_FILE_NAME,EASEALexer.yylineno);nWARNINGS++;
bGENERATE_CSV_FILE=0;
}}
| GENERATE_GNUPLOT_SCRIPT IDENTIFIER2{
if (!mystricmp($2->sName,"False")) bGENERATE_GNUPLOT_SCRIPT=0;
else if (!mystricmp($2->sName,"True")) bGENERATE_GNUPLOT_SCRIPT=1;
else {
fprintf(stderr,"\n%s - Warning line %d: Generate gnuplot script must be \"True\" or \"False\".\nDefault value \"False\" inserted.\n.",sEZ_FILE_NAME,EASEALexer.yylineno);nWARNINGS++;
bGENERATE_GNUPLOT_SCRIPT=0;
}}
| GENERATE_R_SCRIPT IDENTIFIER2{
if (!mystricmp($2->sName,"False")) bGENERATE_R_SCRIPT=0;
else if (!mystricmp($2->sName,"True")) bGENERATE_R_SCRIPT=1;
else {
fprintf(stderr,"\n%s - Warning line %d: Generate R script must be \"True\" or \"False\".\nDefault value \"False\" inserted.\n.",sEZ_FILE_NAME,EASEALexer.yylineno);nWARNINGS++;
bGENERATE_R_SCRIPT=0;
}}
| SAVE_POPULATION IDENTIFIER2{
if (!mystricmp($2->sName,"False")) bSAVE_POPULATION=0;
else if (!mystricmp($2->sName,"True")) bSAVE_POPULATION=1;
......
......@@ -113,10 +113,10 @@ CPPFLAGS+=
Final reduce operator:Deterministic //Deterministic, Tournament, Random, Roulette(only Maximise)
Elitism: Strong //Weak or Strong
Elite: 5
Print stats:1 //Default: 1
Generate csv stats file:0
Generate gnuplot script:0
Generate R script:0
Plot stats:0 //Default: 0
Print stats:true //Default: 1
Generate csv stats file:false
Generate gnuplot script:false
Generate R script:false
Plot stats:false //Default: 0
\end
......@@ -118,10 +118,10 @@ LIBS+=
Final reduce operator:Deterministic //Deterministic, Tournament, Random, Roulette(only Maximise)
Elitism: Strong //Weak or Strong
Elite: 5
Print stats:1 //Default: 1
Generate csv stats file:0
Generate gnuplot script:0
Generate R script:0
Plot stats:0 //Default: 0
Print stats:true //Default: 1
Generate csv stats file:false
Generate gnuplot script:false
Generate R script:false
Plot stats:false //Default: 0
\end
......@@ -175,10 +175,10 @@ CPPFLAGS+=
Number of optimisation iterations : 100 //Number of optimisation iteration
Baldwinism : false //True or False (Lamarckism : keep optimised Genome)
Print stats:1 //Default: 1
Generate csv stats file:0
Generate gnuplot script:0
Generate R script:0
Plot stats:0 //Default: 0
Print stats:true //Default: 1
Generate csv stats file:false
Generate gnuplot script:false
Generate R script:false
Plot stats:false //Default: 0
\end
......@@ -218,10 +218,10 @@ CPPFLAGS+=
Number of optimisation iterations : 1 //Number of optimisation iteration
Baldwinism : false //True or False (Lamarckism : keep optimised Genome)
Print stats:1 //Default: 1
Generate csv stats file:0
Generate gnuplot script:0
Generate R script:0
Plot stats:0 //Default: 0
Print stats:true //Default: 1
Generate csv stats file:false
Generate gnuplot script:false
Generate R script:false
Plot stats:false //Default: 0
\end
......@@ -179,10 +179,10 @@ CPPFLAGS+=
Number of optimisation iterations : 100 //Number of optimisation iteration
Baldwinism : true //True or False (Lamarckism : keep optimised Genome
Print stats:1 //Default: 1
Generate csv stats file:0
Generate gnuplot script:0
Generate R script:0
Plot stats:0 //Default: 0
Print stats:true //Default: 1
Generate csv stats file:false
Generate gnuplot script:false
Generate R script:false
Plot stats:false //Default: 0
\end
......@@ -218,10 +218,10 @@ CPPFLAGS+=
Number of optimisation iterations : 1 //Number of optimisation iteration
Baldwinism : false //True or False (Lamarckism : keep optimised Genome
Print stats:1 //Default: 1
Generate csv stats file:0
Generate gnuplot script:0
Generate R script:0
Plot stats:0 //Default: 0
Print stats:true //Default: 1
Generate csv stats file:false
Generate gnuplot script:false
Generate R script:false
Plot stats:false //Default: 0
\end
......@@ -162,11 +162,11 @@ CPPFLAGS+=
Elitism: Strong //Weak or Strong
Elite: 1
Print stats:1 //Default: 1
Generate csv stats file:0
Generate gnuplot script:0
Generate R script:0
Plot stats:0 //Default: 0
Print stats:true //Default: 1
Generate csv stats file:false
Generate gnuplot script:false
Generate R script:false
Plot stats:false //Default: 0
Remote island model: true
IP file: ip.txt //File containing all the remote island's IP
......
......@@ -181,11 +181,11 @@ CPPFLAGS+=
Elitism: Strong //Weak or Strong
Elite: 5
Print stats:1 //Default: 1
Plot stats:0 //Default: 0
Generate csv stats file:0
Generate gnuplot script:0
Generate R script:0
Print stats:true //Default: 1
Plot stats:false //Default: 0
Generate csv stats file:false
Generate gnuplot script:false
Generate R script:false
\end
......@@ -184,11 +184,11 @@ CPPFLAGS+=
Elitism: Strong //Weak or Strong
Elite: 1
Print stats:1 //Default: 1
Generate csv stats file:0
Generate gnuplot script:0
Generate R script:0
Plot stats:0 //Default: 0
Print stats: true //Default: 1
Generate csv stats file:false
Generate gnuplot script:false
Generate R script:false
Plot stats:false //Default: 0
Remote island model: true
IP file: ip.txt //File containing all the remote island's IP
......
......@@ -435,8 +435,6 @@ void CEvolutionaryAlgorithm::receiveIndividuals(){
this->server->read_data_lock();
string line = this->server->parm->data[this->treatedIndividuals].data;
this->population->parents[index]->deserialize(line);
this->population->parents[index]->valid = false;
this->population->parents[index]->evaluate();
this->server->read_data_unlock();
//cout << "new Individual :" << this->population->parents[index]->serialize() << endl;
this->treatedIndividuals++;
......
......@@ -466,9 +466,6 @@ void ParametersImpl::setDefaultParameters(int argc, char** argv){
if(parentReductionSize<parentPopulationSize) parentReduction = true;
else parentReduction = false;
cout << "Parent red " << parentReduction << " " << parentReductionSize << "/"<< parentPopulationSize << endl;
cout << "Parent red " << offspringReduction << " " << offspringReductionSize << "/" << offspringPopulationSize << endl;
generationalCriterion = new CGenerationalCriterion(setVariable("nbGen",(int)\NB_GEN));
controlCStopingCriterion = new CControlCStopingCriterion();
timeCriterion = new CTimeCriterion(setVariable("timeLimit",\TIME_LIMIT));
......
......@@ -546,9 +546,6 @@ void ParametersImpl::setDefaultParameters(int argc, char** argv){
if(parentReductionSize<parentPopulationSize) parentReduction = true;
else parentReduction = false;
cout << "Parent red " << parentReduction << " " << parentReductionSize << "/"<< parentPopulationSize << endl;
cout << "Parent red " << offspringReduction << " " << offspringReductionSize << "/" << offspringPopulationSize << endl;
generationalCriterion = new CGenerationalCriterion(setVariable("nbGen",(int)\NB_GEN));
controlCStopingCriterion = new CControlCStopingCriterion();
timeCriterion = new CTimeCriterion(setVariable("timeLimit",\TIME_LIMIT));
......
......@@ -291,9 +291,6 @@ void ParametersImpl::setDefaultParameters(int argc, char** argv){
if(parentReductionSize<parentPopulationSize) parentReduction = true;
else parentReduction = false;
cout << "Parent red " << parentReduction << " " << parentReductionSize << "/"<< parentPopulationSize << endl;
cout << "Parent red " << offspringReduction << " " << offspringReductionSize << "/" << offspringPopulationSize << endl;
generationalCriterion = new CGenerationalCriterion(setVariable("nbGen",(int)\NB_GEN));
controlCStopingCriterion = new CControlCStopingCriterion();
timeCriterion = new CTimeCriterion(setVariable("timeLimit",\TIME_LIMIT));
......
......@@ -314,9 +314,6 @@ void ParametersImpl::setDefaultParameters(int argc, char** argv){
if(parentReductionSize<parentPopulationSize) parentReduction = true;
else parentReduction = false;
cout << "Parent red " << parentReduction << " " << parentReductionSize << "/"<< parentPopulationSize << endl;
cout << "Parent red " << offspringReduction << " " << offspringReductionSize << "/" << offspringPopulationSize << endl;
generationalCriterion = new CGenerationalCriterion(setVariable("nbGen",(int)\NB_GEN));
controlCStopingCriterion = new CControlCStopingCriterion();
timeCriterion = new CTimeCriterion(setVariable("timeLimit",\TIME_LIMIT));
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment