diff options
Diffstat (limited to 'gi/posterior-regularisation/prjava/src/optimization/projections')
-rw-r--r-- | gi/posterior-regularisation/prjava/src/optimization/projections/SimplexProjection.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gi/posterior-regularisation/prjava/src/optimization/projections/SimplexProjection.java b/gi/posterior-regularisation/prjava/src/optimization/projections/SimplexProjection.java index eec11bcf..f22afcaf 100644 --- a/gi/posterior-regularisation/prjava/src/optimization/projections/SimplexProjection.java +++ b/gi/posterior-regularisation/prjava/src/optimization/projections/SimplexProjection.java @@ -40,7 +40,7 @@ public class SimplexProjection extends Projection{ for (int i = 0; i < ds.length; i++) { currentSum+=ds[i]; theta = (currentSum-scale)/(i+1); - if(ds[i]-theta <= 0){ + if(ds[i]-theta < -1e-10){ break; } previousTheta = theta; |