You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm relatively new to Rust so bear with me. I'm working on a project that provides a Python API to Rust code via Pyo3. In my project I'm trying to enable fast serialization and deserialization using bincode. I read this crate can mitigate the performance issues I'm seeing (bincode takes 3 times longer than serialization/deserialization with serde_json).
It's not clear to me how to take advantage of this crate when I don't use a struct field to hold the data.
For reference, this is what the unedited, actual serialization and deserialization code snippet looks like, with the Pyo3 API intact:
I'm relatively new to Rust so bear with me. I'm working on a project that provides a Python API to Rust code via Pyo3. In my project I'm trying to enable fast serialization and deserialization using
bincode
. I read this crate can mitigate the performance issues I'm seeing (bincode
takes 3 times longer than serialization/deserialization withserde_json
).It's not clear to me how to take advantage of this crate when I don't use a struct field to hold the data.
For reference, this is what the unedited, actual serialization and deserialization code snippet looks like, with the Pyo3 API intact:
With the API removed, I suppose would be the analogous code:
See also: PyO3/pyo3#100
How can I utilize this crate in this case?
The text was updated successfully, but these errors were encountered: