Skip to content

Commit

Permalink
v0.2.6b3
Browse files Browse the repository at this point in the history
  • Loading branch information
wasertech committed Mar 11, 2023
1 parent 217b671 commit 58f6e8e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion translator/__init__.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
from translator.translate import Translator
from translator.language import get_nllb_lang

__version__ = "0.2.6b2"
__version__ = "0.2.6b3"

LANGS = get_nllb_lang()
5 changes: 4 additions & 1 deletion translator/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,8 +165,11 @@ def main():
translations += translate_sentence(_batch_text, translator)
time_meanwhile = time.perf_counter()
_td = time_meanwhile - _t
_td2 = time_meanwhile - time_before_3
_i += batch_size
_avg = batch_size/_td
_avg1 = batch_size/_td
_avg2 = _i/_td2
_avg = (_avg1 + _avg2)/2
_eta = (_ut_ds - _i) / _avg
spinner.text = f"[{_i:n}/{_ut_ds:n} ({_i/_ut_ds:.2%}) | ~{_avg:.2f} sentences / second | ETA : {datetime.timedelta(seconds=_eta)}]"

Expand Down

0 comments on commit 58f6e8e

Please sign in to comment.