k-nucleotide benchmark N=10,000

Each chart bar shows how many times slower, one ↓ k-nucleotide program was, compared to the fastest program.

These are not the only programs that could be written. These are not the only compilers and interpreters. These are not the only programming languages.

Column × shows how many times more each program used compared to the benchmark program that used least.

    sort sortsort
  ×   Program Source Code CPU secs Elapsed secs Memory KB Code B ≈ CPU Load
1.0Shedskin 0.060.05?593  0% 20% 0% 100%
1.0Shedskin 0.060.05?593  0% 40% 67% 20%
1.0Shedskin 0.060.05?593  0% 0% 0% 100%
1.1PyPy 2 0.050.05?593  0% 100% 0% 17%
1.3PyPy 2 0.060.07?593  14% 50% 0% 100%
1.5Python 2 0.070.08?593  0% 100% 0% 0%
1.6Python 2 0.080.08?593  0% 11% 100% 0%
1.7PyPy 3 0.080.08?594  89% 0% 0% 11%
1.7PyPy 3 0.080.08?594  29% 100% 13% 0%
1.8Cython 0.090.09?618  0% 0% 10% 100%
1.8Cython 0.090.09?618  0% 0% 100% 0%
1.8Cython 0.090.09?618  0% 100% 10% 10%
1.9Python 2 0.090.09?593  0% 10% 0% 89%
2.0Pyston 0.100.10?593  100% 0% 0% 0%
2.0Pyston 0.100.10?593  22% 9% 80% 10%
2.2Nuitka 0.110.11?594  0% 0% 92% 0%
2.2Nuitka 0.110.11?594  8% 0% 9% 100%
2.2Nuitka 0.110.11?594  0% 9% 0% 100%
2.3Python 3 0.110.11?594  0% 100% 9% 0%
2.3Python 3 0.110.12?594  100% 0% 15% 8%
2.4Python 3 0.120.12?594  9% 0% 15% 100%
2.5Python development version 0.120.12?594  0% 0% 100% 0%
2.5Python development version 0.120.12?594  8% 0% 100% 8%
2.5Pyston 0.120.12?593  0% 0% 0% 92%
2.9Python 2 #8 0.180.14?777  29% 50% 21% 21%
2.9Python 2 #8 0.190.14?777  27% 27% 29% 43%
3.1Python development version 0.150.15?594  25% 80% 0% 0%
3.1Python 2 #8 0.210.15?777  36% 40% 27% 31%
3.2Python 2 #2 0.080.16?801  24% 19% 38% 13%
3.3Python 3 #8 0.240.16?777  27% 29% 29% 63%
3.3Python 2 #2 0.090.16?801  13% 13% 22% 44%
3.4Python 3 #8 0.250.17?777  39% 63% 29% 20%
3.4Python development version #3 0.220.17?2011  24% 19% 56% 29%
3.4Python 2 #2 0.090.17?801  6% 31% 12% 6%
3.4Python development version #8 0.290.17?777  39% 41% 76% 35%
3.4Python 3 #8 0.250.17?777  63% 28% 38% 29%
3.4Python 3 #3 0.200.17?2011  24% 44% 24% 44%
3.5Nuitka #8 0.230.17?777  28% 28% 24% 65%
3.5Python development version #8 0.290.17?777  47% 44% 67% 31%
3.6Nuitka #3 0.200.18?2011  56% 21% 22% 17%
3.7Nuitka #2 0.110.18?801  29% 5% 6% 18%
3.7Python 3 #2 0.130.18?801  15% 39% 0% 24%
3.7Python development version #3 0.230.18?2011  26% 61% 26% 22%
3.7Nuitka #8 0.240.18?777  28% 68% 22% 28%
3.7Python 3 #3 0.210.18?2011  17% 61% 18% 21%
3.7Nuitka #3 0.210.18?2011  21% 26% 22% 58%
3.8Python development version #8 0.300.19?777  32% 32% 65% 39%
3.9Nuitka #8 0.250.19?777  68% 17% 22% 22%
3.9Python 3 #2 0.140.19?801  5% 53% 5% 16%
3.9Cython #2 0.110.19?801  6% 5% 33% 17%
3.9PyPy 2 #8 0.190.19?777  20% 16% 20% 53%
3.9Nuitka #3 0.220.19?2011  16% 25% 47% 35%
3.9Cython #2 0.120.19?801  37% 15% 11% 12%
4.0Python 3 #2 0.140.19?801  11% 20% 42% 30%
4.0Python development version #3 0.240.19?2011  65% 22% 28% 38%
4.0Python 3 #3 0.230.20?2011  30% 17% 55% 21%
4.0PyPy 2 #2 0.140.20?801  11% 15% 50% 20%
4.1Nuitka #2 0.130.20?801  5% 42% 10% 15%
4.1Cython #2 0.150.20?801  55% 22% 25% 15%
4.1PyPy 2 #8 0.200.20?777  19% 23% 15% 52%
4.3Python development version #2 0.140.21?801  38% 48% 50% 43%
4.3Python development version #2 0.110.214801  19% 45% 14% 27%
4.4Nuitka #2 0.130.221,756801  14% 18% 38% 9%
4.5PyPy 2 #2 0.160.22?801  32% 55% 36% 32%
4.5PyPy 2 #2 0.150.221,388801  54% 33% 38% 32%
4.6PyPy 2 #8 0.210.221,408777  14% 19% 22% 54%
4.6Python development version #2 0.160.22832801  5% 18% 14% 45%
5.0Pyston #8 0.270.24116,440777  67% 16% 17% 17%
5.0Pyston #8 0.280.25117,132777  69% 16% 13% 13%
5.1PyPy 3 #3 0.320.25201,3482011  63% 27% 21% 33%
5.2Pyston #2 0.190.25125,780801  31% 16% 16% 58%
5.2Pyston #2 0.200.25123,824801  12% 12% 56% 12%
5.2PyPy 3 #2 0.240.26232,008801  27% 54% 12% 8%
5.2PyPy 3 #8 0.310.26211,252777  72% 19% 19% 23%
5.2Pyston #2 0.190.26128,384801  12% 15% 8% 58%
5.3PyPy 3 #3 0.330.26201,8882011  23% 16% 70% 19%
5.3PyPy 3 #3 0.330.26202,3882011  26% 22% 73% 19%
5.3PyPy 3 #8 0.310.26211,392777  15% 20% 73% 16%
5.5PyPy 3 #2 0.250.27230,488801  67% 12% 14% 18%
5.5PyPy 3 #2 0.260.27233,892801  17% 11% 18% 64%
5.6PyPy 2 0.110.274593  11% 41% 37% 15%
5.6PyPy 3 #8 0.310.28210,444777  15% 62% 26% 21%
5.7PyPy 3 0.140.284594  15% 30% 28% 52%
7.2Pyston #8 0.300.354777  21% 19% 63% 21%
32IronPython 1.131.5578,304593  3% 3% 52% 23%
32IronPython 1.151.5780,896593  56% 4% 16% 3%
32IronPython 1.201.5971,668593  34% 11% 3% 39%
33Jython 3.851.61188,480593  81% 45% 63% 59%
34Jython 3.951.66197,900593  66% 50% 61% 77%
37Jython 4.271.80198,752593  67% 70% 65% 68%
missing benchmark programs
Numba No program
MicroPython No program
Grumpy No program

 k-nucleotide benchmark : Hashtable update and k-nucleotide strings

diff program output for this 250KB input file (generated with the fasta program N = 25000) with this output file to check your program is correct before contributing.

We are trying to show the performance of various programming language implementations - so we ask that contributed programs not only give the correct result, but also use the same algorithm to calculate that result.

We use FASTA files generated by the fasta benchmark as input for this benchmark. Note: the file may include both lowercase and uppercase codes.

Each program should

In practice, less brute-force would be used to calculate k-nucleotide frequencies, for example Virus Classification using k-nucleotide Frequencies and A Fast Algorithm for the Exhaustive Analysis of 12-Nucleotide-Long DNA Sequences. Applications to Human Genomics (105KB pdf).

Revised BSD license

  Home   Conclusions   License   Play