diff options
author | Andrew Harvey <andrew@alantgeo.com.au> | 2021-05-19 23:21:31 +1000 |
---|---|---|
committer | Andrew Harvey <andrew@alantgeo.com.au> | 2021-05-19 23:21:31 +1000 |
commit | 66ec9f9177a685129e917ff6bb8d503779c668f9 (patch) | |
tree | 1cf15607a3501cd8b2d07ca2beb679e3cabaa4be /bin/reduceDuplicates.js | |
parent | a7151f6a4c935971250684a94d4ee47dc5fda8af (diff) |
log progress as actual number
Diffstat (limited to 'bin/reduceDuplicates.js')
-rwxr-xr-x | bin/reduceDuplicates.js | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/bin/reduceDuplicates.js b/bin/reduceDuplicates.js index 985a0e1..0880abf 100755 --- a/bin/reduceDuplicates.js +++ b/bin/reduceDuplicates.js @@ -41,7 +41,7 @@ const index = new Transform({ sourceCount++ if (process.stdout.isTTY && sourceCount % 10000 === 0) { - process.stdout.write(` ${sourceCount / 1000}k\r`) + process.stdout.write(` ${sourceCount.toLocaleString()}\r`) } const key = [ @@ -71,7 +71,7 @@ const reduce = new Transform({ transform(key, encoding, callback) { reduceIndex++ if (process.stdout.isTTY && reduceIndex % 10000 === 0) { - process.stdout.write(` ${reduceIndex / 1000}k / ${Math.round(sourceCount / 1000)}k (${Math.round(reduceIndex / sourceCount * 100)}%)\r`) + process.stdout.write(` ${reduceIndex.toLocaleString()} / ${sourceCount.toLocaleString()} (${Math.round(reduceIndex / sourceCount * 100)}%)\r`) } const groupedFeatures = features[key] |