Home

Awesome

Anakin2.0

Build Status License Coverage Status

Welcome to the Anakin GitHub.

Anakin is a cross-platform, high-performance inference engine, which is originally developed by Baidu engineers and is a large-scale application of industrial products.

Please refer to our release announcement to track the latest feature of Anakin.

Features

NV GPU Benchmark

Machine And Enviornment

CPU: Intel(R) Xeon(R) CPU 5117 @ 2.0GHz
GPU: Tesla P4
cuda: CUDA8
cuDNN: v7

The counterpart of Anakin is the acknowledged high performance inference engine NVIDIA TensorRT 5 , The models which TensorRT 5 doesn't support we use the custom plugins to support.

<span id = '1'> VGG16 </span>

Batch_SizeRT latency FP32(ms)Anakin2 Latency FP32 (ms)RT Memory (MB)Anakin2 Memory (MB)
18.525328.23871090.89702
214.120913.87721056.02768.76
424.452924.33911002.17840.54
846.795646.33091098.98935.61

<span id = '2'> Resnet50 </span>

Batch_SizeRT latency FP32(ms)Anakin2 Latency FP32 (ms)RT Latency INT8 (ms)Anakin2 Latency INT8 (ms)RT Memory FP32(MB)Anakin2 Memory FP32(MB)
14.64473.08631.788921.615371134.88311.25
26.691875.139952.711362.700221108.86382
411.19439.205134.167714.77145885.96406.86
819.876917.19766.27988.68197813.84532.61

<span id = '3'> Resnet101 </span>

Batch_SizeRT latency (ms)Anakin2 Latency (ms)RT Latency INT8 (ms)Anakin2 Latency INT8 (ms)RT Memory (MB)Anakin2 Memory (MB)
19.986955.449472.810312.743991159.16500.5
217.34898.856994.86414.694731158.73492
420.619816.82147.116088.453241021.68541.08
831.965333.501511.240315.4336914.49611.54

X86 CPU Benchmark

Machine And Enviornment

CPU: Intel(R) Xeon(R) CPU E5-2650 v4 @ 2.20GHz with HT, for FP32 test
CPU: Intel(R) Xeon(R) Gold 6271 CPU @ 2.60GHz with HT, for INT8 test
System: CentOS 6.3 with GCC 4.8.2, for benchmark between Anakin and Intel Caffe

The counterpart of Anakin is Intel Cafe(1.1.6) with mklml.

Net_NameBatch_SizeAnakin2 Latency(2650v4) fp32 (ms)caffe Latency(2650v4) fp32 (ms)Anakin2 Latency int8(6271) (ms)
resnet50120.620124.13693.20866
resnet50239.228643.10965.44311
resnet50477.139281.88149.93424
resnet508152.941158.32119.5618
vgg16155.613270.53215.3181
vgg16296.5034131.45122.5082
vgg164180.479247.92637.2974
vgg168346.619485.4467.6682
mobilenetv113.981045.427750.926546
mobilenetv127.270799.160581.35007
mobilenetv1414.402916.25052.37271
mobilenetv1829.165129.83813.75992
vgg16_ssd1125.948143.412
vgg16_ssd2247.242266.22
vgg16_ssd4488.377510.978
vgg16_ssd8972.762995.407
mobilenetv213.7850423.0066
mobilenetv227.2462265.9301
mobilenetv2413.763885.3893
mobilenetv2828.4093131.669

ARM CPU Benchmark

Machine And Enviornment

CPU: Kirin 980
CPU: Snapdragon 652
CPU: Snapdragon 855
CPU: RK3399

The counterpart of Anakin is ncnn(20190320). This benchmark we test ARMv7 ARMv8 splitly

ARMv8 TEST

Kirin 980Anakin fp32Anakin int8NCNN fp32NCNN int8
1 thread2 thread4 thread1 thread2 thread4 thread1 thread2 thread4 thread1 thread2 thread4 thread
mobilenet_v134.17219.36912.72337.58820.69213.28045.42024.22016.73050.56027.82020.010
mobilenet_v230.48917.78412.32729.58117.20815.30730.39017.31012.900
mobilenet_ssd71.60937.47728.95288.22070.07066.430103.70085.16085.320
resnet50255.748137.842104.6281299.480695.830498.010243.360131.10089.800
shufflenetv111.5448.9317.02712.8109.3908.030
shufflenetv211.6877.8995.32120.40211.5299.061
squeezenet28.58016.63814.435
googlenet93.91752.74240.301130.87572.52254.204


Snapdragon 855Anakin fp32Anakin int8NCNN fp32NCNN int8
1 thread2 thread4 thread1 thread2 thread4 thread1 thread2 thread4 thread1 thread2 thread4 thread
mobilenet_v132.01919.02410.49134.36320.29210.38237.11022.31013.52047.43028.35015.830
mobilenet_v228.53317.45510.43324.48715.1829.13325.06015.97011.250
mobilenet_ssd66.45441.39723.639101.56069.38043.930136.42091.01047.490
resnet50201.362132.13378.3001141.290724.090385.990229.020138.45082.060
shufflenetv110.1537.1015.32711.6108.0205.870
shufflenetv210.8686.7134.52617.30610.9876.788
squeezenet25.88016.1349.697
googlenet85.77454.51834.025118.12073.68641.865


