Omnibus commited on
Commit
7b01ac4
·
1 Parent(s): 93adb7c

Update utils.py

Browse files
Files changed (1) hide show
  1. utils.py +1 -1
utils.py CHANGED
@@ -35,7 +35,7 @@ def decode(image_name,txt=None):
35
 
36
  def encode(image_name, secret_data,txt=None):
37
  msg=""
38
- BGRimage = cv2.imread(image_name)
39
  image = cv2.cvtColor(BGRimage, cv2.COLOR_BGR2RGB)
40
  n_bytes = image.shape[0] * image.shape[1] * 3 // 8
41
  print("[*] Maximum bytes to encode:", n_bytes)
 
35
 
36
  def encode(image_name, secret_data,txt=None):
37
  msg=""
38
+ BGRimage = cv2.imread(f"{image_name}")
39
  image = cv2.cvtColor(BGRimage, cv2.COLOR_BGR2RGB)
40
  n_bytes = image.shape[0] * image.shape[1] * 3 // 8
41
  print("[*] Maximum bytes to encode:", n_bytes)