From 36fad3997fa73f1a6add47caf804d9d708610abc Mon Sep 17 00:00:00 2001 From: Alex Kessinger Date: Thu, 24 Nov 2016 09:22:16 -0800 Subject: [PATCH 01/32] First pages commit --- index.html | 1 + 1 file changed, 1 insertion(+) create mode 100644 index.html diff --git a/index.html b/index.html new file mode 100644 index 0000000..f1afed9 --- /dev/null +++ b/index.html @@ -0,0 +1 @@ +My Page From 9d92b171fcac0fb8d18397b5c033f7929e0e50dc Mon Sep 17 00:00:00 2001 From: Travis CI Date: Thu, 24 Nov 2016 17:31:11 +0000 Subject: [PATCH 02/32] Deploy to GitHub Pages: a850b133c12287cce77276eacd294db142844f58 --- index.html | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/index.html b/index.html index f1afed9..ddb19ef 100644 --- a/index.html +++ b/index.html @@ -1 +1,19 @@ -My Page +

Python Serialization Benchmark

+

This repository maintains a set of benchmarks for python serialization frameworks.

+

Currently the following projects are benchmarked.

+ +
+Library                  One Object    Many Objects
+---------------------  ------------  --------------
+Strainer                  0.0334759      0.00678802
+serpy                     0.0388439      0.0073688
+Colander                  0.145118       0.028892
+Marshmallow               0.607224       0.118006
+Django REST Framework     1.30471        0.185136
+
\ No newline at end of file From 8957503198f8e264a41bef156132037d6117c617 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Thu, 24 Nov 2016 17:53:21 +0000 Subject: [PATCH 03/32] Deploy to GitHub Pages: 2118471a64d96556abe4d5e4ba69d66b939a1e0a --- index.html | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/index.html b/index.html index ddb19ef..79fbab2 100644 --- a/index.html +++ b/index.html @@ -1,5 +1,6 @@

Python Serialization Benchmark

This repository maintains a set of benchmarks for python serialization frameworks.

+

You can find the latest benchmarks on this page.

Currently the following projects are benchmarked.

  • Colander
  • @@ -11,9 +12,9 @@

    Python Serialization Benchmark

     Library                  One Object    Many Objects
     ---------------------  ------------  --------------
    -Strainer                  0.0334759      0.00678802
    -serpy                     0.0388439      0.0073688
    -Colander                  0.145118       0.028892
    -Marshmallow               0.607224       0.118006
    -Django REST Framework     1.30471        0.185136
    +Strainer                  0.0336289      0.006814
    +serpy                     0.0392451      0.00742602
    +Colander                  0.145964       0.029237
    +Marshmallow               0.605923       0.117652
    +Django REST Framework     1.32028        0.187281
     
    \ No newline at end of file From ec26ce20a821335ca5f0d675f356dfbbbd0ba16a Mon Sep 17 00:00:00 2001 From: Travis CI Date: Thu, 24 Nov 2016 18:11:56 +0000 Subject: [PATCH 04/32] Deploy to GitHub Pages: 00b4931014a7522947f1a5342b515164b196db21 --- index.html | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/index.html b/index.html index 79fbab2..b46c5d5 100644 --- a/index.html +++ b/index.html @@ -9,12 +9,13 @@

    Python Serialization Benchmark

  • marshmallow
  • Strainer
+

Each framework is asked to serialize a list of 2 objcts a 1000 times, and then 1 object a 1000 times.

-Library                  One Object    Many Objects
----------------------  ------------  --------------
-Strainer                  0.0336289      0.006814
-serpy                     0.0392451      0.00742602
-Colander                  0.145964       0.029237
-Marshmallow               0.605923       0.117652
-Django REST Framework     1.32028        0.187281
-
\ No newline at end of file +Library Many Objects One Object

+
+

Strainer 0.0689921 0.0345008 +serpy 0.0743518 0.03845 +Colander 0.311117 0.145795 +Marshmallow 1.15847 0.59406 +Django REST Framework 1.86901 1.27994 +

\ No newline at end of file From 9fcae9dc111675158a5d562943bf34106ed1e465 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Thu, 24 Nov 2016 18:15:19 +0000 Subject: [PATCH 05/32] Deploy to GitHub Pages: 519075c8b38ed4ee31d0685d22b69c4e890e1108 --- index.html | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/index.html b/index.html index b46c5d5..9064cb4 100644 --- a/index.html +++ b/index.html @@ -9,13 +9,13 @@

