jiang-cc commited on
Commit
b0bcd32
·
verified ·
1 Parent(s): 17e9caa

fix: replace PCB with pcb3 (clearer defect), Run Long to 60s

Browse files
Files changed (3) hide show
  1. app.py +2 -2
  2. examples/pcb_defect.jpg +0 -0
  3. examples/pcb_good.jpg +0 -0
app.py CHANGED
@@ -212,7 +212,7 @@ def _predict_gpu(reference_image, test_image, prompt, max_new_tokens, _t_enter=N
212
  return _run_inference(reference_image, test_image, prompt, max_new_tokens, _t_enter=_t_enter)
213
 
214
 
215
- @spaces.GPU(duration=30)
216
  def _predict_long_gpu(reference_image, test_image, prompt, max_new_tokens, _t_enter=None):
217
  return _run_inference(reference_image, test_image, prompt, max_new_tokens, _t_enter=_t_enter)
218
 
@@ -314,7 +314,7 @@ with gr.Blocks(theme=gr.themes.Soft(), title=TITLE) as demo:
314
  label="Max New Tokens",
315
  )
316
  run_btn = gr.Button("Run (15s)", variant="primary", scale=2)
317
- run_long_btn = gr.Button("Run Long (30s)", variant="secondary", scale=1)
318
 
319
  output = gr.Textbox(label="Model Output", lines=4)
320
  vis_output = gr.Image(label="Detection Visualization")
 
212
  return _run_inference(reference_image, test_image, prompt, max_new_tokens, _t_enter=_t_enter)
213
 
214
 
215
+ @spaces.GPU(duration=60)
216
  def _predict_long_gpu(reference_image, test_image, prompt, max_new_tokens, _t_enter=None):
217
  return _run_inference(reference_image, test_image, prompt, max_new_tokens, _t_enter=_t_enter)
218
 
 
314
  label="Max New Tokens",
315
  )
316
  run_btn = gr.Button("Run (15s)", variant="primary", scale=2)
317
+ run_long_btn = gr.Button("Run Long (60s)", variant="secondary", scale=1)
318
 
319
  output = gr.Textbox(label="Model Output", lines=4)
320
  vis_output = gr.Image(label="Detection Visualization")
examples/pcb_defect.jpg CHANGED
examples/pcb_good.jpg CHANGED