fastpybase64 0.2.0__tar.gz → 0.2.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (22) hide show
  1. {fastpybase64-0.2.0/fastpybase64.egg-info → fastpybase64-0.2.1}/PKG-INFO +23 -1
  2. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/README.md +22 -0
  3. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/doc/make_charts.py +10 -0
  4. {fastpybase64-0.2.0 → fastpybase64-0.2.1/fastpybase64.egg-info}/PKG-INFO +23 -1
  5. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/pyproject.toml +1 -1
  6. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/src/fastpybase64.cpp +1 -1
  7. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/LICENSE-APACHE +0 -0
  8. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/LICENSE-MIT +0 -0
  9. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/MANIFEST.in +0 -0
  10. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/bench.py +0 -0
  11. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/fastpybase64.egg-info/SOURCES.txt +0 -0
  12. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/fastpybase64.egg-info/dependency_links.txt +0 -0
  13. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/fastpybase64.egg-info/requires.txt +0 -0
  14. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/fastpybase64.egg-info/top_level.txt +0 -0
  15. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/setup.cfg +0 -0
  16. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/setup.py +0 -0
  17. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/tests/conftest.py +0 -0
  18. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/tests/test_base64.py +0 -0
  19. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/vendor/simdutf-LICENSE-APACHE +0 -0
  20. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/vendor/simdutf-LICENSE-MIT +0 -0
  21. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/vendor/simdutf.cpp +0 -0
  22. {fastpybase64-0.2.0 → fastpybase64-0.2.1}/vendor/simdutf.h +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: fastpybase64
3
- Version: 0.2.0
3
+ Version: 0.2.1
4
4
  Summary: Fast Base64 encoding and decoding for Python, built on simdutf
5
5
  Author-email: Daniel Lemire <daniel@lemire.me>
6
6
  License-Expression: Apache-2.0 OR MIT
@@ -219,6 +219,28 @@ in `base64`) and in `urlsafe_b64decode`, it is 4 to 13 times slower than
219
219
  fastpybase64 from 4 KiB on. pybase64 has no
220
220
  `decodebytes`.
221
221
 
222
+ ### MIME
223
+
224
+ Lines of 76 characters ending with CRLF. Python 3.14.10, fastpybase64 0.2.0
225
+ (simdutf 9.4.0, `icelake`), pybase64 1.5.1, on the same machine. Speeds are
226
+ GB/s of binary data.
227
+
228
+ <picture>
229
+ <source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/simdutf/fastpybase64/main/doc/perf_mime_dark.png">
230
+ <img src="https://raw.githubusercontent.com/simdutf/fastpybase64/main/doc/perf_mime.png" width="80%" alt="Decoding 64 KiB of MIME base64 (CRLF): fastpybase64 12.21 GB/s, pybase64 2.93, base64 1.04">
231
+ </picture>
232
+
233
+ | function | size | `base64` | pybase64 | fastpybase64 |
234
+ |---|---:|---:|---:|---:|
235
+ | `b64decode`, MIME | 64 B | 0.30 | 0.41 | **0.89** |
236
+ | | 4 KiB | 0.97 | 2.50 | **10.03** |
237
+ | | 64 KiB | 1.04 | 2.93 | **12.21** |
238
+ | | 1 MiB | 1.04 | 2.95 | **12.06** |
239
+
240
+ fastpybase64 skips the line breaks while decoding. At 64 KiB it reaches
241
+ 12.21 GB/s, four times pybase64 (2.93 GB/s) and twelve times `base64`
242
+ (1.04 GB/s). From 64 KiB to 1 MiB the speed stays near 12 GB/s.
243
+
222
244
  ### Encoding
223
245
 
224
246
  <picture>
@@ -184,6 +184,28 @@ in `base64`) and in `urlsafe_b64decode`, it is 4 to 13 times slower than
184
184
  fastpybase64 from 4 KiB on. pybase64 has no
185
185
  `decodebytes`.
186
186
 