Snapdragon 652Anakin fp32Anakin int8NCNN fp32NCNN int8
1 thread2 thread4 thread1 thread2 thread4 thread1 thread2 thread4 thread1 thread2 thread4 thread
mobilenet_v1109.99454.93733.17483.88743.63924.665123.320122.67065.100128.800154.370125.570
mobilenet_v280.71246.31430.87469.34043.59031.86489.92090.90055.320
mobilenet_ssd246.459121.684134.019248.190138.170142.350247.020145.080211.000
resnet50673.285346.287378.065880.940514.190533.760313.630
shufflenetv134.94826.63521.57139.95025.52020.180
shufflenetv235.53021.44016.43449.49829.11619.346
squeezenet87.03747.19228.663
googlenet268.023148.53395.624236.492131.51081.561


RK3399Anakin fp32Anakin int8NCNN fp32NCNN int8
1 thread2 thread4 thread1 thread2 thread4 thread1 thread2 thread4 thread1 thread2 thread4 thread
mobilenet_v1111.31760.00887.20145.693149.27091.200142.79086.140
mobilenet_v2105.76760.89979.06553.914118.53086.900
mobilenet_ssd232.923128.337268.900157.860256.560149.730
resnet50671.800369.3861029.300571.230569.250344.830
shufflenetv138.76125.971
shufflenetv236.22022.09551.87930.351
squeezenet98.48954.863
googlenet274.166159.429235.085133.044

ARMv7 TEST

Kirin 980Anakin fp32Anakin int8NCNN fp32NCNN int8
1 thread2 thread4 thread1 thread2 thread4 thread1 thread2 thread4 thread1 thread2 thread4 thread
mobilenet_v139.05119.81314.18439.02622.04814.25050.24026.85020.01092.90049.42037.160
mobilenet_v236.05219.55014.50732.65619.64115.73535.89020.73018.550
mobilenet_ssd83.47444.53033.11699.96053.16084.360180.00091.38068.140
resnet50291.478158.954129.4841412.37766.62560.760355.010189.18133.410
shufflenetv111.9099.7617.44116.03010.6608.120
shufflenetv211.7557.9836.28921.96814.1119.888
squeezenet30.14820.90817.084
googlenet108.21065.79858.630140.88679.91060.693


Snapdragon 855Anakin fp32Anakin int8NCNN fp32NCNN int8
1 thread2 thread4 thread1 thread2 thread4 thread1 thread2 thread4 thread1 thread2 thread4 thread
mobilenet_v134.01520.06411.41042.22221.53211.74641.15024.87018.42079.18048.47024.530
mobilenet_v230.74218.50711.35424.62815.1339.07930.06019.22015.520
mobilenet_ssd69.74944.01026.00085.03062.77048.940154.600138.70082.140
resnet50218.581146.50992.8991380.340996.410540.660324.720261.920126.270
shufflenetv111.0327.4305.36913.3909.2706.360
shufflenetv211.3727.1204.72819.39312.2787.719
squeezenet27.86017.53810.729
googlenet100.71969.50949.021127.98283.36950.275


Snapdragon 652Anakin fp32Anakin int8NCNN fp32NCNN int8
1 thread2 thread4 thread1 thread2 thread4 thread1 thread2 thread4 thread1 thread2 thread4 thread
mobilenet_v1121.98263.00437.32586.67245.72826.354130.740140.85081.810184.630192.730144.740
mobilenet_v289.11350.60935.29172.67945.88833.88794.520101.38065.570
mobilenet_ssd236.466132.29386.335270.630295.520174.280350.640286.420243.850
resnet50751.528405.433255.6992762.8901447.070883.730664.180369.020
shufflenetv136.88323.71815.14453.66033.45023.330
shufflenetv236.93326.35320.50753.24331.08321.550
squeezenet92.74851.93633.027
googlenet296.092179.542125.509242.505140.08389.646


RK3399Anakin fp32Anakin int8NCNN fp32NCNN int8
1 thread2 thread1 thread2 thread1 thread2 thread1 thread2 thread
mobilenet_v1116.98165.03387.76847.617155.83098.520201.800116.440
mobilenet_v2118.22970.56783.79055.413126.53090.930
mobilenet_ssd237.196134.508292.130183.650361.570200.370
resnet50725.582413.9952883.1201632.800702.660404.970
shufflenetv141.09427.353
shufflenetv237.66023.48953.55832.122
squeezenet104.51959.402
googlenet305.304190.897244.855142.493

Documentation

All you need is in Doc Index

We also provide English and Chinese tutorial documentation.

Ask Questions

You are welcome to submit questions and bug reports as Github Issues.

Copyright and License

Anakin is provided under the Apache-2.0 license.

Acknowledgement

Anakin refers to the following projects: