def _obj_idx_to_id(inference_state, obj_idx):
    """Map model-side object index to client-side object id."""
    return inference_state["obj_idx_to_id"][obj_idx]
Map model-side object index to client-side object id.
projects/llava_sam2/hf/models/sam2.py