Performance

Runtime Summary

  • This table is generated by benchmark.py

  • The testing image the size = 128x 128 x 3. Here shows therun time performance per image within batch size = 1024 and batch size = 128 in each backend libraries

  • E.g. albumentations|Affine =0.059 (ms) means BA.Affine(library=”albumentations”) runs 1000/0.059 =16949.15 images per second

Average run time (ms) in batch size = 1024

Unnamed: 0

albumentations

imgaug

torchvision

keras

augly

mmcv

imagenet_c

custom

0

Affine

0.059

0.118

0.126

0.060

1

PiecewiseAffine

1.999

1.419

2

Cutout

0.073

0.137

0.090

3

Crop

0.113

0.074

4

RandomCrop

0.029

0.098

0.068

0.065

5

CenterCrop

0.029

0.074

6

RandomSizedCrop

0.030

0.087

7

RandomResizedCrop

0.038

0.080

8

Resize

0.037

0.095

0.089

0.081

0.066

9

CropAndPad

0.035

0.120

10

Rotate

0.043

0.133

0.082

0.299

0.086

0.068

11

Pad

0.117

0.087

0.081

0.065

12

Normalize

0.051

0.068

13

HorizontalFlip

0.031

0.083

0.078

0.074

0.069

14

VerticalFlip

0.035

0.081

0.078

0.058

0.075

15

ChannelShuffle

0.039

0.086

16

Lambda

0.037

0.082

0.086

0.081

17

Autocontrast

0.284

0.111

18

Blur

0.037

0.110

0.132

19

MedianBlur

0.098

0.148

20

Grayscale

0.127

0.081

0.086

21

Scale

0.081

0.103

22

RandomGrayscale

0.095

23

Equalize

0.044

0.124

0.106

24

Brightness

0.036

0.174

0.096

0.109

0.087

0.612

25

Contrast

0.043

0.165

0.116

0.094

0.144

26

Emboss

0.038

0.123

27

CLAHE

0.059

0.161

0.103

28

Invert

0.032

0.108

0.083

29

Posterize

0.111

30

Saturation

0.059

0.216

0.085

0.085

0.571

31

Sharpen

0.039

0.120

0.119

0.097

32

Solarize

0.036

0.109

0.079

33

PerspectiveTransform

0.149

0.148

34

CoarseDropout

0.036

0.131

35

OverlayText

0.269

0.250

36

JpegCompression

0.093

0.252

0.145

1.936

37

ColorJitter

0.068

0.226

0.148

38

Superpixels

1.727

2.293

39

GaussianNoise

0.132

0.205

40

ShotNoise

0.489

41

ImpulseNoise

0.437

0.311

42

GlassBlur

0.288

44.416

43

MotionBlur

0.045

0.187

3.973

44

GaussianBlur

0.041

0.117

0.187

0.177

45

Snow

0.062

1.561

46

Fog

0.055

0.464

0.246

47

ElasticTransform

1.439

0.222

4.029

48

Pixelization

0.114

0.137

49

RandomFlip

0.071

50

Rerange

0.078

51

RGB2Gray

0.125

52

AdjustGamma

0.071

53

SegRescale

0.070

54

PhotoMetricDistortion

0.097

55

ShiftScaleRotate

0.052

56

Perspective

0.058

57

RandomScale

0.042

58

LongestMaxSize

0.051

59

SmallestMaxSize

0.052

60

RandomRotate90

0.046

61

SafeRotate

0.072

62

CropNonEmptyMaskIfExists

0.053

63

RandomCropNearBBox

0.032

64

Transpose

0.037

65

RandomGamma

0.036

66

OpticalDistortion

0.056

67

GridDistortion

0.085

68

RandomGridShuffle

0.113

69

HueSaturationValue

0.047

70

PadIfNeeded

0.064

71

RGBShift

0.050

72

GaussNoise

0.173

73

ToGray

0.032

74

ToSepia

0.041

75

ImageCompression

0.095

76

ToFloat

0.040

77

FromFloat

0.033

78

RandomBrightnessContrast

0.043

79

RandomRain

0.057

80

RandomSunFlare

0.139

81

RandomShadow

0.050

82

RandomToneCurve

0.069

83

ChannelDropout

0.034

84

ISONoise

0.257

85

Downscale

0.034

86

MultiplicativeNoise

0.039

87

FancyPCA

0.154

88

MaskDropout

0.093

89

GridDropout

0.047

90

Add

0.112

91

AddElementwise

0.127

92

AddToHue

0.128

93

AddToHueAndSaturation

0.133

94

AddToSaturation

0.134

95

AdditiveLaplaceNoise

0.148

96

AdditivePoissonNoise

0.227

97

AffineCv2

0.105

98

AllChannelsCLAHE

0.151

99

AllChannelsHistogramEqualization

0.103

100

BilateralBlur

0.185

101

BlendAlpha

0.161

102

BlendAlphaCheckerboard

0.194

103

BlendAlphaElementwise

0.185

104

BlendAlphaFrequencyNoise

0.376

105

BlendAlphaHorizontalLinearGradient

0.208

106

BlendAlphaRegularGrid

0.201

107

BlendAlphaSimplexNoise

0.433

108

BlendAlphaSomeColors

0.221

109

BlendAlphaVerticalLinearGradient

0.205

110

Canny

0.231

111

Cartoon

4.937

112

CenterCropToAspectRatio

0.102

113

CenterCropToFixedSize

0.099

114

CenterCropToMultiplesOf

0.095

115

CenterCropToPowersOf

0.096

116

CenterCropToSquare

0.101

117

CenterPadToAspectRatio

0.110

118

CenterPadToFixedSize

0.100

119

CenterPadToMultiplesOf

0.110

120

CenterPadToPowersOf

0.106

121

CenterPadToSquare

0.103

122

ChangeColorTemperature

0.121

123

ChangeColorspace

0.098

124

ClipCBAsToImagePlanes

0.085

125

CloudLayer

0.425

126

Clouds

0.774

127

CoarsePepper

0.321

128

CoarseSalt

0.322

129

CoarseSaltAndPepper

0.301

130

Convolve

0.096

131

CropToAspectRatio

0.102

132

CropToMultiplesOf

0.103

133

CropToPowersOf

0.107

134

CropToSquare

0.105

135

DirectedEdgeDetect

0.161

136

Dropout

0.117

137

Dropout2d

0.097

138

EdgeDetect

0.119

139

FastSnowyLandscape

0.159

140

GammaContrast

0.111

141

HistogramEqualization

0.115

142

Jigsaw

0.178

143

KMeansColorQuantization

0.398

144

KeepSizeByResize

0.163

145

LinearContrast

0.112

146

LogContrast

0.111

147

MeanShiftBlur

21.785

148

Multiply

0.111

149

MultiplyAndAddToBrightness

0.190

150

MultiplyElementwise

0.136

151

MultiplyHue

0.216

152

MultiplyHueAndSaturation

0.305

153

PadToAspectRatio

0.117

154

PadToFixedSize

0.107

155

PadToMultiplesOf

0.117

156

PadToPowersOf

0.123

157

PadToSquare

0.109

158

Pepper

0.304

159

Rain

0.905

160

RainLayer

0.437

161

RegularGridVoronoi

10.806

162

RelativeRegularGridVoronoi

10.867

163

RemoveCBAsByOutOfImageFraction

0.091

164

RemoveSaturation

0.216

165

ReplaceElementwise

0.149

166

Rot90

0.096

167

Salt

0.307

168

SaltAndPepper

0.278

169

ScaleX

0.138

170

ScaleY

0.145

171

ShearX

0.143

172

ShearY

0.138

173

SigmoidContrast

0.116

174

Snowflakes

0.815

175

SnowflakesLayer

0.477

176

TotalDropout

0.097

177

TranslateX

0.144

178

TranslateY

0.141

179

UniformColorQuantization

0.124

180

UniformColorQuantizationToNBits

0.124

181

UniformVoronoi

10.874

182

Voronoi

10.984

183

WithBrightnessChannels

0.124

184

WithChannels

0.106

185

WithColorspace

0.113

186

WithHueAndSaturation

0.140

187

WithPolarWarping

0.156

188

EnhanceBrightness

0.111

189

EnhanceColor

0.117

190

EnhanceContrast

0.129

191

EnhanceSharpness

0.140

192

FilterBlur

0.161

193

FilterContour

0.142

194

FilterDetail

0.126

195

FilterEdgeEnhance

0.124

196

FilterEdgeEnhanceMore

0.126

197

FilterEmboss

0.118

198

FilterFindEdges

0.142

199

FilterSharpen

0.126

200

FilterSmooth

0.128

201

FilterSmoothMore

0.161

202

RandomAdjustSharpness

0.110

203

RandomAutocontrast

0.098

204

RandomPerspective

0.136

205

ToTensor

0.087

206

ChangeAspectRatio

0.077

207

ConvertColor

0.077

208

EncodingQuality

0.137

209

MaskedComposite

0.077

210

MemeFormat

2.336

211

Opacity

0.129

212

OverlayEmoji

0.179

213

OverlayImage

0.113

214

OverlayOntoScreenshot

2.449

215

OverlayStripes

0.122

216

PadSquare

0.075

217

RandomAspectRatio

0.100

218

RandomEmojiOverlay

0.145

219

RandomNoise

0.209

220

ShufflePixels

1.461

221

DefocusBlur

0.194

222

ZoomBlur

2.890

223

Frost

0.678

224

SpeckleNoise

0.200

225

Spatter