Python Serialization Benchmark

  • marshmallow
  • Strainer
  • -

    Each framework is asked to serialize a list of 2 objcts a 1000 times, and then 1 object a 1000 times. +

    Each framework is asked to serialize a list of 2 objcts a 1000 times, and then 1 object a 1000 times.

    -Library                  Many Objects    One Object

    -
    -

    Strainer 0.0689921 0.0345008 -serpy 0.0743518 0.03845 -Colander 0.311117 0.145795 -Marshmallow 1.15847 0.59406 -Django REST Framework 1.86901 1.27994 -

    \ No newline at end of file +Library Many Objects One Object +--------------------- -------------- ------------ +Strainer 0.0657301 0.0327411 +serpy 0.102354 0.0389669 +Colander 0.291603 0.145159 +Marshmallow 1.25196 0.598393 +Django REST Framework 1.86221 1.30072 + \ No newline at end of file From e0a093a252c0129b0722c27745a4aa0f3202481d Mon Sep 17 00:00:00 2001 From: Travis CI Date: Thu, 24 Nov 2016 18:40:05 +0000 Subject: [PATCH 06/32] Deploy to GitHub Pages: 9c15417ef0f9187cb5118353747be07f6b50b85e --- index.html | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/index.html b/index.html index 9064cb4..2cb4904 100644 --- a/index.html +++ b/index.html @@ -9,13 +9,15 @@

    Python Serialization Benchmark

  • marshmallow
  • Strainer
  • +

    Along with a baseline of a custom function that doesn't use a framework.

    Each framework is asked to serialize a list of 2 objcts a 1000 times, and then 1 object a 1000 times.

     Library                  Many Objects    One Object
     ---------------------  --------------  ------------
    -Strainer                    0.0657301     0.0327411
    -serpy                       0.102354      0.0389669
    -Colander                    0.291603      0.145159
    -Marshmallow                 1.25196       0.598393
    -Django REST Framework       1.86221       1.30072
    +Custom                      0.013675     0.00681901
    +Strainer                    0.068732     0.034344
    +serpy                       0.0736301    0.039283
    +Colander                    0.32582      0.153205
    +Marshmallow                 1.29869      0.658006
    +Django REST Framework       1.97302      1.3905
     
    \ No newline at end of file From c95e0a5a7e49cdbdc013c59c59ef85a91cc7e0ba Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sun, 27 Nov 2016 22:19:45 +0000 Subject: [PATCH 07/32] Deploy to GitHub Pages: ca736964304bc9755ef0357bab51ad458bb6ab6d --- index.html | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/index.html b/index.html index 2cb4904..2526cea 100644 --- a/index.html +++ b/index.html @@ -14,10 +14,11 @@

    Python Serialization Benchmark

     Library                  Many Objects    One Object
     ---------------------  --------------  ------------
    -Custom                      0.013675     0.00681901
    -Strainer                    0.068732     0.034344
    -serpy                       0.0736301    0.039283
    -Colander                    0.32582      0.153205
    -Marshmallow                 1.29869      0.658006
    -Django REST Framework       1.97302      1.3905
    +Custom                      0.0138059    0.00694203
    +Strainer                    0.0658381    0.0329778
    +serpy                       0.072367     0.0382979
    +Colander                    0.28919      0.14445
    +subjects.loli               0.639348     0.311311
    +Marshmallow                 1.17502      0.602514
    +Django REST Framework       1.86723      1.29026
     
    \ No newline at end of file From b6210eef7424d4e3f3a98a18b8053eb1a26c7455 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Tue, 29 Nov 2016 17:36:04 +0000 Subject: [PATCH 08/32] Deploy to GitHub Pages: 8beee40913855bc3f82f8b9b71a4faa14039df9d --- index.html | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/index.html b/index.html index 2526cea..92ab7c3 100644 --- a/index.html +++ b/index.html @@ -14,11 +14,10 @@

    Python Serialization Benchmark

     Library                  Many Objects    One Object
     ---------------------  --------------  ------------
    -Custom                      0.0138059    0.00694203
    -Strainer                    0.0658381    0.0329778
    -serpy                       0.072367     0.0382979
    -Colander                    0.28919      0.14445
    -subjects.loli               0.639348     0.311311
    -Marshmallow                 1.17502      0.602514
    -Django REST Framework       1.86723      1.29026
    +Custom                      0.0171781    0.00692487
    +Strainer                    0.0833452    0.0340791
    +serpy                       0.089483     0.038825
    +subjects.loli               0.73178      0.328769
    +Marshmallow                 1.23391      0.610214
    +Django REST Framework       1.96648      1.40255
     
    \ No newline at end of file From 51dc178bd8244a8e79a9a999ada6e39273c335be Mon Sep 17 00:00:00 2001 From: Travis CI Date: Tue, 29 Nov 2016 17:40:06 +0000 Subject: [PATCH 09/32] Deploy to GitHub Pages: cc8e2a1d65231158952dd51df01b42f7e0c20e5b --- index.html | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/index.html b/index.html index 92ab7c3..433cfda 100644 --- a/index.html +++ b/index.html @@ -14,10 +14,10 @@

    Python Serialization Benchmark

     Library                  Many Objects    One Object
     ---------------------  --------------  ------------
    -Custom                      0.0171781    0.00692487
    -Strainer                    0.0833452    0.0340791
    -serpy                       0.089483     0.038825
    -subjects.loli               0.73178      0.328769
    -Marshmallow                 1.23391      0.610214
    -Django REST Framework       1.96648      1.40255
    +Custom                      0.0139711    0.00697112
    +Strainer                    0.069011     0.0333052
    +serpy                       0.0743809    0.040561
    +Lollipop                    0.651375     0.336125
    +Marshmallow                 1.23853      0.625176
    +Django REST Framework       1.9754       1.32321
     
    \ No newline at end of file From 3615fd8390a37fb064bee79ffb12826e41c1f49e Mon Sep 17 00:00:00 2001 From: Travis CI Date: Tue, 29 Nov 2016 17:42:47 +0000 Subject: [PATCH 10/32] Deploy to GitHub Pages: 0ddd5e220c8e85ecb825891fb22ea835d3e9b4cf --- index.html | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/index.html b/index.html index 433cfda..ec0fd0e 100644 --- a/index.html +++ b/index.html @@ -3,21 +3,21 @@

    Python Serialization Benchmark

    You can find the latest benchmarks on this page.

    Currently the following projects are benchmarked.

    Along with a baseline of a custom function that doesn't use a framework.

    Each framework is asked to serialize a list of 2 objcts a 1000 times, and then 1 object a 1000 times.

     Library                  Many Objects    One Object
     ---------------------  --------------  ------------
    -Custom                      0.0139711    0.00697112
    -Strainer                    0.069011     0.0333052
    -serpy                       0.0743809    0.040561
    -Lollipop                    0.651375     0.336125
    -Marshmallow                 1.23853      0.625176
    -Django REST Framework       1.9754       1.32321
    +Custom                      0.013634     0.00682497
    +Strainer                    0.0675151    0.0337131
    +serpy                       0.0722299    0.0381689
    +Lollipop                    0.658723     0.324521
    +Marshmallow                 1.2704       0.624744
    +Django REST Framework       2.07065      1.33223
     
    \ No newline at end of file From 306d29fade430bb189089839347e21ec8e5e0347 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Tue, 29 Nov 2016 17:43:09 +0000 Subject: [PATCH 11/32] Deploy to GitHub Pages: 715e3d29c138eea952540b99d305c913a52391cf --- index.html | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/index.html b/index.html index ec0fd0e..0b1fa4c 100644 --- a/index.html +++ b/index.html @@ -10,14 +10,14 @@

    Python Serialization Benchmark

  • Lollipop
  • Along with a baseline of a custom function that doesn't use a framework.

    -

    Each framework is asked to serialize a list of 2 objcts a 1000 times, and then 1 object a 1000 times.

    +

    Each framework is asked to serialize a list of 2 objects a 1000 times, and then 1 object a 1000 times.

     Library                  Many Objects    One Object
     ---------------------  --------------  ------------
    -Custom                      0.013634     0.00682497
    -Strainer                    0.0675151    0.0337131
    -serpy                       0.0722299    0.0381689
    -Lollipop                    0.658723     0.324521
    -Marshmallow                 1.2704       0.624744
    -Django REST Framework       2.07065      1.33223
    +Custom                      0.013813     0.00686789
    +Strainer                    0.069042     0.034332
    +serpy                       0.0770888    0.0383739
    +Lollipop                    0.648447     0.315976
    +Marshmallow                 1.17259      0.597804
    +Django REST Framework       1.88957      1.32931
     
    \ No newline at end of file From 4c551c22ebd129d2d2809fec0bb432522bd1c855 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Tue, 29 Nov 2016 17:59:14 +0000 Subject: [PATCH 12/32] Deploy to GitHub Pages: dcf9ee80c26d4edc5977eb582fbb8c54c9ce7894 --- index.html | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/index.html b/index.html index 0b1fa4c..26cb9d0 100644 --- a/index.html +++ b/index.html @@ -14,10 +14,10 @@

    Python Serialization Benchmark

     Library                  Many Objects    One Object
     ---------------------  --------------  ------------
    -Custom                      0.013813     0.00686789
    -Strainer                    0.069042     0.034332
    -serpy                       0.0770888    0.0383739
    -Lollipop                    0.648447     0.315976
    -Marshmallow                 1.17259      0.597804
    -Django REST Framework       1.88957      1.32931
    +Custom                      0.01373      0.00689316
    +Strainer                    0.0705271    0.0354161
    +serpy                       0.0734689    0.038516
    +Lollipop                    0.659461     0.321331
    +Marshmallow                 1.26974      0.601069
    +Django REST Framework       1.9317       1.32093
     
    \ No newline at end of file From 924ffed3a59b5dca3a59c1fb8c74f835bd1631cc Mon Sep 17 00:00:00 2001 From: Travis CI Date: Wed, 30 Nov 2016 06:22:19 +0000 Subject: [PATCH 13/32] Deploy to GitHub Pages: 1b3424b0e28fffcc9e94c377fd064c75faaab03c --- index.html | 116 ++++++++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 102 insertions(+), 14 deletions(-) diff --git a/index.html b/index.html index 26cb9d0..0a73cc4 100644 --- a/index.html +++ b/index.html @@ -1,23 +1,111 @@ + + + + + +

    Python Serialization Benchmark

    This repository maintains a set of benchmarks for python serialization frameworks.

    You can find the latest benchmarks on this page.

    Currently the following projects are benchmarked.

    -

    Along with a baseline of a custom function that doesn't use a framework.

    -

    Each framework is asked to serialize a list of 2 objects a 1000 times, and then 1 object a 1000 times.

    -
    -Library                  Many Objects    One Object
    +

    Along with a baseline custom function that doesn't use a framework.

    +
    Library                  Many Objects    One Object
     ---------------------  --------------  ------------
    -Custom                      0.01373      0.00689316
    -Strainer                    0.0705271    0.0354161
    -serpy                       0.0734689    0.038516
    -Lollipop                    0.659461     0.321331
    -Marshmallow                 1.26974      0.601069
    -Django REST Framework       1.9317       1.32093
    -
    \ No newline at end of file +Custom 0.0139651 0.00691795 +Strainer 0.068619 0.0343139 +serpy 0.073632 0.038933 +Lollipop 0.662228 0.322233 +Marshmallow 1.1968 0.612923 +Django REST Framework 1.87166 1.30884 +
    + +

    The Benchmark

    +

    Each framework is asked to serialize a list of 2 objects a 1000 times, and then 1 object a 1000 times.

    +

    This is the current object that is being serialized.

    +
    class ChildTestObject(object):
    +    def __init__(self, multiplier=None):
    +        self.w = 1000 * multiplier if multiplier else 100
    +        self.x = 20 * multiplier if multiplier else 20
    +        self.y = 'hello' * multiplier if multiplier else 'hello'
    +        self.z = 10 * multiplier if multiplier else 10
    +
    +
    +class ParentTestObject(object):
    +    def __init__(self):
    +        self.foo = 'bar'
    +        self.sub = ChildTestObject()
    +        self.subs = [ChildTestObject(i) for i in xrange(10)]
    +
    +    def bar(self):
    +        return 5
    +
    +benchmark_object = ParentTestObject()
    +
    + +

    Discussion

    +

    Serialization from python objects to JSON, XML, or other transmission formats is a common task for many web related projects. In order to fill that need a number of frameworks have arised. While their aims are similar, they don't all share the same attributes. Here are how some of the features comapre.

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    ProjectSerializationEncodingDeserializationValidation
    Django REST FrameworkYesYesYesYes
    serpyYesNoNoNo
    marshmallowYesYesYesYes
    LollipopYesNoYesYes
    strainerYesYesYesYes
    + +
      +
    • Serialization: Does the framework provide a way of serializing python objects to simple datastructures
    • +
    • Encoding: Does the framework provide a way of encoding data into a wire format
    • +
    • Deserialization: Does the framework provide a way of deserializing simple data structures into complex data structures
    • +
    • Validation: Does the framework provide a way of validating datastructures, and reprorting error conditions
    • +
    • Part of Framework: Is serialization apart of a larger framework
    • +
    + + From 9027560b52340ea042cd8a64b70a19bfed44f2b1 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sun, 11 Dec 2016 06:02:21 +0000 Subject: [PATCH 14/32] Deploy to GitHub Pages: c41695797559c455256db5ff5d0857ed81129048 --- index.html | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/index.html b/index.html index 0a73cc4..e894f84 100644 --- a/index.html +++ b/index.html @@ -18,12 +18,12 @@

    Python Serialization Benchmark

    Along with a baseline custom function that doesn't use a framework.

    Library                  Many Objects    One Object
     ---------------------  --------------  ------------
    -Custom                      0.0139651    0.00691795
    -Strainer                    0.068619     0.0343139
    -serpy                       0.073632     0.038933
    -Lollipop                    0.662228     0.322233
    -Marshmallow                 1.1968       0.612923
    -Django REST Framework       1.87166      1.30884
    +Custom                      0.0137529    0.00688696
    +Strainer                    0.0598509    0.0299289
    +serpy                       0.072109     0.0382042
    +Lollipop                    0.642238     0.31396
    +Marshmallow                 1.15195      0.622856
    +Django REST Framework       1.92448      1.29381
     

    The Benchmark

    From 3aee94ea7f8b0a47e5e28b4a0c313b64b5ded8b4 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Tue, 21 Mar 2017 16:14:57 +0000 Subject: [PATCH 15/32] Deploy to GitHub Pages: d1b4c4bfeb6ccffe27b5adb1de3f14ab6dd2ce7c --- index.html | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/index.html b/index.html index e894f84..17beb80 100644 --- a/index.html +++ b/index.html @@ -18,12 +18,12 @@

    Python Serialization Benchmark

    Along with a baseline custom function that doesn't use a framework.

    Library                  Many Objects    One Object
     ---------------------  --------------  ------------
    -Custom                      0.0137529    0.00688696
    -Strainer                    0.0598509    0.0299289
    -serpy                       0.072109     0.0382042
    -Lollipop                    0.642238     0.31396
    -Marshmallow                 1.15195      0.622856
    -Django REST Framework       1.92448      1.29381
    +Custom                      0.0139072    0.00688696
    +Strainer                    0.099998     0.0301809
    +serpy                       0.092308     0.0561631
    +Lollipop                    0.639235     0.352615
    +Marshmallow                 1.1639       0.699365
    +Django REST Framework       2.0504       1.5498
     

    The Benchmark

    From a9657f5088c89ee0f1ced43982884287a67f80da Mon Sep 17 00:00:00 2001 From: Travis CI Date: Tue, 21 Mar 2017 16:16:59 +0000 Subject: [PATCH 16/32] Deploy to GitHub Pages: 4197a665f297a5d3347f36952e9f988db6c5e3d3 --- index.html | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/index.html b/index.html index 17beb80..adab1e7 100644 --- a/index.html +++ b/index.html @@ -18,12 +18,12 @@

    Python Serialization Benchmark

    Along with a baseline custom function that doesn't use a framework.

    Library                  Many Objects    One Object
     ---------------------  --------------  ------------
    -Custom                      0.0139072    0.00688696
    -Strainer                    0.099998     0.0301809
    -serpy                       0.092308     0.0561631
    -Lollipop                    0.639235     0.352615
    -Marshmallow                 1.1639       0.699365
    -Django REST Framework       2.0504       1.5498
    +Custom                      0.013824     0.00690889
    +Strainer                    0.0605829    0.0303049
    +serpy                       0.0726092    0.0383818
    +Lollipop                    0.655558     0.319407
    +Marshmallow                 1.14359      0.555189
    +Django REST Framework       1.88762      1.30062
     

    The Benchmark

    From 0db139f7bedde6cf563e402be72fbd8f2b529c4e Mon Sep 17 00:00:00 2001 From: Travis CI Date: Wed, 12 Apr 2017 20:40:39 +0000 Subject: [PATCH 17/32] Deploy to GitHub Pages: 306488bfdf0dcab863bb70d00c72b301dc8205e1 --- index.html | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/index.html b/index.html index adab1e7..e134e65 100644 --- a/index.html +++ b/index.html @@ -14,16 +14,18 @@

    Python Serialization Benchmark

  • Marshmallow
  • Strainer
  • Lollipop
  • +
  • kim
  • Along with a baseline custom function that doesn't use a framework.

    Library                  Many Objects    One Object
     ---------------------  --------------  ------------
    -Custom                      0.013824     0.00690889
    -Strainer                    0.0605829    0.0303049
    -serpy                       0.0726092    0.0383818
    -Lollipop                    0.655558     0.319407
    -Marshmallow                 1.14359      0.555189
    -Django REST Framework       1.88762      1.30062
    +Custom                      0.0137758    0.00682688
    +Strainer                    0.0596168    0.030277
    +serpy                       0.07267      0.0382729
    +Lollipop                    0.473351     0.228435
    +Marshmallow                 1.10127      0.556963
    +Django REST Framework       1.87502      1.31233
    +kim                         2.29187      1.15728
     

    The Benchmark

    From 50bcf5dffa690f381f0b57eeb4f79eb6239edf0a Mon Sep 17 00:00:00 2001 From: Travis CI Date: Wed, 12 Apr 2017 20:45:30 +0000 Subject: [PATCH 18/32] Deploy to GitHub Pages: 7c23b5d00d26a8b9d505c3e483c0c9e128e96526 --- index.html | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/index.html b/index.html index e134e65..188d357 100644 --- a/index.html +++ b/index.html @@ -19,13 +19,13 @@

    Python Serialization Benchmark

    Along with a baseline custom function that doesn't use a framework.

    Library                  Many Objects    One Object
     ---------------------  --------------  ------------
    -Custom                      0.0137758    0.00682688
    -Strainer                    0.0596168    0.030277
    -serpy                       0.07267      0.0382729
    -Lollipop                    0.473351     0.228435
    -Marshmallow                 1.10127      0.556963
    -Django REST Framework       1.87502      1.31233
    -kim                         2.29187      1.15728
    +Custom                      0.0138531    0.00697112
    +Strainer                    0.0602059    0.0299511
    +serpy                       0.072561     0.0382328
    +Lollipop                    0.477565     0.229895
    +Marshmallow                 1.18749      0.567287
    +Django REST Framework       1.90874      1.31186
    +kim                         2.27016      1.13375
     

    The Benchmark

    @@ -99,6 +99,13 @@

    Discussion

    Yes Yes + + kim + Yes + No + Yes + Yes + From 12d4099691a3226dfb5470bb80f9655cea21f40d Mon Sep 17 00:00:00 2001 From: Travis CI Date: Wed, 12 Apr 2017 20:51:43 +0000 Subject: [PATCH 19/32] Deploy to GitHub Pages: 1a2136b382d264e3c03f1b5203b15ae474398cd7 --- index.html | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/index.html b/index.html index 188d357..241e153 100644 --- a/index.html +++ b/index.html @@ -19,13 +19,13 @@

    Python Serialization Benchmark

    Along with a baseline custom function that doesn't use a framework.

    Library                  Many Objects    One Object
     ---------------------  --------------  ------------
    -Custom                      0.0138531    0.00697112
    -Strainer                    0.0602059    0.0299511
    -serpy                       0.072561     0.0382328
    -Lollipop                    0.477565     0.229895
    -Marshmallow                 1.18749      0.567287
    -Django REST Framework       1.90874      1.31186
    -kim                         2.27016      1.13375
    +Custom                      0.0187769    0.00682402
    +Strainer                    0.0603201    0.0337129
    +serpy                       0.073787     0.038656
    +Lollipop                    0.47821      0.231566
    +Marshmallow                 1.14844      0.598486
    +Django REST Framework       1.94096      1.3277
    +kim                         2.28477      1.15237
     

    The Benchmark

    From dace8992b9c55d135b866c0ff5d2a4cd4349e0fb Mon Sep 17 00:00:00 2001 From: Travis CI Date: Thu, 13 Apr 2017 16:12:34 +0000 Subject: [PATCH 20/32] Deploy to GitHub Pages: 2a371083bf3885c4acaf754f9a4f4a7411526428 --- index.html | 19 ++++++++++--------- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/index.html b/index.html index 241e153..398343e 100644 --- a/index.html +++ b/index.html @@ -17,15 +17,16 @@

    Python Serialization Benchmark

  • kim
  • Along with a baseline custom function that doesn't use a framework.

    -
    Library                  Many Objects    One Object
    ----------------------  --------------  ------------
    -Custom                      0.0187769    0.00682402
    -Strainer                    0.0603201    0.0337129
    -serpy                       0.073787     0.038656
    -Lollipop                    0.47821      0.231566
    -Marshmallow                 1.14844      0.598486
    -Django REST Framework       1.94096      1.3277
    -kim                         2.28477      1.15237
    +
    Library                  Many Objects (seconds)    One Object (seconds)
    +---------------------  ------------------------  ----------------------
    +Custom                                0.0147464              0.00725865
    +lima                                  0.0186098              0.00937057
    +serpy                                 0.0557761              0.029979
    +Strainer                              0.0647128              0.0323169
    +Lollipop                              0.569409               0.273222
    +Marshmallow                           1.11986                0.468423
    +Django REST Framework                 1.2735                 0.877778
    +kim                                   2.73208                1.33061
     

    The Benchmark

    From 60e781d8c747cfc184f842bde7adc908350875cf Mon Sep 17 00:00:00 2001 From: Travis CI Date: Mon, 24 Apr 2017 14:06:14 +0000 Subject: [PATCH 21/32] Deploy to GitHub Pages: 5e3c164fa06e93e02af6b522dccfb200585a3764 --- index.html | 33 +++++++++++++++++++++++---------- 1 file changed, 23 insertions(+), 10 deletions(-) diff --git a/index.html b/index.html index 398343e..d9392b4 100644 --- a/index.html +++ b/index.html @@ -17,16 +17,29 @@

    Python Serialization Benchmark

  • kim
  • Along with a baseline custom function that doesn't use a framework.

    -
    Library                  Many Objects (seconds)    One Object (seconds)
    ----------------------  ------------------------  ----------------------
    -Custom                                0.0147464              0.00725865
    -lima                                  0.0186098              0.00937057
    -serpy                                 0.0557761              0.029979
    -Strainer                              0.0647128              0.0323169
    -Lollipop                              0.569409               0.273222
    -Marshmallow                           1.11986                0.468423
    -Django REST Framework                 1.2735                 0.877778
    -kim                                   2.73208                1.33061
    +

    Running the test suite

    +

    A Docker container is bundled with the repository which you can use to run the benchmarks. Firstly make sure you have Docker installed.

    +
      +
    1. +

      Install Docker

      +
    2. +
    3. +

      Build the container $ docker-compose build

      +
    4. +
    5. +

      Run the tests. $ docker-compose run --rm tests

      +
    6. +
    +
    Library                  Many Objects (seconds)    One Object (seconds)    Relative
    +---------------------  ------------------------  ----------------------  ----------
    +Custom                                0.015099               0.00744438     1
    +lima                                  0.0184031              0.00941515     1.23398
    +serpy                                 0.0564134              0.0302956      3.84631
    +Strainer                              0.0645332              0.0326135      4.30932
    +Lollipop                              0.572213               0.275513      37.6042
    +Marshmallow                           0.955579               0.494589      64.3277
    +kim                                   1.10544                0.548943      73.3867
    +Django REST Framework                 1.38124                0.979011     104.698
     

    The Benchmark

    From 7ab74b1a79f2d5bdbd73e9c393e291d7ff317473 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sun, 27 Aug 2017 04:56:59 +0000 Subject: [PATCH 22/32] Deploy to GitHub Pages: c77971dc02b5bce9fd5feb0ddac672dabcace661 --- index.html | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/index.html b/index.html index d9392b4..eb40ca3 100644 --- a/index.html +++ b/index.html @@ -15,6 +15,7 @@

    Python Serialization Benchmark

  • Strainer
  • Lollipop
  • kim
  • +
  • toasted-marshmallow
  • Along with a baseline custom function that doesn't use a framework.

    Running the test suite

    @@ -32,14 +33,15 @@

    Running the test suite

    Library                  Many Objects (seconds)    One Object (seconds)    Relative
     ---------------------  ------------------------  ----------------------  ----------
    -Custom                                0.015099               0.00744438     1
    -lima                                  0.0184031              0.00941515     1.23398
    -serpy                                 0.0564134              0.0302956      3.84631
    -Strainer                              0.0645332              0.0326135      4.30932
    -Lollipop                              0.572213               0.275513      37.6042
    -Marshmallow                           0.955579               0.494589      64.3277
    -kim                                   1.10544                0.548943      73.3867
    -Django REST Framework                 1.38124                0.979011     104.698
    +Custom                                0.0256822               0.013052      1
    +lima                                  0.0383852               0.0197146     1.49996
    +serpy                                 0.104605                0.0706699     4.52507
    +Strainer                              0.114318                0.0885544     5.23755
    +Toasted Marshmallow                   0.292227                0.135766     11.0495
    +Lollipop                              1.23894                 0.419955     42.8277
    +Marshmallow                           2.13818                 0.749287     74.5457
    +kim                                   2.46978                 1.32616      97.9997
    +Django REST Framework                 2.53841                 1.75292     110.789
     

    The Benchmark

    From 2230bf173295a1691da25f900c4188b3a0842f15 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Mon, 2 Jul 2018 22:22:03 +0000 Subject: [PATCH 23/32] Deploy to GitHub Pages: f16cf9f940f7c92530acb01598c46559799f5bf5 --- index.html | 20 +++++++++++--------- 1 file changed, 11 insertions(+), 9 deletions(-) diff --git a/index.html b/index.html index eb40ca3..ea04a92 100644 --- a/index.html +++ b/index.html @@ -16,6 +16,7 @@

    Python Serialization Benchmark

  • Lollipop
  • kim
  • toasted-marshmallow
  • +
  • Colander
  • Along with a baseline custom function that doesn't use a framework.

    Running the test suite

    @@ -33,15 +34,16 @@

    Running the test suite

    Library                  Many Objects (seconds)    One Object (seconds)    Relative
     ---------------------  ------------------------  ----------------------  ----------
    -Custom                                0.0256822               0.013052      1
    -lima                                  0.0383852               0.0197146     1.49996
    -serpy                                 0.104605                0.0706699     4.52507
    -Strainer                              0.114318                0.0885544     5.23755
    -Toasted Marshmallow                   0.292227                0.135766     11.0495
    -Lollipop                              1.23894                 0.419955     42.8277
    -Marshmallow                           2.13818                 0.749287     74.5457
    -kim                                   2.46978                 1.32616      97.9997
    -Django REST Framework                 2.53841                 1.75292     110.789
    +Custom                                0.0329726               0.0159111     1
    +lima                                  0.0401821               0.0206914     1.24527
    +serpy                                 0.142545                0.0760007     4.47073
    +Strainer                              0.197942                0.0984321     6.06284
    +Toasted Marshmallow                   0.296397                0.153362      9.2006
    +Lollipop                              0.7695                  0.325401     22.3981
    +Colander                              0.942478                0.459746     28.6849
    +kim                                   1.30952                 0.785586     42.859
    +Marshmallow                           2.15868                 1.0906       66.4696
    +Django REST Framework                 2.6968                  1.89875      94.0099
     

    The Benchmark

    From 901da2d61850648931912ff8e4a733468ac2f73b Mon Sep 17 00:00:00 2001 From: Travis CI Date: Mon, 2 Jul 2018 22:26:49 +0000 Subject: [PATCH 24/32] Deploy to GitHub Pages: f16cf9f940f7c92530acb01598c46559799f5bf5 --- index.html | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/index.html b/index.html index ea04a92..d404678 100644 --- a/index.html +++ b/index.html @@ -34,16 +34,16 @@

    Running the test suite

    Library                  Many Objects (seconds)    One Object (seconds)    Relative
     ---------------------  ------------------------  ----------------------  ----------
    -Custom                                0.0329726               0.0159111     1
    -lima                                  0.0401821               0.0206914     1.24527
    -serpy                                 0.142545                0.0760007     4.47073
    -Strainer                              0.197942                0.0984321     6.06284
    -Toasted Marshmallow                   0.296397                0.153362      9.2006
    -Lollipop                              0.7695                  0.325401     22.3981
    -Colander                              0.942478                0.459746     28.6849
    -kim                                   1.30952                 0.785586     42.859
    -Marshmallow                           2.15868                 1.0906       66.4696
    -Django REST Framework                 2.6968                  1.89875      94.0099
    +Custom                                0.0229433               0.0117581     1
    +lima                                  0.0243461               0.0123394     1.05718
    +serpy                                 0.0917017               0.0510154     4.11273
    +Strainer                              0.161441                0.0835772     7.06076
    +Toasted Marshmallow                   0.169405                0.0808725     7.21234
    +Colander                              0.626526                0.296166     26.5895
    +Lollipop                              0.887586                0.476963     39.3226
    +Marshmallow                           1.40761                 0.743763     61.9967
    +kim                                   1.59593                 0.73712      67.2323
    +Django REST Framework                 1.98968                 1.41337      98.0668
     

    The Benchmark

    From 8ea7667f246097328e3112df28ce7da954739b36 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Mon, 2 Jul 2018 22:29:07 +0000 Subject: [PATCH 25/32] Deploy to GitHub Pages: 22024be5ebad07b6d1e0d8f013cdfa497687e414 --- index.html | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/index.html b/index.html index d404678..4a6c608 100644 --- a/index.html +++ b/index.html @@ -34,16 +34,16 @@

    Running the test suite

    Library                  Many Objects (seconds)    One Object (seconds)    Relative
     ---------------------  ------------------------  ----------------------  ----------
    -Custom                                0.0229433               0.0117581     1
    -lima                                  0.0243461               0.0123394     1.05718
    -serpy                                 0.0917017               0.0510154     4.11273
    -Strainer                              0.161441                0.0835772     7.06076
    -Toasted Marshmallow                   0.169405                0.0808725     7.21234
    -Colander                              0.626526                0.296166     26.5895
    -Lollipop                              0.887586                0.476963     39.3226
    -Marshmallow                           1.40761                 0.743763     61.9967
    -kim                                   1.59593                 0.73712      67.2323
    -Django REST Framework                 1.98968                 1.41337      98.0668
    +Custom                                0.0185211              0.00847864     1
    +lima                                  0.0323029              0.0103629      1.58023
    +serpy                                 0.0767255              0.0402741      4.33337
    +Strainer                              0.111886               0.0480838      5.92485
    +Toasted Marshmallow                   0.147332               0.0805259      8.43926
    +Colander                              0.460081               0.237314      25.8297
    +Lollipop                              0.744028               0.349707      40.5091
    +kim                                   1.4407                 0.691975      78.9887
    +Marshmallow                           1.7112                 0.871818      95.6683
    +Django REST Framework                 1.62452                1.11424      101.437
     

    The Benchmark

    From c7b267e802d5648cd06d4c80e4e07130360a904a Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sun, 7 Jul 2019 17:07:41 +0000 Subject: [PATCH 26/32] Deploy to GitHub Pages: 774c5ef1fca7ee41b90b10dccc0323b13ffc5e20 --- index.html | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/index.html b/index.html index 4a6c608..4b9990a 100644 --- a/index.html +++ b/index.html @@ -34,16 +34,17 @@

    Running the test suite

    Library                  Many Objects (seconds)    One Object (seconds)    Relative
     ---------------------  ------------------------  ----------------------  ----------
    -Custom                                0.0185211              0.00847864     1
    -lima                                  0.0323029              0.0103629      1.58023
    -serpy                                 0.0767255              0.0402741      4.33337
    -Strainer                              0.111886               0.0480838      5.92485
    -Toasted Marshmallow                   0.147332               0.0805259      8.43926
    -Colander                              0.460081               0.237314      25.8297
    -Lollipop                              0.744028               0.349707      40.5091
    -kim                                   1.4407                 0.691975      78.9887
    -Marshmallow                           1.7112                 0.871818      95.6683
    -Django REST Framework                 1.62452                1.11424      101.437
    +Custom                                0.0134363              0.00623655     1
    +lima                                  0.0156646              0.00784755     1.19515
    +serpy                                 0.0415354              0.0215726      3.20787
    +Strainer                              0.0664504              0.0329065      5.05045
    +Toasted Marshmallow                   0.0995898              0.0533848      7.77592
    +Colander                              0.264328               0.129063      19.9966
    +Lollipop                              0.363104               0.173901      27.2967
    +Marshmallow                           0.520532               0.269906      40.1791
    +Avro                                  0.529453               0.267131      40.4915
    +kim                                   0.74872                0.369864      56.8592
    +Django REST Framework                 0.902153               0.646744      78.7326
     

    The Benchmark

    From d918abb849e6c953f6a88dddd18473265662b5c0 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sun, 7 Jul 2019 17:11:36 +0000 Subject: [PATCH 27/32] Deploy to GitHub Pages: 632dd64e1b07462050d61728f8e236b64edf314e --- index.html | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/index.html b/index.html index 4b9990a..50f0a52 100644 --- a/index.html +++ b/index.html @@ -34,17 +34,17 @@

    Running the test suite

    Library                  Many Objects (seconds)    One Object (seconds)    Relative
     ---------------------  ------------------------  ----------------------  ----------
    -Custom                                0.0134363              0.00623655     1
    -lima                                  0.0156646              0.00784755     1.19515
    -serpy                                 0.0415354              0.0215726      3.20787
    -Strainer                              0.0664504              0.0329065      5.05045
    -Toasted Marshmallow                   0.0995898              0.0533848      7.77592
    -Colander                              0.264328               0.129063      19.9966
    -Lollipop                              0.363104               0.173901      27.2967
    -Marshmallow                           0.520532               0.269906      40.1791
    -Avro                                  0.529453               0.267131      40.4915
    -kim                                   0.74872                0.369864      56.8592
    -Django REST Framework                 0.902153               0.646744      78.7326
    +Custom                                0.01247                0.00598454     1
    +lima                                  0.0176778              0.00955582     1.47571
    +serpy                                 0.0408196              0.0216684      3.38605
    +Strainer                              0.0658422              0.0328884      5.34993
    +Toasted Marshmallow                   0.106558               0.0605462      9.05488
    +Colander                              0.259306               0.127832      20.9779
    +Lollipop                              0.361919               0.171774      28.9193
    +Avro                                  0.558331               0.262144      44.4592
    +Marshmallow                           0.557178               0.276278      45.1626
    +kim                                   0.777472               0.397107      63.6472
    +Django REST Framework                 0.971534               0.728644      92.1278
     

    The Benchmark

    From 201a8ef08eafca05e786ff24a08e10d739b19506 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sun, 7 Jul 2019 17:14:57 +0000 Subject: [PATCH 28/32] Deploy to GitHub Pages: 1a93546aa72707b18ccdab136a19b71b9f27a87f --- index.html | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/index.html b/index.html index 50f0a52..7ed6c8b 100644 --- a/index.html +++ b/index.html @@ -34,17 +34,18 @@

    Running the test suite

    Library                  Many Objects (seconds)    One Object (seconds)    Relative
     ---------------------  ------------------------  ----------------------  ----------
    -Custom                                0.01247                0.00598454     1
    -lima                                  0.0176778              0.00955582     1.47571
    -serpy                                 0.0408196              0.0216684      3.38605
    -Strainer                              0.0658422              0.0328884      5.34993
    -Toasted Marshmallow                   0.106558               0.0605462      9.05488
    -Colander                              0.259306               0.127832      20.9779
    -Lollipop                              0.361919               0.171774      28.9193
    -Avro                                  0.558331               0.262144      44.4592
    -Marshmallow                           0.557178               0.276278      45.1626
    -kim                                   0.777472               0.397107      63.6472
    -Django REST Framework                 0.971534               0.728644      92.1278
    +Custom                                0.012332               0.00598311     1
    +lima                                  0.0161235              0.00804472     1.31958
    +Pickle                                0.021558               0.0217698      2.36569
    +serpy                                 0.04213                0.0218706      3.49442
    +Strainer                              0.0674126              0.0334911      5.50933
    +Toasted Marshmallow                   0.101972               0.0549827      8.5697
    +Colander                              0.259778               0.128447      21.197
    +Lollipop                              0.370258               0.180135      30.0514
    +Avro                                  0.524337               0.262554      42.9641
    +Marshmallow                           0.551328               0.275338      45.1358
    +kim                                   0.816756               0.384658      65.597
    +Django REST Framework                 0.963721               0.74473       93.2811
     

    The Benchmark

    From 786f24ac52a71b4a6ac534cc72a58107236b5657 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Fri, 24 Jan 2020 07:09:08 +0000 Subject: [PATCH 29/32] Deploy to GitHub Pages: ee599b910432b5042e6b8c7aed5da7eee71a12de --- index.html | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/index.html b/index.html index 7ed6c8b..e39c82f 100644 --- a/index.html +++ b/index.html @@ -34,18 +34,18 @@

    Running the test suite

    Library                  Many Objects (seconds)    One Object (seconds)    Relative
     ---------------------  ------------------------  ----------------------  ----------
    -Custom                                0.012332               0.00598311     1
    -lima                                  0.0161235              0.00804472     1.31958
    -Pickle                                0.021558               0.0217698      2.36569
    -serpy                                 0.04213                0.0218706      3.49442
    -Strainer                              0.0674126              0.0334911      5.50933
    -Toasted Marshmallow                   0.101972               0.0549827      8.5697
    -Colander                              0.259778               0.128447      21.197
    -Lollipop                              0.370258               0.180135      30.0514
    -Avro                                  0.524337               0.262554      42.9641
    -Marshmallow                           0.551328               0.275338      45.1358
    -kim                                   0.816756               0.384658      65.597
    -Django REST Framework                 0.963721               0.74473       93.2811
    +Custom                                0.0104711              0.00514102     1
    +lima                                  0.012804               0.00634384     1.22647
    +Pickle                                0.0183399              0.0178602      2.31871
    +serpy                                 0.0329423              0.0175877      3.23658
    +Strainer                              0.0532405              0.0266149      5.11496
    +Toasted Marshmallow                   0.0841787              0.0451415      8.28331
    +Colander                              0.217609               0.106181      20.7397
    +Lollipop                              0.299593               0.142388      28.3101
    +Avro                                  0.423823               0.211522      40.6956
    +Marshmallow                           0.457737               0.238069      44.5683
    +kim                                   0.65399                0.32078       62.4367
    +Django REST Framework                 0.784377               0.587458      87.8698
     

    The Benchmark

    From df14f2881b0bc3c57e67049319c15b37f1e63261 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Mon, 27 Apr 2020 15:41:17 +0000 Subject: [PATCH 30/32] Deploy to GitHub Pages: 6cbba2c05842b39304906e1e91458f9894c067fb --- index.html | 68 +++++++++++++++++++++++++++++++++++++++--------------- 1 file changed, 49 insertions(+), 19 deletions(-) diff --git a/index.html b/index.html index e39c82f..478f5a3 100644 --- a/index.html +++ b/index.html @@ -9,14 +9,16 @@

    Python Serialization Benchmark

    You can find the latest benchmarks on this page.

    Currently the following projects are benchmarked.

    Along with a baseline custom function that doesn't use a framework.

    Running the test suite

    @@ -34,18 +36,18 @@

    Running the test suite

    Library                  Many Objects (seconds)    One Object (seconds)    Relative
     ---------------------  ------------------------  ----------------------  ----------
    -Custom                                0.0104711              0.00514102     1
    -lima                                  0.012804               0.00634384     1.22647
    -Pickle                                0.0183399              0.0178602      2.31871
    -serpy                                 0.0329423              0.0175877      3.23658
    -Strainer                              0.0532405              0.0266149      5.11496
    -Toasted Marshmallow                   0.0841787              0.0451415      8.28331
    -Colander                              0.217609               0.106181      20.7397
    -Lollipop                              0.299593               0.142388      28.3101
    -Avro                                  0.423823               0.211522      40.6956
    -Marshmallow                           0.457737               0.238069      44.5683
    -kim                                   0.65399                0.32078       62.4367
    -Django REST Framework                 0.784377               0.587458      87.8698
    +Custom                                0.0106766              0.00519919     1
    +lima                                  0.0125217              0.00629926     1.18551
    +Pickle                                0.0173957              0.0172369      2.18147
    +serpy                                 0.0332184              0.0176816      3.20613
    +Strainer                              0.0534034              0.0266812      5.04444
    +Toasted Marshmallow                   0.0825396              0.0447464      8.0176
    +Colander                              0.215784               0.105959      20.2662
    +Lollipop                              0.301132               0.143556      28.0104
    +Avro                                  0.413466               0.207327      39.1031
    +Marshmallow                           0.446715               0.22695       42.4334
    +kim                                   0.629416               0.311557      59.2709
    +Django REST Framework                 0.781569               0.577704      85.6191
     

    The Benchmark

    @@ -99,7 +101,7 @@

    Discussion

    No - marshmallow + Marshmallow Yes Yes Yes @@ -113,19 +115,47 @@

    Discussion

    Yes - strainer + Strainer Yes - Yes + No Yes Yes - kim + Kim Yes No Yes Yes + + Toasted Marshmallow + Yes + Yes + Yes + Yes + + + Colander + Yes + No + Yes< + Yes + + + Lima + Yes + No + No + No + + + Avro + Yes + Yes + Yes + No + From e06ecba9114ce9663689603c2aae01166c9061ad Mon Sep 17 00:00:00 2001 From: Travis CI Date: Tue, 5 Jan 2021 04:20:52 +0000 Subject: [PATCH 31/32] Deploy to GitHub Pages: d8452fa880756746f1fe874aa24953dda7af01a0 --- index.html | 37 ++++++++++++++++++++++--------------- 1 file changed, 22 insertions(+), 15 deletions(-) diff --git a/index.html b/index.html index 478f5a3..51a14c6 100644 --- a/index.html +++ b/index.html @@ -18,6 +18,7 @@

    Python Serialization Benchmark

  • Toasted Marshmallow
  • Colander
  • Lima
  • +
  • Serpyco
  • Avro
  • Along with a baseline custom function that doesn't use a framework.

    @@ -36,24 +37,24 @@

    Running the test suite

    Library                  Many Objects (seconds)    One Object (seconds)    Relative
     ---------------------  ------------------------  ----------------------  ----------
    -Custom                                0.0106766              0.00519919     1
    -lima                                  0.0125217              0.00629926     1.18551
    -Pickle                                0.0173957              0.0172369      2.18147
    -serpy                                 0.0332184              0.0176816      3.20613
    -Strainer                              0.0534034              0.0266812      5.04444
    -Toasted Marshmallow                   0.0825396              0.0447464      8.0176
    -Colander                              0.215784               0.105959      20.2662
    -Lollipop                              0.301132               0.143556      28.0104
    -Avro                                  0.413466               0.207327      39.1031
    -Marshmallow                           0.446715               0.22695       42.4334
    -kim                                   0.629416               0.311557      59.2709
    -Django REST Framework                 0.781569               0.577704      85.6191
    +serpyco                              0.00796366              0.00406694     1
    +Custom                               0.00985813              0.00479531     1.21801
    +lima                                 0.0123692               0.00617647     1.54154
    +Pickle                               0.0181735               0.0181575      3.01988
    +serpy                                0.0357647               0.0186381      4.52204
    +Strainer                             0.0541008               0.026659       6.71286
    +Toasted Marshmallow                  0.0879436               0.0476737     11.2727
    +Colander                             0.230517                0.114572      28.6843
    +Lollipop                             0.32575                 0.156234      40.0632
    +Avro                                 0.442604                0.219167      55.0073
    +Marshmallow                          0.477782                0.258027      61.1615
    +kim                                  0.616711                0.307592      76.8293
    +Django REST Framework                0.779191                0.535238     109.257
     
    -

    The Benchmark

    Each framework is asked to serialize a list of 2 objects a 1000 times, and then 1 object a 1000 times.

    This is the current object that is being serialized.

    -
    class ChildTestObject(object):
    +
    class ChildTestObject(object):
         def __init__(self, multiplier=None):
             self.w = 1000 * multiplier if multiplier else 100
             self.x = 20 * multiplier if multiplier else 20
    @@ -72,7 +73,6 @@ 

    The Benchmark

    benchmark_object = ParentTestObject()
    -

    Discussion

    Serialization from python objects to JSON, XML, or other transmission formats is a common task for many web related projects. In order to fill that need a number of frameworks have arised. While their aims are similar, they don't all share the same attributes. Here are how some of the features comapre.

    @@ -128,6 +128,13 @@

    Discussion

    + + + + + + + From 42c85bcc4f9cfd32fe238a1a76917b77d92d6c76 Mon Sep 17 00:00:00 2001 From: Travis CI Date: Sun, 7 Feb 2021 22:49:20 +0000 Subject: [PATCH 32/32] Deploy to GitHub Pages: b45cb024a553e78a81e1a8c5a3056b7b9100baab --- index.html | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/index.html b/index.html index 51a14c6..ef32fb9 100644 --- a/index.html +++ b/index.html @@ -37,19 +37,19 @@

    Running the test suite

    Library                  Many Objects (seconds)    One Object (seconds)    Relative
     ---------------------  ------------------------  ----------------------  ----------
    -serpyco                              0.00796366              0.00406694     1
    -Custom                               0.00985813              0.00479531     1.21801
    -lima                                 0.0123692               0.00617647     1.54154
    -Pickle                               0.0181735               0.0181575      3.01988
    -serpy                                0.0357647               0.0186381      4.52204
    -Strainer                             0.0541008               0.026659       6.71286
    -Toasted Marshmallow                  0.0879436               0.0476737     11.2727
    -Colander                             0.230517                0.114572      28.6843
    -Lollipop                             0.32575                 0.156234      40.0632
    -Avro                                 0.442604                0.219167      55.0073
    -Marshmallow                          0.477782                0.258027      61.1615
    -kim                                  0.616711                0.307592      76.8293
    -Django REST Framework                0.779191                0.535238     109.257
    +serpyco                              0.00796103              0.00404453     1
    +Custom                               0.009902                0.00483012     1.22711
    +lima                                 0.012424                0.00625205     1.55562
    +Pickle                               0.0180094               0.0179398      2.99438
    +serpy                                0.0356748               0.0189779      4.55228
    +Strainer                             0.0529356               0.0261641      6.58858
    +Toasted Marshmallow                  0.0865085               0.0465157     11.0802
    +Colander                             0.238111                0.116309      29.5214
    +Lollipop                             0.32454                 0.156491      40.0673
    +Avro                                 0.442609                0.220602      55.2419
    +Marshmallow                          0.496984                0.242603      61.6036
    +kim                                  0.616623                0.307922      77.0097
    +Django REST Framework                0.761326                0.527056     107.315
     

    The Benchmark

    Each framework is asked to serialize a list of 2 objects a 1000 times, and then 1 object a 1000 times.

    Yes Yes
    serpycoYesYesYesYes
    Toasted Marshmallow Yes