187
+ ### MIME
188
+
189
+ Lines of 76 characters ending with CRLF. Python 3.14.10, fastpybase64 0.2.0
190
+ (simdutf 9.4.0, `icelake`), pybase64 1.5.1, on the same machine. Speeds are
191
+ GB/s of binary data.
192
+
193
+ <picture>
194
+ <source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/simdutf/fastpybase64/main/doc/perf_mime_dark.png">
195
+ <img src="https://raw.githubusercontent.com/simdutf/fastpybase64/main/doc/perf_mime.png" width="80%" alt="Decoding 64 KiB of MIME base64 (CRLF): fastpybase64 12.21 GB/s, pybase64 2.93, base64 1.04">
196
+ </picture>
197
+
198
+ | function | size | `base64` | pybase64 | fastpybase64 |
199
+ |---|---:|---:|---:|---:|
200
+ | `b64decode`, MIME | 64 B | 0.30 | 0.41 | **0.89** |
201
+ | | 4 KiB | 0.97 | 2.50 | **10.03** |
202
+ | | 64 KiB | 1.04 | 2.93 | **12.21** |
203
+ | | 1 MiB | 1.04 | 2.95 | **12.06** |
204
+
205
+ fastpybase64 skips the line breaks while decoding. At 64 KiB it reaches
206
+ 12.21 GB/s, four times pybase64 (2.93 GB/s) and twelve times `base64`
207
+ (1.04 GB/s). From 64 KiB to 1 MiB the speed stays near 12 GB/s.
208
+
187
209
  ### Encoding
188
210
 
189
211
  <picture>
@@ -107,6 +107,16 @@ chart("perf_encode",
107
107
  ("base64 (stdlib)", "urlsafe_b64encode", 0.69, False)],
108
108
  "Encoding speed", "GB/s of binary data", " GB/s")
109
109
 
110
+ chart("perf_mime",
111
+ "Decoding MIME base64 in Python",
112
+ "b64decode of 64 KiB, lines of 76 characters ending with CRLF",
113
+ "fastpybase64 0.2.0 (simdutf 9.4.0) · pybase64 1.5.1 · Python 3.14.10 · "
114
+ + MACHINE,
115
+ [("fastpybase64", "b64decode", 12.21, True),
116
+ ("pybase64", "b64decode", 2.93, False),
117
+ ("base64 (stdlib)", "b64decode", 1.04, False)],
118
+ "Decoding speed", "GB/s of binary data", " GB/s")
119
+
110
120
  chart("perf_small",
111
121
  "Small inputs",
112
122
  "time per call for 64 bytes of binary data (88 base64 characters)",
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: fastpybase64
3
- Version: 0.2.0
3
+ Version: 0.2.1
4
4
  Summary: Fast Base64 encoding and decoding for Python, built on simdutf
5
5
  Author-email: Daniel Lemire <daniel@lemire.me>
6
6
  License-Expression: Apache-2.0 OR MIT
@@ -219,6 +219,28 @@ in `base64`) and in `urlsafe_b64decode`, it is 4 to 13 times slower than
219
219
  fastpybase64 from 4 KiB on. pybase64 has no
220
220
  `decodebytes`.
221
221
 
222
+ ### MIME
223
+
224
+ Lines of 76 characters ending with CRLF. Python 3.14.10, fastpybase64 0.2.0
225
+ (simdutf 9.4.0, `icelake`), pybase64 1.5.1, on the same machine. Speeds are
226
+ GB/s of binary data.
227
+
228
+ <picture>
229
+ <source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/simdutf/fastpybase64/main/doc/perf_mime_dark.png">
230
+ <img src="https://raw.githubusercontent.com/simdutf/fastpybase64/main/doc/perf_mime.png" width="80%" alt="Decoding 64 KiB of MIME base64 (CRLF): fastpybase64 12.21 GB/s, pybase64 2.93, base64 1.04">
231
+ </picture>
232
+
233
+ | function | size | `base64` | pybase64 | fastpybase64 |
234
+ |---|---:|---:|---:|---:|
235
+ | `b64decode`, MIME | 64 B | 0.30 | 0.41 | **0.89** |
236
+ | | 4 KiB | 0.97 | 2.50 | **10.03** |
237
+ | | 64 KiB | 1.04 | 2.93 | **12.21** |
238
+ | | 1 MiB | 1.04 | 2.95 | **12.06** |
239
+
240
+ fastpybase64 skips the line breaks while decoding. At 64 KiB it reaches
241
+ 12.21 GB/s, four times pybase64 (2.93 GB/s) and twelve times `base64`
242
+ (1.04 GB/s). From 64 KiB to 1 MiB the speed stays near 12 GB/s.
243
+
222
244
  ### Encoding
223
245
 
224
246
  <picture>
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "fastpybase64"
7
- version = "0.2.0"
7
+ version = "0.2.1"
8
8
  description = "Fast Base64 encoding and decoding for Python, built on simdutf"
9
9
  readme = "README.md"
10
10
  authors = [
@@ -13,7 +13,7 @@
13
13
  #include <atomic>
14
14
  #include <cstring>
15
15
 
16
- #define FASTPYBASE64_VERSION "0.2.0"
16
+ #define FASTPYBASE64_VERSION "0.2.1"
17
17
 
18
18
  // Unity build: compiling simdutf in this translation unit keeps the build
19
19
  // simple and lets the compiler inline across the boundary.
File without changes
File without changes
File without changes
File without changes
File without changes