sshenai commited on
Commit
a045f14
·
verified ·
1 Parent(s): 0ff16be

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -16,7 +16,7 @@ def image_to_caption(image_path):
16
  # Generates a story for the caption using a pre-trained model
17
  def caption_to_story(text):
18
  captiontostory = pipeline("text-generation", model="pranavpsv/genre-story-generator-v2")
19
- story = captiontostory(text,max_length=150,min_length=50)[0]['generated_text']
20
  return story
21
 
22
  # Generates an audio for the story
 
16
  # Generates a story for the caption using a pre-trained model
17
  def caption_to_story(text):
18
  captiontostory = pipeline("text-generation", model="pranavpsv/genre-story-generator-v2")
19
+ story = captiontostory(text, max_length=150, min_length=50)[0]['generated_text']
20
  return story
21
 
22
  # Generates an audio for the story