Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UDP Support? #72

Open
kevinlinxc opened this issue Mar 8, 2022 · 2 comments
Open

UDP Support? #72

kevinlinxc opened this issue Mar 8, 2022 · 2 comments

Comments

@kevinlinxc
Copy link

kevinlinxc commented Mar 8, 2022

Hi, I am using this library and have noticed that it is a bit slow for high frequency image sending, which is to be expected. I'm wondering if it's possible to use UDP instead of TCP? Doing a bit of research, it seems like ZMQ has some support for this with NORM and PGM:

http://wiki.zeromq.org/topics:norm-protocol-transport
https://stackoverflow.com/a/70623213/11741232

When I tried hotswapping TCP in URLs for norm and pgm, I got zmq.error.ZMQError: Protocol not supported so it seems like it's not supported

@jeffbass
Copy link
Owner

jeffbass commented Mar 10, 2022

I have not used UDP, but imageZMQ uses ZMQ multi-part messages (using the ZMQ option zmq.SNDMORE). I believe this ZMQ option is incompatible with UDP. Also, with multi-part messages it is not likely using UDP would actually be faster; image messages are quite large, making the relative savings of UDP versus TCP relatively small. From my reading of the ZMQ docs, PGM may be compatible with ZMQ multi-part messages, but perhaps not with the pyZMQ bindings used by imageZMQ.

I saw that your post on stackoverflow got a number of responses. I would love to know what your learn from your experiments if you try some of the things mentioned there.

@kevinlinxc
Copy link
Author

Hi Jeff, that is good insight on UDP vs TCP being a small difference for large amounts of data, thank you. I'll keep you in the loop.

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

No branches or pull requests

2 participants