sandeshrajx commited on
Commit
3ba09e8
·
verified ·
1 Parent(s): 8924488

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +18 -3
app.py CHANGED
@@ -37,8 +37,8 @@ def run_inference(model_name, prompt_text):
37
  # Map model names to their respective configuration files
38
  config_mapping = {
39
  "OpenSora-v1-16x256x256.pth": "configs/opensora/inference/16x256x256.py",
40
- "OpenSora-v1-HQ-16x256x256.pth": "configs/opensora/inference/16x512x512.py",
41
- "OpenSora-v1-HQ-16x512x512.pth": "configs/opensora/inference/64x512x512.py"
42
  }
43
 
44
  config_path = config_mapping[model_name]
@@ -88,11 +88,26 @@ def main():
88
  ],
89
  value="OpenSora-v1-16x256x256.pth",
90
  label="Model Selection"),
91
- gr.Textbox(label="Prompt Text", value="Enter prompt text here")
92
  ],
93
  outputs=gr.Video(label="Output Video"),
94
  title="Open-Sora Inference",
95
  description="Run Open-Sora Inference with Custom Parameters",
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
96
  ).launch()
97
 
98
  if __name__ == "__main__":
 
37
  # Map model names to their respective configuration files
38
  config_mapping = {
39
  "OpenSora-v1-16x256x256.pth": "configs/opensora/inference/16x256x256.py",
40
+ "OpenSora-v1-HQ-16x256x256.pth": "configs/opensora/inference/16x256x256.py",
41
+ "OpenSora-v1-HQ-16x512x512.pth": "configs/opensora/inference/16x512x512.py"
42
  }
43
 
44
  config_path = config_mapping[model_name]
 
88
  ],
89
  value="OpenSora-v1-16x256x256.pth",
90
  label="Model Selection"),
91
+ gr.Textbox(label="Prompt Text", value="iron man riding a skateboard in new york city")
92
  ],
93
  outputs=gr.Video(label="Output Video"),
94
  title="Open-Sora Inference",
95
  description="Run Open-Sora Inference with Custom Parameters",
96
+ # examples=[
97
+ # ["OpenSora-v1-HQ-16x256x256.pth", "iron man riding a skateboard in new york city"],
98
+ # ["OpenSora-v1-16x256x256.pth", "a man is skiing down a snowy mountain. a drone shot from above. an avalanche is chasing him from behind."],
99
+ # ["OpenSora-v1-16x256x256.pth", "Extreme close up of a 24 year old woman’s eye blinking, standing in Marrakech during magic hour, cinematic film shot in 70mm, depth of field, vivid colors, cinematic"],
100
+ # ],
101
+ article = """
102
+ # Examples
103
+
104
+ | Model | Description | Video Player Embedding |
105
+ |------------------------------|----------------------------------------------------------------------------------------------------------------------|---------------------------------------------------------|
106
+ | OpenSora-v1-HQ-16x256x256.pth | Iron Man riding a skateboard in New York City | ![ironman](https://github.com/sandeshrajbhandari/open-sora-examples/assets/12326258/8173e37f-6405-44f3-aaaa-fafc88187933) |
107
+ | OpenSora-v1-16x256x256.pth | A man is skiing down a snowy mountain. A drone shot from above. An avalanche is chasing him from behind. | ![skiing](https://github.com/sandeshrajbhandari/open-sora-examples/assets/12326258/d2cab73a-a77e-4e0b-a80e-668e252b6b6a) |
108
+ | OpenSora-v1-16x256x256.pth | Extreme close-up of a 24-year-old woman’s eye blinking, standing in Marrakech during magic hour, cinematic film shot in 70mm, depth of field, vivid colors, cinematic | ![woman](https://github.com/sandeshrajbhandari/open-sora-examples/assets/12326258/38322939-f7bf-4f72-8a5e-ccc427970afc) |
109
+
110
+ """
111
  ).launch()
112
 
113
  if __name__ == "__main__":