tommy24 commited on
Commit
ff7f76f
·
1 Parent(s): fce06c9

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +8 -8
app.py CHANGED
@@ -528,14 +528,14 @@ def classify(platform, UserInput, Images, Textbox2, Textbox3):
528
  image_base64 = base64.b64encode(get_image.content).decode("utf-8")
529
  image_data_url = f"data:image/png;base64,{image_base64}"
530
 
531
- random_id = random.randint(1000, 9999)
532
- filename = f"image_{random_id}"
533
- with open(filename, "wb") as file:
534
- file.write(get_image.content)
535
- print(f"Saved image as: {filename}")
536
-
537
- full_path = os.path.join(os.getcwd(), filename)
538
- print(f"Saved image as: {full_path}")
539
 
540
  elif platform == "web":
541
  print("WEB")
 
528
  image_base64 = base64.b64encode(get_image.content).decode("utf-8")
529
  image_data_url = f"data:image/png;base64,{image_base64}"
530
 
531
+ # random_id = random.randint(1000, 9999)
532
+ # filename = f"image_{random_id}"
533
+ # with open(filename, "wb") as file:
534
+ # file.write(get_image.content)
535
+ # print(f"Saved image as: {filename}")
536
+
537
+ # full_path = os.path.join(os.getcwd(), filename)
538
+ # print(f"Saved image as: {full_path}")
539
 
540
  elif platform == "web":
541
  print("WEB")