Spaces:
Sleeping
Sleeping
write up small description of the task
Browse files
app.py
CHANGED
@@ -23,18 +23,6 @@ EXAMPLE_IMAGES = [
|
|
23 |
"./examples/f416de7491a31951f79b3cee75b002f4d1bf0162.jpg",
|
24 |
]
|
25 |
|
26 |
-
TRUE_LABELS = {
|
27 |
-
"./examples/0b820b71670c039dd0a51333d1c919f471a9e940.jpg": 1,
|
28 |
-
"./examples/7f6ccae485af121e0b6ee733022e226ee6b0c65f.jpg": 1,
|
29 |
-
"./examples/8eaaa7a400aa79d36c2440a4aa101cc14256cda4.jpg": 0,
|
30 |
-
"./examples/94fa32b29cc1c00403176c0795fffa3cfaa0f20e.jpg": 1,
|
31 |
-
"./examples/730431efa2f79927156dcc4382819e9a6cc2c5bb.jpg": 0,
|
32 |
-
"./examples/a1c001f6b242c72d3066f15ac6eb059ea72d30ba.jpg": 0,
|
33 |
-
"./examples/a106469bbfda4cdc5a9da7ac0152927bf1b4a92d.jpg": 0,
|
34 |
-
"./examples/c3d660212bf2a11c994e0eadff13770a9927b731.jpg": 1,
|
35 |
-
"./examples/f416de7491a31951f79b3cee75b002f4d1bf0162.jpg": 0,
|
36 |
-
}
|
37 |
-
|
38 |
|
39 |
def display_image(image):
|
40 |
return image
|
@@ -137,6 +125,23 @@ if __name__ == "__main__":
|
|
137 |
</p>
|
138 |
"""
|
139 |
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
140 |
with gr.Row():
|
141 |
gr.Markdown("## Setup Phase: 🔐 Generate the FHE public and secret keys.")
|
142 |
with gr.Row():
|
|
|
23 |
"./examples/f416de7491a31951f79b3cee75b002f4d1bf0162.jpg",
|
24 |
]
|
25 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
26 |
|
27 |
def display_image(image):
|
28 |
return image
|
|
|
125 |
</p>
|
126 |
"""
|
127 |
)
|
128 |
+
gr.Markdown("""
|
129 |
+
## 🔒 Privacy-Preserving Cancer Detection with Fully Homomorphic Encryption (FHE)
|
130 |
+
|
131 |
+
This demo lets you upload a microscopic tissue image and get a “Cancerous” or “Not Cancerous” verdict—**without ever revealing your raw data**.
|
132 |
+
Under the hood, we run the deep learning classifier from your image, **encrypt** it with fully homomorphic encryption (FHE), and run the classification entirely on ciphertext.
|
133 |
+
That means all computation happens on encrypted values: the server never sees your clear-text image or features, yet still returns an accurate diagnosis in milliseconds.
|
134 |
+
|
135 |
+
### Steps
|
136 |
+
|
137 |
+
1. **Generate** your public/private keys
|
138 |
+
2. **Upload or select** a reference cell image
|
139 |
+
3. **Generate & encrypt** its embedding
|
140 |
+
4. **Set a decision threshold** and click “Check”
|
141 |
+
5. **See the verdict** (“Cancerous” vs. “Not Cancerous”)
|
142 |
+
|
143 |
+
Experience cutting-edge FHE in action: robust cancer screening with patient privacy built in.
|
144 |
+
""")
|
145 |
with gr.Row():
|
146 |
gr.Markdown("## Setup Phase: 🔐 Generate the FHE public and secret keys.")
|
147 |
with gr.Row():
|