Spaces:
Runtime error

dnasafe commited on
Commit
65267b4
·
verified ·
1 Parent(s): 65df51c

add show_image

Browse files
Files changed (1) hide show
  1. app.py +9 -9
app.py CHANGED
@@ -8,13 +8,11 @@ public_key, private_key = paillier.generate_paillier_keypair(n_length=1024)
8
 
9
 
10
  def show_image():
11
-
12
- # Convert To PIL Image
13
-
14
  html = (
15
- "<div >"
16
- "<img src='https://dnasafe.io/redesign/animation.gif' alt='image One'>"
17
- + "</div>"
18
  )
19
  return html
20
 
@@ -82,9 +80,11 @@ iface = gr.Interface(
82
  ],
83
  title="Paillier Encryption Demonstration",
84
  description="This app demonstrates Paillier encryption. Enter data (e.g., smoker, non-smoker) in the textbox, and the app will perform encryption and homomorphic addition.",
85
- show_image()
86
 
87
  )
88
-
89
  # Launch the Gradio app
90
- iface.launch()
 
 
 
8
 
9
 
10
  def show_image():
11
+ # Convert To PIL Image (you can implement your desired image display logic here)
 
 
12
  html = (
13
+ "<div>"
14
+ "<img src='https://dnasafe.io/redesign/animation.gif' alt='image One'>"
15
+ + "</div>"
16
  )
17
  return html
18
 
 
80
  ],
81
  title="Paillier Encryption Demonstration",
82
  description="This app demonstrates Paillier encryption. Enter data (e.g., smoker, non-smoker) in the textbox, and the app will perform encryption and homomorphic addition.",
83
+
84
 
85
  )
86
+ # Add show_image to the layout (optional)
87
  # Launch the Gradio app
88
+ layout = Column([show_image(), iface])
89
+ iface.launch(layout=layout) # Use layout argument
90
+