MCPcopy Create free account
hub / github.com/aigc3d/LHM / get_img

Method get_img

engine/SegmentAPI/SAM.py:393–401  ·  view source on GitHub ↗
(self, img_path, sup_res=True)

Source from the content-addressed store, hash-verified

391 return cur_ratio
392
393 def get_img(self, img_path, sup_res=True):
394
395 img = cv2.imread(img_path)
396 img = img[..., ::-1].copy() # bgr2rgb
397
398 if self.wo_supers:
399 return img
400
401 return img
402
403 def compute_coords(self, pha, bbox):
404

Callers 1

_forwardMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected