fffiloni commited on
Commit
80d5220
·
verified ·
1 Parent(s): bd97426

Update gradio_app.py

Browse files
Files changed (1) hide show
  1. gradio_app.py +3 -2
gradio_app.py CHANGED
@@ -5,7 +5,8 @@ from gradio_client import Client, handle_file
5
 
6
 
7
  def infer(text_prompt, action_prompt, profile: gr.OAuthProfile, oauth_token: gr.OAuthToken):
8
-
 
9
  print(f"OAuth token: {oauth_token.token}")
10
  client_secret = os.getenv('OAUTH_CLIENT_SECRET')
11
  print(f"OAuth client secret env: {client_secret}")
@@ -33,7 +34,7 @@ def infer(text_prompt, action_prompt, profile: gr.OAuthProfile, oauth_token: gr.
33
  print(f"✅ Image saved temporarily at: {temp_image_path}")
34
 
35
 
36
- gr_client = Client("Lightricks/ltx-video-distilled", hf_token=oauth_token.token)
37
  result = gr_client.predict(
38
  prompt=action_prompt,
39
  negative_prompt="worst quality, inconsistent motion, blurry, jittery, distorted",
 
5
 
6
 
7
  def infer(text_prompt, action_prompt, profile: gr.OAuthProfile, oauth_token: gr.OAuthToken):
8
+
9
+ gradio_auth_token = oauth_token.token
10
  print(f"OAuth token: {oauth_token.token}")
11
  client_secret = os.getenv('OAUTH_CLIENT_SECRET')
12
  print(f"OAuth client secret env: {client_secret}")
 
34
  print(f"✅ Image saved temporarily at: {temp_image_path}")
35
 
36
 
37
+ gr_client = Client("Lightricks/ltx-video-distilled", hf_token=gradio_auth_token)
38
  result = gr_client.predict(
39
  prompt=action_prompt,
40
  negative_prompt="worst quality, inconsistent motion, blurry, jittery, distorted",