0.315

226

KeepSizeCrop

0.082

227

TextFlow

4.133

228

HidePatch

0.075

229

SkinTone

0.084

230

PaletteRecolor

71.895

Average run time (ms) in batch size = 128

Unnamed: 0

albumentations

imgaug

torchvision

keras

augly

mmcv

imagenet_c

custom

0

Affine

0.263

0.565

0.582

0.500

1

PiecewiseAffine

2.469

2.075

2

Cutout

0.296

0.601

0.579

3

Crop

0.562

0.570

4

RandomCrop

0.238

0.538

0.475

0.506

5

CenterCrop

0.274

0.470

6

RandomSizedCrop

0.239

0.564

7

RandomResizedCrop

0.240

0.532

8

Resize

0.238

0.552

0.562

0.508

0.519

9

CropAndPad

0.243

0.565

10

Rotate

0.251

0.579

0.525

0.707

0.528

0.521

11

Pad

0.619

0.496

0.527

0.463

12

Normalize

0.297

0.479

13

HorizontalFlip

0.234

0.497

0.538

0.522

0.472

14

VerticalFlip

0.278

0.533

0.473

0.515

0.527

15

ChannelShuffle

0.235

0.535

16

Lambda

0.238

0.527

0.522

0.534

17

Autocontrast

0.751

0.539

18

Blur

0.305

0.527

0.585

19

MedianBlur

0.392

0.586

20

Grayscale

0.546

0.525

0.491

21

Scale

0.577

0.549

22

RandomGrayscale

0.519

23

Equalize

0.270

0.518

0.538

24

Brightness

0.237

0.688

0.500

0.540

0.491

1.017

25

Contrast

0.286

0.593

0.617

0.513

0.628

26

Emboss

0.291

0.552

27

CLAHE

0.311

0.558

0.584

28

Invert

0.279

0.544

0.543

29

Posterize

0.553

30

Saturation

0.274

0.700

0.560

0.502

1.028

31

Sharpen

0.232

0.555

0.502

0.549

32

Solarize

0.299

0.543

0.656

33

PerspectiveTransform

0.570

0.615

34

CoarseDropout

0.234

0.568

35

OverlayText

0.775

0.751

36

JpegCompression

0.310

0.681

0.743

2.321

37

ColorJitter

0.319

0.693

0.617

38

Superpixels

1.935

2.537

39

GaussianNoise

0.528

0.632

40

ShotNoise

0.851

41

ImpulseNoise

0.843

0.797

42

GlassBlur

0.559

44.870

43

MotionBlur

0.310

0.632

4.308

44

GaussianBlur

0.241

0.550

0.645

0.565

45

Snow

0.266

1.874

46

Fog

0.255

0.874

0.622

47

ElasticTransform

1.549

0.649

4.159

48

Pixelization

0.502

0.573

49

RandomFlip

0.463

50

Rerange

0.473

51

RGB2Gray

0.523

52

AdjustGamma

0.471

53

SegRescale

0.461

54

PhotoMetricDistortion

0.481

55

ShiftScaleRotate

0.287

56

Perspective

0.252

57

RandomScale

0.274

58

LongestMaxSize

0.255

59

SmallestMaxSize

0.299

60

RandomRotate90

0.233

61

SafeRotate

0.313

62

CropNonEmptyMaskIfExists

0.242

63

RandomCropNearBBox

0.268

64

Transpose

0.230

65

RandomGamma

0.275

66

OpticalDistortion

0.263

67

GridDistortion

0.340

68

RandomGridShuffle

0.316

69

HueSaturationValue

0.295

70

PadIfNeeded

0.262

71

RGBShift

0.287

72

GaussNoise

0.358

73

ToGray

0.291

74

ToSepia

0.261

75

ImageCompression

0.354

76

ToFloat

0.239

77

FromFloat

0.275

78

RandomBrightnessContrast

0.234

79

RandomRain

0.311

80

RandomSunFlare

0.335

81

RandomShadow

0.322

82

RandomToneCurve

0.281

83

ChannelDropout

0.286

84

ISONoise

0.441

85

Downscale

0.277

86

MultiplicativeNoise

0.237

87

FancyPCA

0.396

88

MaskDropout

0.291

89

GridDropout

0.290

90

Add

0.549

91

AddElementwise

0.574

92

AddToHue

0.627

93

AddToHueAndSaturation

0.576

94

AddToSaturation

0.566

95

AdditiveLaplaceNoise

0.583

96

AdditivePoissonNoise

0.685

97

AffineCv2

0.616

98

AllChannelsCLAHE

0.600

99

AllChannelsHistogramEqualization

0.539

100

BilateralBlur

0.659

101

BlendAlpha

0.615

102

BlendAlphaCheckerboard

0.636

103

BlendAlphaElementwise

0.650

104

BlendAlphaFrequencyNoise

0.833

105

BlendAlphaHorizontalLinearGradient

0.646

106

BlendAlphaRegularGrid

0.681

107

BlendAlphaSimplexNoise

0.904

108

BlendAlphaSomeColors

0.690

109

BlendAlphaVerticalLinearGradient

0.725

110

Canny

0.694

111

Cartoon

5.447

112

CenterCropToAspectRatio

0.549

113

CenterCropToFixedSize

0.539

114

CenterCropToMultiplesOf

0.543

115

CenterCropToPowersOf

0.551

116

CenterCropToSquare

0.539

117

CenterPadToAspectRatio

0.560

118

CenterPadToFixedSize

0.548

119

CenterPadToMultiplesOf

0.553

120

CenterPadToPowersOf

0.562

121

CenterPadToSquare

0.548

122

ChangeColorTemperature

0.560

123

ChangeColorspace

0.543

124

ClipCBAsToImagePlanes

0.536

125

CloudLayer

0.945

126

Clouds

1.263

127

CoarsePepper

0.808

128

CoarseSalt

0.767

129

CoarseSaltAndPepper

0.767

130

Convolve

0.578

131

CropToAspectRatio

0.565

132

CropToMultiplesOf

0.605

133

CropToPowersOf

0.630

134

CropToSquare

0.552

135

DirectedEdgeDetect

0.608

136

Dropout

0.589

137

Dropout2d

0.552

138

EdgeDetect

0.560

139

FastSnowyLandscape

0.591

140

GammaContrast

0.566

141

HistogramEqualization

0.553

142

Jigsaw

0.610

143

KMeansColorQuantization

0.907

144

KeepSizeByResize

0.589

145

LinearContrast

0.554

146

LogContrast

0.545

147

MeanShiftBlur

20.750

148

Multiply

0.555

149

MultiplyAndAddToBrightness

0.625

150

MultiplyElementwise

0.616

151

MultiplyHue

0.670

152

MultiplyHueAndSaturation

0.747

153

PadToAspectRatio

0.566

154

PadToFixedSize

0.564

155

PadToMultiplesOf

0.565

156

PadToPowersOf

0.568

157

PadToSquare

0.545

158

Pepper

0.759

159

Rain

1.284

160

RainLayer

0.857

161

RegularGridVoronoi

10.793

162

RelativeRegularGridVoronoi

10.411

163

RemoveCBAsByOutOfImageFraction

0.512

164

RemoveSaturation

0.650

165

ReplaceElementwise

0.534

166

Rot90

0.525

167

Salt

0.741

168

SaltAndPepper

0.653

169

ScaleX

0.576

170

ScaleY

0.572

171

ShearX

0.519

172

ShearY

0.569

173

SigmoidContrast

0.550

174

Snowflakes

1.122

175

SnowflakesLayer

0.879

176

TotalDropout

0.520

177

TranslateX

0.527

178

TranslateY

0.569

179

UniformColorQuantization

0.552

180

UniformColorQuantizationToNBits

0.520

181

UniformVoronoi

10.528

182

Voronoi

10.346

183

WithBrightnessChannels

0.508

184

WithChannels

0.534

185

WithColorspace

0.545

186

WithHueAndSaturation

0.522

187

WithPolarWarping

0.601

188

EnhanceBrightness

0.554

189

EnhanceColor

0.508

190

EnhanceContrast

0.562

191

EnhanceSharpness

0.576

192

FilterBlur

0.609

193

FilterContour

0.574

194

FilterDetail

0.518

195

FilterEdgeEnhance

0.522

196

FilterEdgeEnhanceMore

0.574

197

FilterEmboss

0.558

198

FilterFindEdges

0.520

199

FilterSharpen

0.516

200

FilterSmooth

0.514

201

FilterSmoothMore

0.546

202

RandomAdjustSharpness

0.551

203

RandomAutocontrast

0.494

204

RandomPerspective

0.528

205

ToTensor

0.522

206

ChangeAspectRatio

0.515

207

ConvertColor

0.534

208

EncodingQuality

0.531

209

MaskedComposite

0.469

210

MemeFormat

2.639

211

Opacity

0.530

212

OverlayEmoji

0.559

213

OverlayImage

0.485

214

OverlayOntoScreenshot

2.828

215

OverlayStripes

0.518

216

PadSquare

0.533

217

RandomAspectRatio

0.550

218

RandomEmojiOverlay

0.558

219

RandomNoise

0.599

220

ShufflePixels

1.737

221

DefocusBlur

0.641

222

ZoomBlur

3.231

223

Frost

1.120

224

SpeckleNoise

0.587

225

Spatter

0.686

226

KeepSizeCrop

0.505

227

TextFlow

4.352

228

HidePatch

0.501

229

SkinTone

0.525

230

PaletteRecolor

68.395