Skip to content

Conversation

@YvesSchoenberg
Copy link
Contributor

No description provided.

@YvesSchoenberg
Copy link
Contributor Author

@GabeMedrash, @BBarash, what would you think if we add better SDK support for images? For example:

img = msg.get_img(fmt="cv2", colorspace="BGR")

so users don't need to do any of this:

def convert_image_msg_to_cv2(msg):
    return cv2.imdecode(np.frombuffer(msg["data"], np.uint8), cv2.IMREAD_COLOR)

Questions:
1.) Would this bloat up our SDK because we need to add opencv etc dependencies? Could we put it into the analytics package?
2.) What happens if someone calls msg.get_img() on a message that's not an image - is it acceptable to just throw an error?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants