Skip to content

Commit

Permalink
updated return for visual prompt counting
Browse files Browse the repository at this point in the history
  • Loading branch information
dillonalaird committed Apr 25, 2024
1 parent 8e3c525 commit 577fe66
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion vision_agent/tools/tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -588,7 +588,9 @@ def __call__(self, image: Union[str, ImageType], prompt: str) -> Dict:
"prompt": prompt,
"tool": "few_shot_counting",
}
return _send_inference_request(data, "tools")
resp_data = _send_inference_request(data, "tools")
resp_data["heat_map"] = np.array(b64_to_pil(resp_data["heat_map"][0]))
return resp_data


class VisualQuestionAnswering(Tool):
Expand Down

0 comments on commit 577fe66

Please sign in to comment.