BigRatz commited on
Commit
96563fb
·
1 Parent(s): bbf3f50

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -5,7 +5,7 @@ import numpy as np
5
  from openai import OpenAI
6
 
7
  # Image Preprocessing Function
8
- def preprocess_image(image_path):
9
  # Convert the file to an OpenCV image
10
  file_bytes = np.asarray(bytearray(image_file.read()), dtype=np.uint8)
11
  image = cv2.imdecode(file_bytes, cv2.IMREAD_COLOR)
@@ -24,7 +24,7 @@ def preprocess_image(image_path):
24
  equalized_image = clahe.apply(blurred_image)
25
 
26
  # Return the preprocessed image
27
- return image_path
28
 
29
  # Function to encode the image to base64
30
  def encode_image(image_file):
 
5
  from openai import OpenAI
6
 
7
  # Image Preprocessing Function
8
+ def preprocess_image(image_file):
9
  # Convert the file to an OpenCV image
10
  file_bytes = np.asarray(bytearray(image_file.read()), dtype=np.uint8)
11
  image = cv2.imdecode(file_bytes, cv2.IMREAD_COLOR)
 
24
  equalized_image = clahe.apply(blurred_image)
25
 
26
  # Return the preprocessed image
27
+ return image_file
28
 
29
  # Function to encode the image to base64
30
  def encode_image(image_file):