Skip to content
This repository has been archived by the owner on Nov 6, 2023. It is now read-only.

Commit

Permalink
change name on module
Browse files Browse the repository at this point in the history
  • Loading branch information
Aminmalek committed Nov 1, 2023
1 parent deabddd commit 7077f8c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lib/src/main/java/fsst/SymbolMap.java
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ void clear() {
int load() {
int ret = 0;
for (int i = 0; i < hashTabSize; i++)
ret += Utils.boolToInt(hashTab[i].gcl < FSST_GCL_FREE);
ret += Utils.booleanToInt(hashTab[i].gcl < FSST_GCL_FREE);
return ret;
}

Expand Down
4 changes: 2 additions & 2 deletions lib/src/main/java/fsst/SymbolTable.java
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ int compressCount(SymbolTable symbolTable, Counters counters, Integer[] line, in
int start = cur;
int code2 = 255, code1 = symbolTable.findLongestSymbol((byte) cur, (byte) end);
cur += symbolTable.symbols[code1].length();
gain += (int) (symbolTable.symbols[code1].length() - (1 + Utils.boolToInt(isEscapeCode(code1))));
gain += (int) (symbolTable.symbols[code1].length() - (1 + Utils.booleanToInt(isEscapeCode(code1))));
while (true) {
// count single symbol (i.e. an option is not extending it)
// TODO: Double check which boolean flag we need for our specific implementation
Expand Down Expand Up @@ -293,7 +293,7 @@ int compressCount(SymbolTable symbolTable, Counters counters, Integer[] line, in
}

// compute compressed output size
gain += ((int) (cur - start)) - (1 + Utils.boolToInt(isEscapeCode(code2)));
gain += ((int) (cur - start)) - (1 + Utils.booleanToInt(isEscapeCode(code2)));

// now count the subsequent two symbols we encode as an extension codesibility
if (sampleFrac < 128) { // no need to count pairs in final round
Expand Down

0 comments on commit 7077f8c

Please sign in to comment.