@NotThreadSafe public class ProposalStats extends Object
trackX
methods to indicate that a proposal had some action (generation, acceptance, rejection)
Use the #proposalsX
to find out how many proposals were (generated, accepted, rejected) during the tracked
optimization run.Constructor and Description |
---|
ProposalStats() |
ProposalStats(int numProposalsGenerated,
int numProposalsRejected,
int numProposalsAccepted,
int numMovesAccepted,
int numSwapsAccepted,
int numPartitionMovesAccepted,
Map<String,Integer> rejectingGoalCount) |
Modifier and Type | Method and Description |
---|---|
int |
movesAccepted() |
int |
partitionMovesAccepted() |
int |
proposalsAccepted() |
double |
proposalsAcceptedPercent() |
int |
proposalsGenerated() |
int |
proposalsRejected() |
double |
proposalsRejectedPercent() |
Map<String,Integer> |
rejectingGoalCount()
For a given goal, it stores information about what other goals did reject its proposals
and how many times exactly.
|
int |
swapsAccepted() |
String |
toString() |
void |
trackProposalAccepted(ActionType actionType)
Track that a proposal has been accepted.
|
void |
trackProposalGenerated()
Track that a proposal has been generated.
|
void |
trackProposalRejected(Optional<String> rejectingGoal)
Track that a proposal has been rejected, and Optionally indicate what goal rejected it.
|
public void trackProposalGenerated()
public void trackProposalRejected(Optional<String> rejectingGoal)
rejectingGoal
- an Optional for the goal that generated the rejection.public void trackProposalAccepted(ActionType actionType)
public int proposalsGenerated()
public int proposalsRejected()
public double proposalsRejectedPercent()
public int proposalsAccepted()
public double proposalsAcceptedPercent()
public int movesAccepted()
public int swapsAccepted()
public int partitionMovesAccepted()
public Map<String,Integer> rejectingGoalCount()