From 9a35051a710efca0a8d48cd8af6e45c3913998c5 Mon Sep 17 00:00:00 2001 From: Zevaryx Date: Sat, 26 Jun 2021 20:38:29 -0600 Subject: [PATCH] Properly calculate ratio --- jarvis/cogs/image.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jarvis/cogs/image.py b/jarvis/cogs/image.py index b164e78..7328921 100644 --- a/jarvis/cogs/image.py +++ b/jarvis/cogs/image.py @@ -56,7 +56,7 @@ class ImageCog(commands.Cog): await ctx.send("Image already meets target.") return - ratio = size / tgt_size + ratio = tgt_size / size buffer = np.frombuffer(file, dtype=np.uint8) img = cv2.imdecode(buffer, flags=-1)