package com.zy.asrs.domain.path;
|
|
import lombok.Data;
|
|
import java.io.Serializable;
|
|
@Data
|
public class StationPathProfileConfig implements Serializable {
|
private static final long serialVersionUID = 1L;
|
|
private Integer calcMaxDepth = 120;
|
private Integer calcMaxPaths = 500;
|
private Integer calcMaxCost = 300;
|
|
private Integer s1TopK = 5;
|
private Double s1LenWeight = 1.0d;
|
private Double s1TurnWeight = 3.0d;
|
private Double s1LiftWeight = 8.0d;
|
private Double s1SoftDeviationWeight = 4.0d;
|
private Double s1MaxLenRatio = 1.15d;
|
private Integer s1MaxTurnDiff = 1;
|
|
private Double s2BusyWeight = 2.0d;
|
private Double s2RunBlockWeight = 10.0d;
|
private Double s2LoopLoadWeight = 12.0d;
|
|
public static StationPathProfileConfig defaultConfig() {
|
return new StationPathProfileConfig();
|
}
|
|
public void mergeFrom(StationPathProfileConfig source) {
|
if (source == null) {
|
return;
|
}
|
if (source.calcMaxDepth != null) this.calcMaxDepth = source.calcMaxDepth;
|
if (source.calcMaxPaths != null) this.calcMaxPaths = source.calcMaxPaths;
|
if (source.calcMaxCost != null) this.calcMaxCost = source.calcMaxCost;
|
if (source.s1TopK != null) this.s1TopK = source.s1TopK;
|
if (source.s1LenWeight != null) this.s1LenWeight = source.s1LenWeight;
|
if (source.s1TurnWeight != null) this.s1TurnWeight = source.s1TurnWeight;
|
if (source.s1LiftWeight != null) this.s1LiftWeight = source.s1LiftWeight;
|
if (source.s1SoftDeviationWeight != null) this.s1SoftDeviationWeight = source.s1SoftDeviationWeight;
|
if (source.s1MaxLenRatio != null) this.s1MaxLenRatio = source.s1MaxLenRatio;
|
if (source.s1MaxTurnDiff != null) this.s1MaxTurnDiff = source.s1MaxTurnDiff;
|
if (source.s2BusyWeight != null) this.s2BusyWeight = source.s2BusyWeight;
|
if (source.s2RunBlockWeight != null) this.s2RunBlockWeight = source.s2RunBlockWeight;
|
if (source.s2LoopLoadWeight != null) this.s2LoopLoadWeight = source.s2LoopLoadWeight;
|
}
|
}
|