-
Notifications
You must be signed in to change notification settings - Fork 1
/
Join_Cp.java
35 lines (27 loc) · 1.09 KB
/
Join_Cp.java
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
import org.apache.logging.log4j.LogManager;
import org.apache.logging.log4j.Logger;
import ec.*;
import ec.gp.*;
public class Join_Cp extends GPNode {
/**
*
*/
private static final long serialVersionUID = -2469474980216912290L;
private static Logger logNormal = LogManager.getLogger("logNormal");
public Singleton sin = Singleton.getInstance();
String logantes = "";
public String toString() { return "Join_Cp"; }
public int expectedChildren() { return 0; }
public void eval(final EvolutionState state, final int thread, final GPData input, final ADFStack stack, final GPIndividual individual, final Problem problem) {
long startTime = System.currentTimeMillis();
if(sin.selogea) logantes = ((MyProblem)problem).instancia.logantes();
MyGPData d = ((MyGPData)(input));
((MyProblem)problem).instancia.Join_Cp();
if(sin.selogea) logNormal.debug(logantes + ((MyProblem)problem).instancia.logdespues());
d.punto = null;
d.condicion = true;
long stopTime = System.currentTimeMillis();
sin.Join_CpElapsedTime += stopTime - startTime;
sin.Join_CpCounter++;
}
}