@Override
	public void saveBase64(StringBuilder buffer, char[] encoder) {
		if (hash.length == 0)
			return;
		char[] charBuf = new char[70];
		int i = 0;
		int charpos = 0;
		for (;;) {
			hash[i].saveBase64(charBuf, charpos, encoder);
			i += 1;
			charpos += 7;
			if (i >= hash.length)
				break;
			if (charpos == 70) {
				buffer.append(charBuf);
				charpos = 0;
			}
		}
		if (charpos != 0)
			buffer.append(charBuf, 0, charpos);
	}
Assuming -feature- is sorted and -hash- is empty, count the features and populate -hash- and -tf-
For every unique feature, look up its idf via -idflookup-
@param feature is the list of sorted hash features
@param wfactory is the WeightFactory used to decide feature weights
@param idflookup is the IDFLookup used to decide relative frequency of individual features
Ghidra/Framework/Generic/src/main/java/generic/lsh/vector/LSHCosineVector.java