Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/willcrichton/protojit
Protobuf autogenerator for Python
https://github.com/willcrichton/protojit
Last synced: 23 days ago
JSON representation
Protobuf autogenerator for Python
- Host: GitHub
- URL: https://github.com/willcrichton/protojit
- Owner: willcrichton
- Created: 2018-01-24T04:13:11.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2018-01-25T01:25:11.000Z (almost 7 years ago)
- Last Synced: 2024-11-21T05:48:12.575Z (about 1 month ago)
- Language: Python
- Size: 6.84 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# protojit
Protojit is a small library for automatic serialization and deserialization (akin to `pickle`, `marshal`, and `json`) of Python data objects. It uses Protobuf to dynamically JIT compile a serializer for a given kind of data. Essentially, it typechecks an example of what your data looks like and generates the appropriate serializer for that type.
While this proof of concept works correctly, upon benchmarking, this library was not any faster during serialization or deserialization than `marshal`, so it did not succeed in the goal of being the fastest serializer. It does, however, generate files that are on average 2-4x smaller than the aforementioned comparison libraries (try running `bench.py`).