Yaowei222 commited on
Commit
9bc4f8c
·
1 Parent(s): 12edc27

fix vlm return

Browse files
Files changed (1) hide show
  1. app/business_logic.py +1 -1
app/business_logic.py CHANGED
@@ -489,7 +489,7 @@ def vlm_auto_generate(image_target_state, image_reference_state, mask_target_sta
489
 
490
  if VLM_PROCESSOR is None or VLM_MODEL is None:
491
  gr.Warning("Please enable vlm for prompt first")
492
- return prompt
493
 
494
  messages = construct_vlm_gen_prompt(image_target_state, image_reference_state, mask_target_state, custmization_mode)
495
  output_text = run_vlm(VLM_PROCESSOR, VLM_MODEL, messages, device=device)
 
489
 
490
  if VLM_PROCESSOR is None or VLM_MODEL is None:
491
  gr.Warning("Please enable vlm for prompt first")
492
+ return None
493
 
494
  messages = construct_vlm_gen_prompt(image_target_state, image_reference_state, mask_target_state, custmization_mode)
495
  output_text = run_vlm(VLM_PROCESSOR, VLM_MODEL, messages, device=device)