MCPcopy
hub / github.com/chenfei-wu/TaskMatrix / set_image

Method set_image

visual_chatgpt.py:896–899  ·  view source on GitHub ↗

Set the image for the predictor.

(self, img)

Source from the content-addressed store, hash-verified

894 return updated_image_path
895
896 def set_image(self, img) -> None:
897 """Set the image for the predictor."""
898 with torch.cuda.amp.autocast():
899 self.sam_predictor.set_image(img)
900
901 def show_points(self, coords: np.ndarray, labels: np.ndarray,
902 image: np.ndarray) -> np.ndarray:

Callers 5

get_maskMethod · 0.80
inference_replace_samMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected