Skip to content

Commit

Permalink
w
Browse files Browse the repository at this point in the history
  • Loading branch information
test123456654321 committed Oct 26, 2024
1 parent 469b057 commit bf5e006
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/LunaTranslator/myutils/languageguesser.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,11 @@ def guess(string: str):
(0x3100, 0x312F),
(0x31A0, 0x31BF),
(0x3000, 0x303F),
): 10,
): 20,
lambda c: inranges(
ord(c),
(0x4E00, 0x9FA5),
): 3,
): 4,
},
"zh": {
lambda c: inranges(
Expand Down Expand Up @@ -85,7 +85,6 @@ def guess(string: str):
for lang, ck in checkers.items():
if isinstance(ck, dict):
for f, w in ck.items():
print(lang, f, c, f(c))
if f(c):
cnt[lang] += w
else:
Expand Down

0 comments on commit bf5e006

Please sign in to comment.