yingzhac commited on
Commit
c1d4b6a
·
1 Parent(s): e7cea37

Fix: 修改示例部分,解决参数不匹配问题

Browse files
Files changed (1) hide show
  1. app.py +5 -6
app.py CHANGED
@@ -104,9 +104,9 @@ def infer(
104
 
105
 
106
  examples = [
107
- ["A fantasy landscape with mountains and a lake", "examples/landscape.jpg"],
108
- ["A cyberpunk city street scene", "examples/city.jpg"],
109
- ["A cartoon character in winter clothing", "examples/character.jpg"],
110
  ]
111
 
112
  css = """
@@ -197,9 +197,8 @@ with gr.Blocks(css=css) as demo:
197
 
198
  gr.Examples(
199
  examples=examples,
200
- inputs=[prompt, input_image],
201
- outputs=[result, seed, canny_image],
202
- fn=infer,
203
  cache_examples=True,
204
  )
205
 
 
104
 
105
 
106
  examples = [
107
+ ["A fantasy landscape with mountains and a lake", None],
108
+ ["A cyberpunk city street scene", None],
109
+ ["A cartoon character in winter clothing", None],
110
  ]
111
 
112
  css = """
 
197
 
198
  gr.Examples(
199
  examples=examples,
200
+ inputs=[prompt],
201
+ fn=None,
 
202
  cache_examples=True,
203
  )
204