-
Notifications
You must be signed in to change notification settings - Fork 186
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
Update quickstart guide #792
Comments
Additionally, i see from the change log that there its faster to pass arrays to-and-from python/java. I did not find any documentation about this. Can we get some code samples for this? In my usecase, I am trying to pass a byte array from java to python and back (as a byte array). Any pointers would help. Blurb from documentation:
|
Most of these behaviors are automatic. Anything with the appropriate byte transfer is able to be transferred in bulk. These include memoryview, bytes, bytearray, and numpy array. If you can show me some sample code with your use case I can give specifics. Python has several APIs for transfer of sequences. For anything which supports the buffer API we can optimize by checking only the first element for conversion and then using the memcpy type API. Unfortunately, Java does not support pinning or write through behaviors so, views of Java memory are read only. |
My current implementation looks as follows:
As you can expect, the performance of converting an object to #json is high, i implemented a binary serializer on the java side (ProtoStuff). This improved the performance on the java side by 10 fold. I am trying to update the the contract on python class to use the binary serializer in hopes to improve the performance of my program. The java class has new methods:
Any tips here would be great. |
It appears that lambda as well as a few of the other late added features have not yet made the quickstart guide. This should be updated.
The text was updated successfully, but these errors were encountered: