NVIDIA
NVIDIA
Jasper for PyTorch
Resource
NVIDIA
NVIDIA
Jasper for PyTorch

The Jasper model is an end-to-end neural acoustic model for automatic speech recognition (ASR).

The performance measurements in this document were conducted at the time of publication and may not reflect the performance achieved from NVIDIA's latest software release. For the most up-to-date performance measurements, go to NVIDIA Data Center Deep Learning Product Performance.

Benchmarking

The following section shows how to run benchmarks measuring the model performance in training and inference modes.

Training performance benchmark

To benchmark the training performance in a specific setting on the train-clean-100 subset of LibriSpeech, run:

BATCH_SIZE_SEQ=<BATCH_SIZES> NUM_GPUS_SEQ=<NUMS_OF_GPUS> bash scripts/train_benchmark.sh

By default, this script runs 2 epochs on the configuration configs/jasper10x5dr_speedp-online_train-benchmark.yaml, which applies gentle speed perturbation that does not change the length of the output, enabling immediate stabilization of training step times in the cuDNN benchmark mode. The script runs benchmarks on batch sizes 32 on 1, 4, and 8 GPUs, and requires a 8x 32GB GPU machine.

Inference performance benchmark

To benchmark the inference performance on a specific batch size and audio length, run:

BATCH_SIZE_SEQ=<BATCH_SIZES> MAX_DURATION_SEQ=<DURATIONS> bash scripts/inference_benchmark.sh

By default, the script runs on a single GPU and evaluates on the dataset limited to utterances shorter than MAX_DURATION. It uses the model configuration configs/jasper10x5dr_speedp-online_speca.yaml.

Results

The following sections provide details on how we achieved our performance and accuracy in training and inference. All results are trained on 960 hours of LibriSpeech with a maximum audio length of 16.7s. The training is evaluated on LibriSpeech dev-clean, dev-other, test-clean, test-other. Checkpoints for evaluation are being chosen based on their word error rate on dev-clean.

Training accuracy results

Training accuracy: NVIDIA DGX A100 (8x A100 80GB)

Our results were obtained by running the scripts/train.sh training script in the PyTorch 20.10-py3 NGC container with NVIDIA DGX A100 with (8x A100 80GB) GPUs. The following table reports the word error rate (WER) of the acoustic model with greedy decoding on all LibriSpeech dev and test datasets for mixed precision training.

Number of GPUsBatch size per GPUPrecisiondev-clean WERdev-other WERtest-clean WERtest-other WERTime to train
864mixed3.209.783.419.7170 h
Training accuracy: NVIDIA DGX-1 (8x V100 32GB)

Our results were obtained by running the scripts/train.sh training script in the PyTorch 20.10-py3 NGC container with NVIDIA DGX-1 with (8x V100 32GB) GPUs. The following table reports the word error rate (WER) of the acoustic model with greedy decoding on all LibriSpeech dev and test datasets for mixed precision training.

Number of GPUsBatch size per GPUPrecisiondev-clean WERdev-other WERtest-clean WERtest-other WERTime to train
864mixed3.2610.003.549.80130 h

We show the best of 5 runs (mixed precision) and 2 runs (FP32) chosen based on dev-clean WER. For FP32, two gradient accumulation steps have been used.

Training stability test

The following table compares greedy decoding word error rates across 8 different training runs with different seeds for mixed precision training.

DGX A100 80GB, FP16, 8x GPUSeed #1Seed #2Seed #3Seed #4Seed #5Seed #6Seed #7Seed #8MeanStd
dev-clean3.463.553.453.443.253.343.203.403.390.11
dev-other10.3010.7710.3610.269.9910.189.7810.3210.250.27
test-clean3.843.813.663.643.583.553.413.733.650.13
test-other10.6110.5210.4910.479.8910.099.7110.2610.260.31
DGX-1 32GB, FP16, 8x GPUSeed #1Seed #2Seed #3Seed #4Seed #5Seed #6Seed #7Seed #8MeanStd
dev-clean3.313.313.263.443.403.353.363.283.340.06
dev-other10.0210.0110.0010.0610.0510.0310.1010.0410.040.03
test-clean3.493.503.543.613.573.583.483.513.540.04
test-other10.1110.149.8010.0910.179.999.8610.0010.020.13

Training performance results

Our results were obtained by running the scripts/train.sh training script in the PyTorch 20.10-py3 NGC container. Performance (in sequences per second) is the steady-state throughput.

Training performance: NVIDIA DGX A100 (8x A100 80GB)
Batch size / GPUGPUsThroughput - TF32Throughput - mixed precisionThroughput speedup (TF32 to mixed precision)Weak scaling - TF32Weak scaling - mixed precision
32142.1864.321.521.001.00
324157.49239.231.523.733.72
328310.10470.091.527.357.31
64149.6475.591.521.001.00
644192.66289.161.503.883.83
648371.41547.911.487.487.25

Note: Mixed precision permits higher batch sizes during training. We report the maximum batch sizes (as powers of 2), which are allowed without gradient accumulation.

To achieve these same results, follow the Quick Start Guide outlined above.

Training performance: NVIDIA DGX-1 (8x V100 16GB)
Batch size / GPUGPUsThroughput - FP32Throughput - mixed precisionThroughput speedup (FP32 to mixed precision)Weak scaling - FP32Weak scaling - mixed precision
16110.7127.872.601.001.00
16440.2899.802.483.763.58
16878.23193.892.487.306.96

Note: Mixed precision permits higher batch sizes during training. We report the maximum batch sizes (as powers of 2), which are allowed without gradient accumulation.

To achieve these same results, follow the Quick Start Guide outlined above.

Training performance: NVIDIA DGX-1 (8x V100 32GB)
Batch size / GPUGPUsThroughput - FP32Throughput - mixed precisionThroughput speedup (FP32 to mixed precision)Weak scaling - FP32Weak scaling - mixed precision
32112.2234.082.791.001.00
32446.97128.392.733.843.77
32892.44249.002.697.577.31
641N/A39.30N/AN/A1.00
644N/A150.18N/AN/A3.82
648N/A282.68N/AN/A7.19

Note: Mixed precision permits higher batch sizes during training. We report the maximum batch sizes (as powers of 2), which are allowed without gradient accumulation.

To achieve these same results, follow the Quick Start Guide outlined above.

Training performance: NVIDIA DGX-2 (16x V100 32GB)
Batch size / GPUGPUsThroughput - FP32Throughput - mixed precisionThroughput speedup (FP32 to mixed precision)Weak scaling - FP32Weak scaling - mixed precision
32113.4638.942.891.001.00
32451.38143.442.793.823.68
328100.54280.482.797.477.20
3216188.14515.902.7413.9813.25
641N/A43.86N/AN/A1.00
644N/A165.27N/AN/A3.77
648N/A318.10N/AN/A7.25
6416N/A567.47N/AN/A12.94

Note: Mixed precision permits higher batch sizes during training. We report the maximum batch sizes (as powers of 2), which are allowed without gradient accumulation.

To achieve these same results, follow the Quick Start Guide outlined above.

Inference performance results

Our results were obtained by running the scripts/inference_benchmark.sh script in the PyTorch 20.10-py3 NGC container on NVIDIA DGX A100, DGX-1, DGX-2 and T4 on a single GPU. Performance numbers (latency in milliseconds per batch) were averaged over 500 iterations.

Inference performance: NVIDIA DGX A100 (1x A100 80GB)
FP16 Latency (ms) PercentilesTF32 Latency (ms) PercentilesFP16/TF32 speed up
BSDuration (s)90%95%99%Avg90%95%99%AvgAvg
12.032.4032.5032.8232.3033.3033.6434.6533.251.03
22.032.9033.5134.3532.6934.4834.6535.6634.271.05
42.032.8533.0133.8932.6034.0934.4635.2234.001.04
82.035.5135.8937.1035.3334.8635.3636.0834.450.98
162.036.0036.5737.4035.7743.8344.1244.7743.391.21
17.033.5033.9934.9133.0333.8334.2534.9533.701.02
27.034.4334.8935.7234.2234.4134.7335.6934.281.00
47.034.3034.5935.4334.0737.9538.1838.8737.551.10
87.035.9836.2837.1135.2844.6444.7945.3744.291.26
167.039.8640.0841.1639.3355.1755.4657.2454.561.39
116.735.2035.8038.7134.3635.3635.7636.5534.641.01
216.735.4035.8136.5034.7636.3436.5337.4035.871.03
416.736.0136.3837.3735.5744.6945.0945.8843.921.23
816.741.4841.7844.2240.6958.5758.7459.6258.111.43
1616.761.3761.9366.3260.9297.3397.71100.0496.561.59

To achieve these same results, follow the Quick Start Guide outlined above.

Inference performance: NVIDIA DGX-1 (1x V100 16GB)
FP16 Latency (ms) PercentilesFP32 Latency (ms) PercentilesFP16/FP32 speed up
BSDuration (s)90%95%99%Avg90%95%99%AvgAvg
12.045.4245.6249.5445.0248.8348.9951.6648.441.08
22.050.3150.5353.6649.1049.8750.0452.9949.411.01
42.049.1749.4852.1348.7352.9253.2155.2852.311.07
82.051.2051.4052.3249.0173.0273.3075.0071.991.47
162.051.7552.2456.3651.2783.9984.5786.6983.241.62
17.048.1348.5350.9546.7848.5248.7550.8948.011.03
27.049.5250.1052.3548.0065.2765.4166.5964.791.35
47.051.7552.0154.3950.3893.7594.7797.0492.271.83
87.054.8056.2766.2352.95130.65131.09132.91129.822.45
167.073.0273.4275.8371.96157.53158.20160.73155.512.16
116.748.1048.5252.7147.2073.3473.5674.1972.691.54
216.764.2164.5265.5656.06129.48129.97131.78126.362.25
416.760.3861.0363.1858.87183.33183.85185.53181.903.09
816.785.8886.3487.7084.46227.42228.21229.63225.712.67
1616.7135.62136.40137.69131.58276.90277.59281.16275.082.09

To achieve these same results, follow the Quick Start Guide outlined above.

Inference performance: NVIDIA DGX-1 (1x V100 32GB)
FP16 Latency (ms) PercentilesFP32 Latency (ms) PercentilesFP16/FP32 speed up
BSDuration (s)90%95%99%Avg90%95%99%AvgAvg
12.052.7453.0154.4051.4755.9756.2257.9354.931.07
22.051.7752.1554.6950.9856.5856.8758.8855.351.09
42.051.4151.7653.4750.5561.5661.8763.8160.741.20
82.051.8352.1554.0850.8580.2080.6981.6777.691.53
162.070.4870.9672.1162.9893.0093.4494.1789.051.41
17.049.7750.2151.8848.7352.7452.9954.5451.671.06
27.051.1251.4752.8449.9865.3365.6367.0764.641.29
47.053.1353.5655.6852.1593.5493.8594.7292.761.78
87.057.6758.0759.8956.41133.93134.18134.88133.152.36
167.076.0976.4879.1375.27162.35162.77164.63161.302.14
116.754.7855.2956.8352.5175.3776.2778.0574.321.42
216.756.8057.2059.0155.49130.60131.36132.93128.552.32
416.764.1964.8466.4762.87188.09188.76190.07185.762.95
816.787.4687.8689.9986.47232.33232.89234.43230.442.67
1616.7136.02136.52139.44134.78283.87284.59286.70282.012.09

To achieve these same results, follow the Quick Start Guide outlined above.

Inference performance: NVIDIA DGX-2 (1x V100 32GB)
FP16 Latency (ms) PercentilesFP32 Latency (ms) PercentilesFP16/FP32 speed up
BSDuration (s)90%95%99%Avg90%95%99%AvgAvg
12.035.8836.1239.8035.2042.9543.6746.6542.231.20
22.036.3636.5740.9735.6041.8342.2145.6040.971.15
42.036.6936.8941.2536.0548.3548.5252.3547.801.33
82.037.4937.7041.3736.8865.4165.6466.5064.961.76
162.041.3541.7945.5840.9177.2277.5179.4876.541.87
17.036.0736.5540.3135.6239.5239.8443.0738.931.09
27.037.4237.6641.3636.7955.9456.1958.3355.601.51
47.038.5138.9542.5537.9886.6287.0887.5086.202.27
87.042.8243.0047.1142.55122.05122.29122.70121.592.86
167.067.7467.9269.0565.69149.92150.16151.03149.492.28
116.739.2839.7843.3438.3566.7367.1669.8066.011.72
216.743.0543.4247.1842.43120.04121.12123.32118.142.78
416.752.1852.4956.1151.63176.09176.51178.70174.603.38
816.778.5578.7981.6678.04216.19216.68217.63214.482.75
1616.7125.57125.92128.78124.33264.11264.49266.14262.802.11

To achieve these same results, follow the Quick Start Guide outlined above.

Inference performance: NVIDIA T4
FP16 Latency (ms) PercentilesFP32 Latency (ms) PercentilesFP16/FP32 speed up
BSDuration (s)90%95%99%Avg90%95%99%AvgAvg
12.043.6246.9550.4637.2351.3152.3756.2149.771.34
22.049.0950.4653.1140.6181.8582.2283.9480.811.99
42.047.7151.1455.0941.29112.56115.13118.56111.602.70
82.051.3753.1155.4845.94198.95199.48200.28197.224.29
162.063.5964.3066.9061.77221.75222.07223.22220.093.56
17.047.4948.6653.3640.7673.6374.4177.6572.411.78
27.048.6350.0158.3543.44114.66115.28117.63112.412.59
47.052.1952.8554.2249.94200.38201.29202.97197.213.95
87.084.9085.5687.5283.41404.00404.72405.70400.254.80
167.0157.12157.58159.19155.01490.93492.09493.44486.453.14
116.750.5751.5757.5846.27150.39151.84153.54147.313.18
216.763.6464.5566.3161.98256.54258.16262.71250.344.04
416.7140.44141.06142.00138.14519.59521.41523.86512.743.71
816.7267.03268.06270.01263.15727.33728.61731.36722.622.75
1616.7362.40364.02367.80358.75867.92869.19871.46860.372.40

To achieve these same results, follow the Quick Start Guide outlined above.

NVIDIA uses cookies to improve your experience on our web site. We and our third-party partners also use cookies and other tools to collect and record information you provide as well as information about your interactions with our websites for performance improvement, analytics, and to assist in marketing efforts. By clicking "Accept All", you consent to our use of cookies and other tools as described in our Cookie Policy. You can manage your cookie settings by clicking on "Manage Settings." By continuing to use this site or by clicking one of the buttons below, you agree to our Terms of Service (which contains important waivers). Please see our Privacy Policy for more information on our privacy practices.