diff --git a/demo/inference_on_a_image.py b/demo/inference_on_a_image.py index 63f09bd1..aa0d3952 100644 --- a/demo/inference_on_a_image.py +++ b/demo/inference_on_a_image.py @@ -117,7 +117,7 @@ def get_grounding_output(model, image, caption, box_threshold, text_threshold=No else: # given-phrase mode positive_maps = create_positive_map_from_span( - model.tokenizer(text_prompt), + model.tokenizer(caption), token_span=token_spans ).to(image.device) # n_phrase, 256