public override bool Equals(object o)
 {
     if (o == this)
     {
         return(true);
     }
     if (o is ProbabilitySampler)
     {
         ProbabilitySampler that = (ProbabilitySampler)o;
         return(DoubleUtil.ToInt64(Probability) == DoubleUtil.ToInt64(that.Probability) &&
                (this.IdUpperBound == that.IdUpperBound));
     }
     return(false);
 }
예제 #2
0
 public static ISampler GetProbabilitySampler(double probability)
 {
     return(ProbabilitySampler.Create(probability));
 }