Spaces:
Running
on
Zero
Running
on
Zero
Commit
·
db6f03b
1
Parent(s):
dad6083
Provide default value for the radio of examples.
Browse files- app.py +1 -3
- app_local.py +2 -4
- requirements.txt +1 -10
app.py
CHANGED
@@ -259,9 +259,7 @@ for idx_example, example in enumerate(examples):
|
|
259 |
example_resolution = '2048x2048'
|
260 |
else:
|
261 |
example_resolution = '1024x1024'
|
262 |
-
examples[idx_example]
|
263 |
-
examples.append(examples[-1].copy())
|
264 |
-
examples[-1][1] = '512x512'
|
265 |
|
266 |
examples_url = [
|
267 |
['https://hips.hearstapps.com/hmg-prod/images/gettyimages-1229892983-square.jpg'],
|
|
|
259 |
example_resolution = '2048x2048'
|
260 |
else:
|
261 |
example_resolution = '1024x1024'
|
262 |
+
examples[idx_example] = examples[idx_example] + [example_resolution, 'General']
|
|
|
|
|
263 |
|
264 |
examples_url = [
|
265 |
['https://hips.hearstapps.com/hmg-prod/images/gettyimages-1229892983-square.jpg'],
|
app_local.py
CHANGED
@@ -255,9 +255,7 @@ for idx_example, example in enumerate(examples):
|
|
255 |
example_resolution = '2048x2048'
|
256 |
else:
|
257 |
example_resolution = '1024x1024'
|
258 |
-
examples[idx_example]
|
259 |
-
examples.append(examples[-1].copy())
|
260 |
-
examples[-1][1] = '512x512'
|
261 |
|
262 |
examples_url = [
|
263 |
['https://hips.hearstapps.com/hmg-prod/images/gettyimages-1229892983-square.jpg'],
|
@@ -315,4 +313,4 @@ demo = gr.TabbedInterface(
|
|
315 |
)
|
316 |
|
317 |
if __name__ == "__main__":
|
318 |
-
demo.launch(debug=True)
|
|
|
255 |
example_resolution = '2048x2048'
|
256 |
else:
|
257 |
example_resolution = '1024x1024'
|
258 |
+
examples[idx_example] = examples[idx_example] + [example_resolution, 'General']
|
|
|
|
|
259 |
|
260 |
examples_url = [
|
261 |
['https://hips.hearstapps.com/hmg-prod/images/gettyimages-1229892983-square.jpg'],
|
|
|
313 |
)
|
314 |
|
315 |
if __name__ == "__main__":
|
316 |
+
demo.launch(debug=True, shared=True)
|
requirements.txt
CHANGED
@@ -1,13 +1,4 @@
|
|
1 |
-
|
2 |
-
torchvision
|
3 |
-
numpy<2
|
4 |
-
opencv-python
|
5 |
-
tqdm
|
6 |
-
timm
|
7 |
-
prettytable
|
8 |
-
scipy
|
9 |
-
scikit-image
|
10 |
-
kornia
|
11 |
gradio_imageslider>=0.0.18
|
12 |
transformers==4.42.4
|
13 |
huggingface_hub==0.28.1
|
|
|
1 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
2 |
gradio_imageslider>=0.0.18
|
3 |
transformers==4.42.4
|
4 |
huggingface_hub==0.28.1
|