Set ratio minimum to 65%
This commit is contained in:
parent
43d409953c
commit
d614e81982
1 changed files with 2 additions and 2 deletions
|
@ -70,7 +70,7 @@ class ImageCog(commands.Cog):
|
|||
accuracy = 0.0
|
||||
# TODO: Optimize to not run multiple times
|
||||
while len(file) > tgt_size or (
|
||||
len(file) <= tgt_size and accuracy < 0.50
|
||||
len(file) <= tgt_size and accuracy < 0.65
|
||||
):
|
||||
old_file = file
|
||||
|
||||
|
@ -87,7 +87,7 @@ class ImageCog(commands.Cog):
|
|||
file = old_file
|
||||
ratio += 0.1
|
||||
else:
|
||||
ratio = max(tgt_size / len(file) - 0.02, 0.50)
|
||||
ratio = max(tgt_size / len(file) - 0.02, 0.65)
|
||||
|
||||
bufio = BytesIO(file)
|
||||
accuracy = (len(file) / tgt_size) * 100
|
||||
|
|
Loading…
Add table
Reference in a new issue