@Override
	protected void computeLogMi(DataSequence dataSeq, int i, int ell, double[] lambda) {
		super.computeLogMi(dataSeq, i, ell, lambda);
		if (dataSeq.y(i) >= 0) {
			for (int j = 0; j < Ri.size(); j++) {
				if (j != dataSeq.y(i))
					Ri.set(j, RobustMath.LOG0);
			}
			assert(Ri.get(dataSeq.y(i)) > RobustMath.LOG0);
		}
		if (usedLabels != null && labelConstraints != null && 
				usedLabels.length >= dataSeq.length() && usedLabels[i].size() > 0) {
			for (int y = 0; y < Ri.size(); y++) {
				if (!labelConstraints.valid(usedLabels[i], y, -1)) {
					Ri.set(y, RobustMath.LOG0);
				}
			}
		}
	}