Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
@@ -1,8 +1,13 @@
|
|
1 |
import gradio as gr
|
|
|
2 |
from gradio_client import Client, handle_file
|
|
|
3 |
|
4 |
from gradio_imageslider import ImageSlider
|
5 |
|
|
|
|
|
|
|
6 |
def get_flux_image(prompt):
|
7 |
client = Client("black-forest-labs/FLUX.1-schnell")
|
8 |
result = client.predict(
|
|
|
1 |
import gradio as gr
|
2 |
+
import os
|
3 |
from gradio_client import Client, handle_file
|
4 |
+
from huggingface_hub import login
|
5 |
|
6 |
from gradio_imageslider import ImageSlider
|
7 |
|
8 |
+
hf_tkn = os.environ.get("HF_TKN")
|
9 |
+
login(hf_tkn)
|
10 |
+
|
11 |
def get_flux_image(prompt):
|
12 |
client = Client("black-forest-labs/FLUX.1-schnell")
|
13 |
result = client.predict(
|