id
int64
0
328k
repository_name
stringlengths
7
58
file_path
stringlengths
9
302
class_name
stringlengths
5
256
human_written_code
stringlengths
16
2.16M
class_skeleton
stringlengths
18
1.49M
⌀
total_program_units
int64
1
1.76k
total_doc_str
int64
0
771
AvgCountLine
float64
0
7.89k
AvgCountLineBlank
float64
0
297
AvgCountLineCode
float64
0
7.89k
AvgCountLineComment
float64
0
7.89k
AvgCyclomatic
float64
0
130
CommentToCodeRatio
float64
0
168
CountClassBase
float64
0
40
CountClassCoupled
float64
0
583
CountClassCoupledModified
float64
0
575
CountClassDerived
float64
0
5.35k
CountDeclInstanceMethod
float64
0
529
CountDeclInstanceVariable
float64
0
296
CountDeclMethod
float64
0
599
CountDeclMethodAll
float64
0
1.12k
CountLine
float64
1
40.4k
CountLineBlank
float64
0
8.16k
CountLineCode
float64
1
25.7k
CountLineCodeDecl
float64
1
8.15k
CountLineCodeExe
float64
0
24.2k
CountLineComment
float64
0
16.5k
CountStmt
float64
1
9.71k
CountStmtDecl
float64
1
8.15k
CountStmtExe
float64
0
9.69k
MaxCyclomatic
float64
0
759
MaxInheritanceTree
float64
0
16
MaxNesting
float64
0
34
SumCyclomatic
float64
0
2.9k
20,200
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blend.py
imgaug.augmenters.blend.BlendAlphaSomeColors
class BlendAlphaSomeColors(BlendAlphaMask): """Blend images from two branches using colorwise masks. This class generates masks that "mark" a few colors and replace the pixels within these colors with the results of the foreground branch. The remaining pixels are replaced with the results of the backgr...
class BlendAlphaSomeColors(BlendAlphaMask): '''Blend images from two branches using colorwise masks. This class generates masks that "mark" a few colors and replace the pixels within these colors with the results of the foreground branch. The remaining pixels are replaced with the results of the backgro...
2
1
19
0
18
1
1
4.68
1
2
1
0
1
0
1
61
144
36
19
7
12
89
3
2
1
1
3
0
1
20,201
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blend.py
imgaug.augmenters.blend.BlendAlphaVerticalLinearGradient
class BlendAlphaVerticalLinearGradient(BlendAlphaMask): """Blend images from two branches along a vertical linear gradient. This class generates a vertical linear gradient mask (i.e. usually a mask with low values on the left and high values on the right) and alphas-blends between foreground and backgr...
class BlendAlphaVerticalLinearGradient(BlendAlphaMask): '''Blend images from two branches along a vertical linear gradient. This class generates a vertical linear gradient mask (i.e. usually a mask with low values on the left and high values on the right) and alphas-blends between foreground and backgro...
2
1
16
0
16
0
1
4.76
1
2
1
0
1
0
1
61
127
29
17
6
11
81
3
2
1
1
3
0
1
20,202
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blend.py
imgaug.augmenters.blend.BoundingBoxesMaskGen
import imgaug as ia import numpy as np from .. import random as iarandom from .. import parameters as iap class BoundingBoxesMaskGen(IBatchwiseMaskGenerator): """Generator that produces masks highlighting bounding boxes. This class produces for each row (i.e. image + bounding boxes) in a batch a mask in w...
class BoundingBoxesMaskGen(IBatchwiseMaskGenerator): '''Generator that produces masks highlighting bounding boxes. This class produces for each row (i.e. image + bounding boxes) in a batch a mask in which the inner areas of bounding box rectangles with given labels are marked (i.e. set to ``1.0``). The...
6
3
24
4
15
5
3
1.21
1
6
1
0
3
2
4
5
169
32
62
19
56
75
42
18
37
5
2
3
13
20,203
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blend.py
imgaug.augmenters.blend.CheckerboardMaskGen
import numpy as np from .. import random as iarandom class CheckerboardMaskGen(IBatchwiseMaskGenerator): """Generate masks following a checkerboard-like pattern. This mask generator splits each image into a regular grid of ``H`` rows and ``W`` columns. Each cell is then filled with either ``1.0`` or `...
class CheckerboardMaskGen(IBatchwiseMaskGenerator): '''Generate masks following a checkerboard-like pattern. This mask generator splits each image into a regular grid of ``H`` rows and ``W`` columns. Each cell is then filled with either ``1.0`` or ``0.0``. The cell at the top-left is always ``1.0``. It...
9
5
16
3
5
7
1
1.81
1
3
2
0
4
1
5
6
115
28
31
14
22
56
23
11
17
2
2
1
6
20,204
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blend.py
imgaug.augmenters.blend.HorizontalLinearGradientMaskGen
class HorizontalLinearGradientMaskGen(_LinearGradientMaskGen): """Generator that produces horizontal linear gradient masks. This class receives batches and produces for each row (i.e. image) a horizontal linear gradient that matches the row's shape (i.e. image shape). The gradient increases linearly fr...
class HorizontalLinearGradientMaskGen(_LinearGradientMaskGen): '''Generator that produces horizontal linear gradient masks. This class receives batches and produces for each row (i.e. image) a horizontal linear gradient that matches the row's shape (i.e. image shape). The gradient increases linearly fro...
4
2
24
4
8
12
1
3.61
1
1
0
0
1
0
2
9
105
22
18
5
13
65
5
3
2
1
3
0
2
20,205
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blend.py
imgaug.augmenters.blend.IBatchwiseMaskGenerator
from abc import ABCMeta, abstractmethod import six @six.add_metaclass(ABCMeta) class IBatchwiseMaskGenerator(object): """Interface for classes generating masks for batches. Child classes are supposed to receive a batch and generate an iterable of masks, one per row (i.e. image), matching the row shape (i....
@six.add_metaclass(ABCMeta) class IBatchwiseMaskGenerator(object): '''Interface for classes generating masks for batches. Child classes are supposed to receive a batch and generate an iterable of masks, one per row (i.e. image), matching the row shape (i.e. image shape). This is used in :class:`~imgaug....
3
2
24
4
1
19
1
13
1
0
0
8
1
0
1
1
36
8
2
2
0
26
2
2
0
1
1
0
1
20,206
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blend.py
imgaug.augmenters.blend.InvertMaskGen
from .. import random as iarandom from .. import parameters as iap class InvertMaskGen(IBatchwiseMaskGenerator): """Generator that inverts the outputs of other mask generators. This class receives batches and calls for each row (i.e. image) a child mask generator to produce a mask. That mask is then inver...
class InvertMaskGen(IBatchwiseMaskGenerator): '''Generator that inverts the outputs of other mask generators. This class receives batches and calls for each row (i.e. image) a child mask generator to produce a mask. That mask is then inverted for ``p%`` of all rows, i.e. converted to ``1.0 - mask``. ...
3
2
9
1
6
2
2
1.5
1
2
1
0
2
2
2
3
39
9
12
8
9
18
12
8
9
3
2
2
4
20,207
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blend.py
imgaug.augmenters.blend.RegularGridMaskGen
import numpy as np from .. import parameters as iap from .. import random as iarandom class RegularGridMaskGen(IBatchwiseMaskGenerator): """Generate masks following a regular grid pattern. This mask generator splits each image into a grid-like pattern of ``H`` rows and ``W`` columns. Each cell is then fil...
class RegularGridMaskGen(IBatchwiseMaskGenerator): '''Generate masks following a regular grid pattern. This mask generator splits each image into a grid-like pattern of ``H`` rows and ``W`` columns. Each cell is then filled with an alpha value, sampled randomly per cell. The difference to :class:`C...
6
3
27
5
15
7
1
0.94
1
3
1
0
3
3
4
5
153
31
63
27
56
59
39
26
33
2
2
1
5
20,208
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blend.py
imgaug.augmenters.blend.SegMapClassIdsMaskGen
from .. import parameters as iap import imgaug as ia import numpy as np from .. import random as iarandom class SegMapClassIdsMaskGen(IBatchwiseMaskGenerator): """Generator that produces masks highlighting segmentation map classes. This class produces for each segmentation map in a batch a mask in which t...
class SegMapClassIdsMaskGen(IBatchwiseMaskGenerator): '''Generator that produces masks highlighting segmentation map classes. This class produces for each segmentation map in a batch a mask in which the locations of a set of provided classes are highlighted (i.e. ``1.0``). The classes may be provided a...
6
3
22
4
13
6
2
1.44
1
5
1
0
3
2
4
5
167
33
55
15
49
79
33
14
28
3
2
2
8
20,209
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blend.py
imgaug.augmenters.blend.SomeColorsMaskGen
from imgaug.imgaug import _normalize_cv2_input_arr_ import imgaug as ia from .. import random as iarandom import cv2 from .. import parameters as iap import numpy as np class SomeColorsMaskGen(IBatchwiseMaskGenerator): """Generator that produces masks based on some similar colors in images. This class receive...
class SomeColorsMaskGen(IBatchwiseMaskGenerator): '''Generator that produces masks based on some similar colors in images. This class receives batches for which to generate masks, iterates over the batch rows (i.e. images) and generates one mask per row. The mask contains high alpha values for some col...
15
3
19
3
11
4
1
1.19
1
4
1
0
4
6
9
10
291
52
109
43
90
130
65
35
54
3
2
1
13
20,210
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blend.py
imgaug.augmenters.blend.StochasticParameterMaskGen
import numpy as np from .. import random as iarandom from .. import parameters as iap class StochasticParameterMaskGen(IBatchwiseMaskGenerator): """Mask generator that queries stochastic parameters for mask values. This class receives batches for which to generate masks, iterates over the batch rows (i.e....
class StochasticParameterMaskGen(IBatchwiseMaskGenerator): '''Mask generator that queries stochastic parameters for mask values. This class receives batches for which to generate masks, iterates over the batch rows (i.e. images) and generates one mask per row. For a row with shape ``(H, W, C)`` (= imag...
4
2
14
2
9
4
2
1.37
1
3
1
0
3
2
3
4
77
13
27
9
23
37
17
9
13
3
2
1
5
20,211
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blend.py
imgaug.augmenters.blend.VerticalLinearGradientMaskGen
class VerticalLinearGradientMaskGen(_LinearGradientMaskGen): """Generator that produces vertical linear gradient masks. See :class:`~imgaug.augmenters.blend.HorizontalLinearGradientMaskGen` for details. Added in 0.4.0. Parameters ---------- min_value : number or tuple of number or list of...
class VerticalLinearGradientMaskGen(_LinearGradientMaskGen): '''Generator that produces vertical linear gradient masks. See :class:`~imgaug.augmenters.blend.HorizontalLinearGradientMaskGen` for details. Added in 0.4.0. Parameters ---------- min_value : number or tuple of number or list of nu...
4
2
24
4
8
12
1
3.22
1
1
0
0
1
0
2
9
97
21
18
5
13
58
5
3
2
1
3
0
2
20,212
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blend.py
imgaug.augmenters.blend._LinearGradientMaskGen
import numpy as np from abc import ABCMeta, abstractmethod from .. import random as iarandom from .. import parameters as iap class _LinearGradientMaskGen(IBatchwiseMaskGenerator): def __init__(self, axis, min_value=0.0, max_value=1.0, start_at=0.0, end_at=1.0): self.axis = axis self.min_value = i...
class _LinearGradientMaskGen(IBatchwiseMaskGenerator): def __init__(self, axis, min_value=0.0, max_value=1.0, start_at=0.0, end_at=1.0): pass def draw_masks(self, batch, random_state=None): ''' See :func:`~imgaug.augmenters.blend.IBatchwiseMaskGenerator.draw_masks`. Added in 0...
10
2
20
3
12
5
2
0.4
1
3
1
2
4
5
6
7
134
25
78
31
66
31
44
27
37
4
2
1
9
20,213
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blur.py
imgaug.augmenters.blur.AverageBlur
import imgaug as ia from .. import parameters as iap from . import meta class AverageBlur(meta.Augmenter): """Blur an image by computing simple means over neighbourhoods. The padding behaviour around the image borders is cv2's ``BORDER_REFLECT_101``. **Supported dtypes**: * ``uint8``: yes; f...
class AverageBlur(meta.Augmenter): '''Blur an image by computing simple means over neighbourhoods. The padding behaviour around the image borders is cv2's ``BORDER_REFLECT_101``. **Supported dtypes**: * ``uint8``: yes; fully tested * ``uint16``: yes; tested * ``uint32``: no (1) ...
4
2
27
2
24
1
5
1.03
1
9
3
0
3
2
3
55
175
27
73
15
67
75
41
13
37
10
2
3
15
20,214
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blur.py
imgaug.augmenters.blur.BilateralBlur
from .. import parameters as iap import cv2 from imgaug.imgaug import _normalize_cv2_input_arr_ from . import meta class BilateralBlur(meta.Augmenter): """Blur/Denoise an image using a bilateral filter. Bilateral filters blur homogenous and textured areas, while trying to preserve edges. See http...
class BilateralBlur(meta.Augmenter): '''Blur/Denoise an image using a bilateral filter. Bilateral filters blur homogenous and textured areas, while trying to preserve edges. See http://docs.opencv.org/2.4/modules/imgproc/doc/filtering.html#bilateralfilter for more information regarding the para...
4
2
16
1
14
1
2
2.17
1
3
0
0
3
3
3
55
157
24
42
18
36
91
24
16
20
4
2
2
6
20,215
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blur.py
imgaug.augmenters.blur.GaussianBlur
from .. import parameters as iap from . import meta class GaussianBlur(meta.Augmenter): """Augmenter to blur images using gaussian kernels. **Supported dtypes**: See ``~imgaug.augmenters.blur.blur_gaussian_(backend="auto")``. Parameters ---------- sigma : number or tuple of number or list of...
class GaussianBlur(meta.Augmenter): '''Augmenter to blur images using gaussian kernels. **Supported dtypes**: See ``~imgaug.augmenters.blur.blur_gaussian_(backend="auto")``. Parameters ---------- sigma : number or tuple of number or list of number or imgaug.parameters.StochasticParameter, optio...
4
2
9
1
7
1
2
1.91
1
2
0
0
3
2
3
55
86
19
23
12
17
44
16
10
12
3
2
1
5
20,216
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blur.py
imgaug.augmenters.blur.MeanShiftBlur
from .. import parameters as iap from . import meta class MeanShiftBlur(meta.Augmenter): """Apply a pyramidic mean shift filter to each image. See also :func:`blur_mean_shift_` for details. This augmenter expects input images of shape ``(H,W)`` or ``(H,W,1)`` or ``(H,W,3)``. .. note:: T...
class MeanShiftBlur(meta.Augmenter): '''Apply a pyramidic mean shift filter to each image. See also :func:`blur_mean_shift_` for details. This augmenter expects input images of shape ``(H,W)`` or ``(H,W,1)`` or ``(H,W,3)``. .. note:: This augmenter is quite slow. Added in 0.4.0. **S...
5
2
9
0
9
0
2
1.57
1
2
0
0
4
2
4
56
113
23
35
12
28
55
16
10
11
3
2
2
6
20,217
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blur.py
imgaug.augmenters.blur.MedianBlur
from . import meta from imgaug.imgaug import _normalize_cv2_input_arr_ import six.moves as sm import cv2 from .. import parameters as iap import imgaug as ia import numpy as np class MedianBlur(meta.Augmenter): """Blur an image by computing median values over neighbourhoods. Median blurring can be used to rem...
class MedianBlur(meta.Augmenter): '''Blur an image by computing median values over neighbourhoods. Median blurring can be used to remove small dirt from images. At larger kernel sizes, its effects have some similarity with Superpixels. **Supported dtypes**: * ``uint8``: yes; fully tested ...
4
2
18
1
15
2
4
1.34
1
4
0
0
3
1
3
55
130
20
47
14
41
63
28
12
24
7
2
4
11
20,218
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blur.py
imgaug.augmenters.blur.MotionBlur
from . import convolutional as iaa_convolutional from .. import parameters as iap class MotionBlur(iaa_convolutional.Convolve): """Blur images in a way that fakes camera or object movements. **Supported dtypes**: See :class:`~imgaug.augmenters.convolutional.Convolve`. Parameters ---------- k...
class MotionBlur(iaa_convolutional.Convolve): '''Blur images in a way that fakes camera or object movements. **Supported dtypes**: See :class:`~imgaug.augmenters.convolutional.Convolve`. Parameters ---------- k : int or tuple of int or list of int or imgaug.parameters.StochasticParameter, optio...
2
1
21
2
18
1
1
3.63
1
2
1
0
1
0
1
56
109
21
19
8
15
69
7
6
5
1
3
0
1
20,219
aleju/imgaug
aleju_imgaug/imgaug/augmenters/blur.py
imgaug.augmenters.blur._MotionBlurMatrixGenerator
import numpy as np class _MotionBlurMatrixGenerator(object): def __init__(self, k, angle, direction, order): self.k = k self.angle = angle self.direction = direction self.order = order def __call__(self, _image, nb_channels, random_state): from . import geometric as ia...
class _MotionBlurMatrixGenerator(object): def __init__(self, k, angle, direction, order): pass def __call__(self, _image, nb_channels, random_state): pass
3
0
18
3
14
2
2
0.17
1
3
1
0
2
4
2
2
40
6
29
13
25
5
19
13
15
2
1
0
3
20,220
aleju/imgaug
aleju_imgaug/imgaug/augmenters/collections.py
imgaug.augmenters.collections.RandAugment
from . import arithmetic import numpy as np from .. import random as iarandom from . import pillike from . import size as sizelib from . import flip from .. import parameters as iap from . import meta class RandAugment(meta.Sequential): """Apply RandAugment to inputs as described in the corresponding paper. S...
class RandAugment(meta.Sequential): '''Apply RandAugment to inputs as described in the corresponding paper. See paper:: Cubuk et al. RandAugment: Practical automated data augmentation with a reduced search space .. note:: The paper contains essentially no hyperparameters for...
12
2
18
1
14
4
1
1.53
1
28
27
0
2
2
4
96
319
48
107
28
93
164
39
24
29
4
3
2
13
20,221
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.AddToBrightness
class AddToBrightness(MultiplyAndAddToBrightness): """Add to the brightness channels of input images. This is a wrapper around :class:`WithBrightnessChannels` and hence performs internally the same projection to random colorspaces. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.au...
class AddToBrightness(MultiplyAndAddToBrightness): '''Add to the brightness channels of input images. This is a wrapper around :class:`WithBrightnessChannels` and hence performs internally the same projection to random colorspaces. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmen...
2
1
20
0
19
1
1
1.85
1
1
0
0
1
0
1
63
72
15
20
12
8
37
3
2
1
1
4
0
1
20,222
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.AddToHue
class AddToHue(AddToHueAndSaturation): """ Add random values to the hue of images. The augmenter first transforms images to HSV colorspace, then adds random values to the H channel and afterwards converts back to RGB. If you want to change both the hue and the saturation, it is recommended to ...
class AddToHue(AddToHueAndSaturation): ''' Add random values to the hue of images. The augmenter first transforms images to HSV colorspace, then adds random values to the H channel and afterwards converts back to RGB. If you want to change both the hue and the saturation, it is recommended to us...
2
1
8
0
8
0
1
5.33
1
1
0
0
1
0
1
63
73
16
9
4
5
48
3
2
1
1
3
0
1
20,223
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.AddToHueAndSaturation
from .. import dtypes as iadt import numpy as np from . import meta import six.moves as sm from .. import parameters as iap import imgaug as ia class AddToHueAndSaturation(meta.Augmenter): """ Increases or decreases hue and saturation by random values. The augmenter first transforms images to HSV colorspa...
class AddToHueAndSaturation(meta.Augmenter): ''' Increases or decreases hue and saturation by random values. The augmenter first transforms images to HSV colorspace, then adds random values to the H and S channels and afterwards converts back to RGB. This augmenter is faster than using ``WithHueAnd...
17
2
19
2
13
3
2
0.82
1
6
0
2
4
6
10
62
315
56
142
51
122
117
91
42
80
5
2
2
23
20,224
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.AddToSaturation
class AddToSaturation(AddToHueAndSaturation): """ Add random values to the saturation of images. The augmenter first transforms images to HSV colorspace, then adds random values to the S channel and afterwards converts back to RGB. If you want to change both the hue and the saturation, it is recom...
class AddToSaturation(AddToHueAndSaturation): ''' Add random values to the saturation of images. The augmenter first transforms images to HSV colorspace, then adds random values to the S channel and afterwards converts back to RGB. If you want to change both the hue and the saturation, it is recomme...
2
1
8
0
8
0
1
5.11
1
1
0
0
1
0
1
63
71
16
9
4
5
46
3
2
1
1
3
0
1
20,225
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.ChangeColorTemperature
from . import meta from .. import parameters as iap class ChangeColorTemperature(meta.Augmenter): """Change the temperature to a provided Kelvin value. Low Kelvin values around ``1000`` to ``4000`` will result in red, yellow or orange images. Kelvin values around ``10000`` to ``40000`` will result in ...
class ChangeColorTemperature(meta.Augmenter): '''Change the temperature to a provided Kelvin value. Low Kelvin values around ``1000`` to ``4000`` will result in red, yellow or orange images. Kelvin values around ``10000`` to ``40000`` will result in progressively darker blue tones. Color temperatur...
4
2
8
1
7
0
1
1.62
1
1
0
0
3
2
3
55
72
17
21
10
15
34
13
8
9
2
2
1
4
20,226
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.ChangeColorspace
from . import meta import cv2 from . import blend from .. import parameters as iap import imgaug as ia class ChangeColorspace(meta.Augmenter): """ Augmenter to change the colorspace of images. .. note:: This augmenter is not tested. Some colorspaces might work, others might not. ..no...
class ChangeColorspace(meta.Augmenter): ''' Augmenter to change the colorspace of images. .. note:: This augmenter is not tested. Some colorspaces might work, others might not. ..note:: This augmenter tries to project the colorspace value range on 0-255. It outputs dtype...
5
2
22
2
19
1
3
0.58
1
8
3
1
4
4
4
56
211
29
116
34
109
67
53
32
48
4
2
2
10
20,227
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.Grayscale
class Grayscale(ChangeColorspace): """Augmenter to convert images to their grayscale versions. .. note:: Number of output channels is still ``3``, i.e. this augmenter just "removes" color. TODO check dtype support **Supported dtypes**: See :func:`~imgaug.augmenters.color.change_...
class Grayscale(ChangeColorspace): '''Augmenter to convert images to their grayscale versions. .. note:: Number of output channels is still ``3``, i.e. this augmenter just "removes" color. TODO check dtype support **Supported dtypes**: See :func:`~imgaug.augmenters.color.change_color...
2
1
9
0
9
0
1
4.9
1
1
0
0
1
0
1
57
77
18
10
4
6
49
3
2
1
1
3
0
1
20,228
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.KMeansColorQuantization
class KMeansColorQuantization(_AbstractColorQuantization): """ Quantize colors using k-Means clustering. This "collects" the colors from the input image, groups them into ``k`` clusters using k-Means clustering and replaces the colors in the input image using the cluster centroids. This is slo...
class KMeansColorQuantization(_AbstractColorQuantization): ''' Quantize colors using k-Means clustering. This "collects" the colors from the input image, groups them into ``k`` clusters using k-Means clustering and replaces the colors in the input image using the cluster centroids. This is slowe...
5
2
8
1
6
1
1
5.47
1
1
0
0
3
0
3
62
159
36
19
9
10
104
7
4
3
1
3
0
3
20,229
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.MultiplyAndAddToBrightness
from . import meta import numpy as np import imgaug as ia from . import arithmetic class MultiplyAndAddToBrightness(WithBrightnessChannels): """Multiply and add to the brightness channels of input images. This is a wrapper around :class:`WithBrightnessChannels` and hence performs internally the same proje...
class MultiplyAndAddToBrightness(WithBrightnessChannels): '''Multiply and add to the brightness channels of input images. This is a wrapper around :class:`WithBrightnessChannels` and hence performs internally the same projection to random colorspaces. Added in 0.4.0. **Supported dtypes**: See :...
3
1
23
1
22
1
2
1
1
6
4
2
2
0
2
62
109
19
45
14
31
45
7
3
4
3
3
0
4
20,230
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.MultiplyBrightness
class MultiplyBrightness(MultiplyAndAddToBrightness): """Multiply the brightness channels of input images. This is a wrapper around :class:`WithBrightnessChannels` and hence performs internally the same projection to random colorspaces. Added in 0.4.0. **Supported dtypes**: See :class:`~imga...
class MultiplyBrightness(MultiplyAndAddToBrightness): '''Multiply the brightness channels of input images. This is a wrapper around :class:`WithBrightnessChannels` and hence performs internally the same projection to random colorspaces. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.a...
2
1
20
0
19
1
1
1.85
1
1
0
0
1
0
1
63
72
15
20
12
8
37
3
2
1
1
4
0
1
20,231
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.MultiplyHue
class MultiplyHue(MultiplyHueAndSaturation): """ Multiply the hue of images by random values. The augmenter first transforms images to HSV colorspace, then multiplies the pixel values in the H channel and afterwards converts back to RGB. This augmenter is a shortcut for ``MultiplyHueAndSaturat...
class MultiplyHue(MultiplyHueAndSaturation): ''' Multiply the hue of images by random values. The augmenter first transforms images to HSV colorspace, then multiplies the pixel values in the H channel and afterwards converts back to RGB. This augmenter is a shortcut for ``MultiplyHueAndSaturatio...
2
1
8
0
8
0
1
5.11
1
1
0
0
1
0
1
62
70
15
9
4
5
46
3
2
1
1
4
0
1
20,232
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.MultiplyHueAndSaturation
from . import meta from .. import parameters as iap from . import arithmetic from .. import random as iarandom class MultiplyHueAndSaturation(WithHueAndSaturation): """ Multipy hue and saturation by random values. The augmenter first transforms images to HSV colorspace, then multiplies the pixel value...
class MultiplyHueAndSaturation(WithHueAndSaturation): ''' Multipy hue and saturation by random values. The augmenter first transforms images to HSV colorspace, then multiplies the pixel values in the H and S channels and afterwards converts back to RGB. This augmenter is a wrapper around ``With...
2
1
94
5
89
0
10
1.01
1
6
3
2
1
0
1
61
211
30
90
7
85
91
27
4
25
10
3
2
10
20,233
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.MultiplySaturation
class MultiplySaturation(MultiplyHueAndSaturation): """ Multiply the saturation of images by random values. The augmenter first transforms images to HSV colorspace, then multiplies the pixel values in the H channel and afterwards converts back to RGB. This augmenter is a shortcut for ``Mul...
class MultiplySaturation(MultiplyHueAndSaturation): ''' Multiply the saturation of images by random values. The augmenter first transforms images to HSV colorspace, then multiplies the pixel values in the H channel and afterwards converts back to RGB. This augmenter is a shortcut for ``Multi...
2
1
8
0
8
0
1
4.78
1
1
0
1
1
0
1
62
67
15
9
4
5
43
3
2
1
1
4
0
1
20,234
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.Posterize
class Posterize(UniformColorQuantizationToNBits): """Alias for :class:`UniformColorQuantizationToNBits`. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.color.UniformColorQuantizationToNBits`. """
class Posterize(UniformColorQuantizationToNBits): '''Alias for :class:`UniformColorQuantizationToNBits`. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.color.UniformColorQuantizationToNBits`. ''' pass
1
1
0
0
0
0
0
5
1
0
0
1
0
0
0
61
10
4
1
1
0
5
1
1
0
0
4
0
0
20,235
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.RemoveSaturation
from .. import parameters as iap class RemoveSaturation(MultiplySaturation): """Decrease the saturation of images by varying degrees. This creates images looking similar to :class:`Grayscale`. This augmenter is the same as ``MultiplySaturation((0.0, 1.0))``. Added in 0.4.0. **Supported dtypes**...
class RemoveSaturation(MultiplySaturation): '''Decrease the saturation of images by varying degrees. This creates images looking similar to :class:`Grayscale`. This augmenter is the same as ``MultiplySaturation((0.0, 1.0))``. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters....
2
1
15
0
15
0
1
3
1
2
1
0
1
0
1
63
84
20
16
4
12
48
4
2
2
1
5
0
1
20,236
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.UniformColorQuantization
class UniformColorQuantization(_AbstractColorQuantization): """Quantize colors into N bins with regular distance. For ``uint8`` images the equation is ``floor(v/q)*q + q/2`` with ``q = 256/N``, where ``v`` is a pixel intensity value and ``N`` is the target number of colors after quantization. This...
class UniformColorQuantization(_AbstractColorQuantization): '''Quantize colors into N bins with regular distance. For ``uint8`` images the equation is ``floor(v/q)*q + q/2`` with ``q = 256/N``, where ``v`` is a pixel intensity value and ``N`` is the target number of colors after quantization. This a...
5
2
9
1
7
1
1
4.45
1
1
0
0
3
0
3
62
154
34
22
12
10
98
7
4
3
1
3
0
3
20,237
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.UniformColorQuantizationToNBits
class UniformColorQuantizationToNBits(_AbstractColorQuantization): """Quantize images by setting ``8-B`` bits of each component to zero. This augmenter sets the ``8-B`` highest frequency (rightmost) bits of each array component to zero. For ``B`` bits this is equivalent to changing each component's int...
class UniformColorQuantizationToNBits(_AbstractColorQuantization): '''Quantize images by setting ``8-B`` bits of each component to zero. This augmenter sets the ``8-B`` highest frequency (rightmost) bits of each array component to zero. For ``B`` bits this is equivalent to changing each component's inte...
3
1
12
1
10
2
1
5
1
1
0
1
2
0
2
61
152
32
20
10
10
100
5
3
2
1
3
0
2
20,238
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.WithBrightnessChannels
from . import meta from .. import parameters as iap class WithBrightnessChannels(meta.Augmenter): """Augmenter to apply child augmenters to brightness-related image channels. This augmenter first converts an image to a random colorspace containing a brightness-related channel (e.g. ``V`` in ``HSV``), then...
class WithBrightnessChannels(meta.Augmenter): '''Augmenter to apply child augmenters to brightness-related image channels. This augmenter first converts an image to a random colorspace containing a brightness-related channel (e.g. ``V`` in ``HSV``), then extracts that channel and applies its child augm...
9
3
12
1
10
1
2
0.83
1
2
0
1
8
3
8
60
201
36
90
35
70
75
46
24
37
3
2
2
12
20,239
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.WithColorspace
from . import meta class WithColorspace(meta.Augmenter): """ Apply child augmenters within a specific colorspace. This augumenter takes a source colorspace A and a target colorspace B as well as children C. It changes images from A to B, then applies the child augmenters C and finally changes the ...
class WithColorspace(meta.Augmenter): ''' Apply child augmenters within a specific colorspace. This augumenter takes a source colorspace A and a target colorspace B as well as children C. It changes images from A to B, then applies the child augmenters C and finally changes the colorspace back from...
7
3
9
1
7
1
1
1.09
1
1
0
0
6
3
6
58
116
22
45
13
36
49
26
11
19
3
2
2
8
20,240
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color.WithHueAndSaturation
import imgaug as ia from . import meta import numpy as np from .. import dtypes as iadt class WithHueAndSaturation(meta.Augmenter): """ Apply child augmenters to hue and saturation channels. This augumenter takes an image in a source colorspace, converts it to HSV, extracts the H (hue) and S (saturati...
class WithHueAndSaturation(meta.Augmenter): ''' Apply child augmenters to hue and saturation channels. This augumenter takes an image in a source colorspace, converts it to HSV, extracts the H (hue) and S (saturation) channels, applies the provided child augmenters to these channels and finally...
9
3
12
1
9
2
2
1.05
1
2
0
1
8
3
8
60
183
31
74
26
63
78
52
24
43
4
2
1
14
20,241
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color._AbstractColorQuantization
import six from . import meta import numpy as np import imgaug as ia from abc import ABCMeta, abstractmethod from .. import parameters as iap import six.moves as sm @six.add_metaclass(ABCMeta) class _AbstractColorQuantization(meta.Augmenter): def __init__(self, counts=(2, 16), counts_value_range=(2, None), from_c...
@six.add_metaclass(ABCMeta) class _AbstractColorQuantization(meta.Augmenter): def __init__(self, counts=(2, 16), counts_value_range=(2, None), from_colorspace=CSPACE_RGB, to_colorspace=[CSPACE_RGB, CSPACE_Lab], max_size=128, interpolation='linear', seed=None, name=None, random_state='deprecated', deterministic='de...
11
2
18
2
14
2
2
0.19
1
5
2
3
6
6
7
59
135
19
98
41
80
19
59
31
51
6
2
2
16
20,242
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color._KelvinToRGBTable
import numpy as np class _KelvinToRGBTable(object): def __init__(self): self.table = self.create_table() def transform_kelvins_to_rgb_multipliers(self, kelvins): """Transform kelvin values to corresponding multipliers for RGB images. A single returned multiplier denotes the channelwi...
class _KelvinToRGBTable(object): def __init__(self): pass def transform_kelvins_to_rgb_multipliers(self, kelvins): '''Transform kelvin values to corresponding multipliers for RGB images. A single returned multiplier denotes the channelwise multipliers in the range ``[0.0, 1.0]...
5
1
146
3
138
135
1
0.98
1
0
0
0
2
1
3
3
443
11
416
16
411
407
19
15
15
1
1
0
3
20,243
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color._KelvinToRGBTableSingleton
class _KelvinToRGBTableSingleton(object): _INSTANCE = None @classmethod def get_instance(cls): if cls._INSTANCE is None: cls._INSTANCE = _KelvinToRGBTable() return cls._INSTANCE
class _KelvinToRGBTableSingleton(object): @classmethod def get_instance(cls): pass
3
0
4
0
4
0
2
0.14
1
1
1
0
0
0
1
1
9
1
7
4
4
1
6
3
4
2
1
1
2
20,244
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color._QuantizeUniformCenterizedLUTTableSingleton
class _QuantizeUniformCenterizedLUTTableSingleton(object): _INSTANCE = None @classmethod def get_instance(cls): """Get singleton instance of :class:`_QuantizeUniformLUTTable`. Added in 0.4.0. Returns ------- _QuantizeUniformLUTTable The global instance ...
class _QuantizeUniformCenterizedLUTTableSingleton(object): @classmethod def get_instance(cls): '''Get singleton instance of :class:`_QuantizeUniformLUTTable`. Added in 0.4.0. Returns ------- _QuantizeUniformLUTTable The global instance of :class:`_QuantizeUni...
3
1
14
3
4
7
2
1
1
1
1
0
0
0
1
1
18
4
7
4
4
7
6
3
4
2
1
1
2
20,245
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color._QuantizeUniformLUTTable
import numpy as np class _QuantizeUniformLUTTable(object): def __init__(self, centerize): self.table = self._generate_quantize_uniform_table(centerize) def get_for_nb_bins(self, nb_bins): """Get LUT ndarray for a provided number of bins. Added in 0.4.0. """ return se...
class _QuantizeUniformLUTTable(object): def __init__(self, centerize): pass def get_for_nb_bins(self, nb_bins): '''Get LUT ndarray for a provided number of bins. Added in 0.4.0. ''' pass @classmethod def _generate_quantize_uniform_table(cls, centerize): ...
5
1
9
1
5
3
2
0.56
1
0
0
0
2
1
3
3
33
5
18
11
13
10
16
10
12
3
1
2
5
20,246
aleju/imgaug
aleju_imgaug/imgaug/augmenters/color.py
imgaug.augmenters.color._QuantizeUniformNotCenterizedLUTTableSingleton
class _QuantizeUniformNotCenterizedLUTTableSingleton(object): """Table for :func:`quantize_uniform` with ``to_bin_centers=False``.""" _INSTANCE = None @classmethod def get_instance(cls): """Get singleton instance of :class:`_QuantizeUniformLUTTable`. Added in 0.4.0. Returns ...
class _QuantizeUniformNotCenterizedLUTTableSingleton(object): '''Table for :func:`quantize_uniform` with ``to_bin_centers=False``.''' @classmethod def get_instance(cls): '''Get singleton instance of :class:`_QuantizeUniformLUTTable`. Added in 0.4.0. Returns ------- _Q...
3
2
14
3
4
7
2
1.14
1
1
1
0
0
0
1
1
19
4
7
4
4
8
6
3
4
2
1
1
2
20,247
aleju/imgaug
aleju_imgaug/imgaug/augmenters/contrast.py
imgaug.augmenters.contrast.AllChannelsCLAHE
import numpy as np from .. import parameters as iap import six.moves as sm from imgaug.imgaug import _normalize_cv2_input_arr_ from .. import dtypes as iadt import cv2 from . import meta class AllChannelsCLAHE(meta.Augmenter): """Apply CLAHE to all channels of images in their original colorspaces. CLAHE (Cont...
class AllChannelsCLAHE(meta.Augmenter): '''Apply CLAHE to all channels of images in their original colorspaces. CLAHE (Contrast Limited Adaptive Histogram Equalization) performs histogram equilization within image patches, i.e. over local neighbourhoods. In contrast to ``imgaug.augmenters.contrast....
4
2
29
3
25
1
4
0.96
1
3
0
0
3
4
3
55
180
33
75
27
68
72
44
24
40
10
2
3
12
20,248
aleju/imgaug
aleju_imgaug/imgaug/augmenters/contrast.py
imgaug.augmenters.contrast.AllChannelsHistogramEqualization
from imgaug.imgaug import _normalize_cv2_input_arr_ from . import meta import cv2 import numpy as np import six.moves as sm from .. import dtypes as iadt class AllChannelsHistogramEqualization(meta.Augmenter): """ Apply Histogram Eq. to all channels of images in their original colorspaces. In contrast to ...
class AllChannelsHistogramEqualization(meta.Augmenter): ''' Apply Histogram Eq. to all channels of images in their original colorspaces. In contrast to ``imgaug.augmenters.contrast.HistogramEqualization``, this augmenter operates directly on all channels of the input images. It does not perform any...
4
2
9
2
7
0
2
2.26
1
2
0
0
3
0
3
55
95
20
23
8
18
52
18
7
14
4
2
2
6
20,249
aleju/imgaug
aleju_imgaug/imgaug/augmenters/contrast.py
imgaug.augmenters.contrast.CLAHE
from .. import dtypes as iadt from ..augmentables.batches import _BatchInAugmentation from . import meta from . import color as color_lib class CLAHE(meta.Augmenter): """Apply CLAHE to L/V/L channels in HLS/HSV/Lab colorspaces. This augmenter applies CLAHE (Contrast Limited Adaptive Histogram Equalization...
class CLAHE(meta.Augmenter): '''Apply CLAHE to L/V/L channels in HLS/HSV/Lab colorspaces. This augmenter applies CLAHE (Contrast Limited Adaptive Histogram Equalization) to images, a form of histogram equalization that normalizes within local image patches. The augmenter transforms input images to ...
5
2
15
2
12
1
1
2.89
1
4
3
0
3
2
3
55
222
39
47
22
36
136
24
16
19
2
2
1
5
20,250
aleju/imgaug
aleju_imgaug/imgaug/augmenters/contrast.py
imgaug.augmenters.contrast.GammaContrast
from .. import parameters as iap class GammaContrast(_ContrastFuncWrapper): """ Adjust image contrast by scaling pixel values to ``255*((v/255)**gamma)``. Values in the range ``gamma=(0.5, 2.0)`` seem to be sensible. **Supported dtypes**: See :func:`~imgaug.augmenters.contrast.adjust_contrast_ga...
class GammaContrast(_ContrastFuncWrapper): ''' Adjust image contrast by scaling pixel values to ``255*((v/255)**gamma)``. Values in the range ``gamma=(0.5, 2.0)`` seem to be sensible. **Supported dtypes**: See :func:`~imgaug.augmenters.contrast.adjust_contrast_gamma`. Parameters ---------- ...
2
1
14
0
14
0
1
3
1
1
0
0
1
0
1
56
76
16
15
6
11
45
5
4
3
1
3
0
1
20,251
aleju/imgaug
aleju_imgaug/imgaug/augmenters/contrast.py
imgaug.augmenters.contrast.HistogramEqualization
from . import color as color_lib from .. import dtypes as iadt from ..augmentables.batches import _BatchInAugmentation from . import meta class HistogramEqualization(meta.Augmenter): """ Apply Histogram Eq. to L/V/L channels of images in HLS/HSV/Lab colorspaces. This augmenter is similar to ``imgaug.augme...
class HistogramEqualization(meta.Augmenter): ''' Apply Histogram Eq. to L/V/L channels of images in HLS/HSV/Lab colorspaces. This augmenter is similar to ``imgaug.augmenters.contrast.CLAHE``. The augmenter transforms input images to a target colorspace (e.g. ``Lab``), extracts an intensity-related ...
5
2
13
2
10
1
1
2.29
1
4
3
0
3
2
3
55
154
29
38
19
29
87
23
15
18
2
2
1
5
20,252
aleju/imgaug
aleju_imgaug/imgaug/augmenters/contrast.py
imgaug.augmenters.contrast.LinearContrast
from .. import parameters as iap class LinearContrast(_ContrastFuncWrapper): """Adjust contrast by scaling each pixel to ``127 + alpha*(v-127)``. **Supported dtypes**: See :func:`~imgaug.augmenters.contrast.adjust_contrast_linear`. Parameters ---------- alpha : number or tuple of number or l...
class LinearContrast(_ContrastFuncWrapper): '''Adjust contrast by scaling each pixel to ``127 + alpha*(v-127)``. **Supported dtypes**: See :func:`~imgaug.augmenters.contrast.adjust_contrast_linear`. Parameters ---------- alpha : number or tuple of number or list of number or imgaug.parameters.S...
2
1
17
1
16
0
1
2.65
1
1
0
0
1
0
1
56
77
15
17
6
13
45
5
4
3
1
3
0
1
20,253
aleju/imgaug
aleju_imgaug/imgaug/augmenters/contrast.py
imgaug.augmenters.contrast.LogContrast
from .. import parameters as iap class LogContrast(_ContrastFuncWrapper): """Adjust image contrast by scaling pixels to ``255*gain*log_2(1+v/255)``. This augmenter is fairly similar to ``imgaug.augmenters.arithmetic.Multiply``. **Supported dtypes**: See :func:`~imgaug.augmenters.contrast.adjust_...
class LogContrast(_ContrastFuncWrapper): '''Adjust image contrast by scaling pixels to ``255*gain*log_2(1+v/255)``. This augmenter is fairly similar to ``imgaug.augmenters.arithmetic.Multiply``. **Supported dtypes**: See :func:`~imgaug.augmenters.contrast.adjust_contrast_log`. Parameters --...
2
1
16
1
14
1
1
3.2
1
1
0
0
1
0
1
56
79
16
15
6
11
48
5
4
3
1
3
0
1
20,254
aleju/imgaug
aleju_imgaug/imgaug/augmenters/contrast.py
imgaug.augmenters.contrast.SigmoidContrast
from .. import parameters as iap class SigmoidContrast(_ContrastFuncWrapper): """ Adjust image contrast to ``255*1/(1+exp(gain*(cutoff-I_ij/255)))``. Values in the range ``gain=(5, 20)`` and ``cutoff=(0.25, 0.75)`` seem to be sensible. A combination of ``gain=5.5`` and ``cutof=0.45`` is fairly cl...
class SigmoidContrast(_ContrastFuncWrapper): ''' Adjust image contrast to ``255*1/(1+exp(gain*(cutoff-I_ij/255)))``. Values in the range ``gain=(5, 20)`` and ``cutoff=(0.25, 0.75)`` seem to be sensible. A combination of ``gain=5.5`` and ``cutof=0.45`` is fairly close to the identity function. ...
2
1
21
1
19
1
1
3.2
1
1
0
0
1
0
1
56
103
19
20
6
16
64
5
4
3
1
3
0
1
20,255
aleju/imgaug
aleju_imgaug/imgaug/augmenters/contrast.py
imgaug.augmenters.contrast._ContrastFuncWrapper
from .. import dtypes as iadt import numpy as np from .. import parameters as iap import six.moves as sm from . import meta class _ContrastFuncWrapper(meta.Augmenter): def __init__(self, func, params1d, per_channel, dtypes_allowed=None, dtypes_disallowed=None, seed=None, name=None, random_state='deprecated', dete...
class _ContrastFuncWrapper(meta.Augmenter): def __init__(self, func, params1d, per_channel, dtypes_allowed=None, dtypes_disallowed=None, seed=None, name=None, random_state='deprecated', deterministic='deprecated'): pass def _augment_batch_(self, batch, random_state, parents, hooks): pass ...
4
1
20
1
17
2
3
0.16
1
4
0
5
3
5
3
55
65
6
51
26
44
8
36
23
32
7
2
3
9
20,256
aleju/imgaug
aleju_imgaug/imgaug/augmenters/contrast.py
imgaug.augmenters.contrast._IntensityChannelBasedApplier
import imgaug as ia from . import color as color_lib import numpy as np class _IntensityChannelBasedApplier(object): RGB = color_lib.CSPACE_RGB BGR = color_lib.CSPACE_BGR HSV = color_lib.CSPACE_HSV HLS = color_lib.CSPACE_HLS Lab = color_lib.CSPACE_Lab _CHANNEL_MAPPING = {HSV: 2, HLS: 1, Lab: 0}...
class _IntensityChannelBasedApplier(object): def __init__(self, from_colorspace, to_colorspace): pass def apply(self, images, random_state, parents, hooks, func): pass def get_parameters(self): '''See :func:`~imgaug.augmenters.meta.Augmenter.get_parameters`.''' pass
4
1
38
4
28
6
5
0.19
1
3
0
0
3
2
3
3
128
15
95
30
91
18
66
30
62
14
1
3
16
20,257
aleju/imgaug
aleju_imgaug/imgaug/augmenters/convolutional.py
imgaug.augmenters.convolutional.Convolve
from . import meta import imgaug as ia class Convolve(meta.Augmenter): """ Apply a convolution to input images. **Supported dtypes**: See :func:`~imgaug.augmenters.convolutional.convolve_`. Parameters ---------- matrix : None or (H, W) ndarray or imgaug.parameters.StochasticParameter...
class Convolve(meta.Augmenter): ''' Apply a convolution to input images. **Supported dtypes**: See :func:`~imgaug.augmenters.convolutional.convolve_`. Parameters ---------- matrix : None or (H, W) ndarray or imgaug.parameters.StochasticParameter or callable, optional The weight ...
4
2
17
2
14
1
4
1.37
1
4
0
5
3
2
3
55
124
22
43
13
37
59
29
11
25
6
2
2
11
20,258
aleju/imgaug
aleju_imgaug/imgaug/augmenters/convolutional.py
imgaug.augmenters.convolutional.DirectedEdgeDetect
from .. import parameters as iap class DirectedEdgeDetect(Convolve): """ Detect edges from specified angles and alpha-blend with the input image. This augmenter first detects edges along a certain angle. Usually, edges are detected in x- or y-direction, while here the edge detection kernel is rota...
class DirectedEdgeDetect(Convolve): ''' Detect edges from specified angles and alpha-blend with the input image. This augmenter first detects edges along a certain angle. Usually, edges are detected in x- or y-direction, while here the edge detection kernel is rotated to match a specified angle. ...
2
1
17
2
15
0
1
4.06
1
2
1
0
1
0
1
56
103
22
16
7
12
65
6
5
4
1
3
0
1
20,259
aleju/imgaug
aleju_imgaug/imgaug/augmenters/convolutional.py
imgaug.augmenters.convolutional.EdgeDetect
from .. import parameters as iap class EdgeDetect(Convolve): """ Generate a black & white edge image and alpha-blend it with the input image. **Supported dtypes**: See :class:`~imgaug.augmenters.convolutional.Convolve`. Parameters ---------- alpha : number or tuple of number or list of n...
class EdgeDetect(Convolve): ''' Generate a black & white edge image and alpha-blend it with the input image. **Supported dtypes**: See :class:`~imgaug.augmenters.convolutional.Convolve`. Parameters ---------- alpha : number or tuple of number or list of number or imgaug.parameters.Stochasti...
2
1
13
2
11
0
1
3.08
1
2
1
0
1
0
1
56
62
13
12
6
8
37
5
4
3
1
3
0
1
20,260
aleju/imgaug
aleju_imgaug/imgaug/augmenters/convolutional.py
imgaug.augmenters.convolutional.Emboss
from .. import parameters as iap class Emboss(Convolve): """ Emboss images and alpha-blend the result with the original input images. The embossed version pronounces highlights and shadows, letting the image look as if it was recreated on a metal plate ("embossed"). **Supported dtypes**: See...
class Emboss(Convolve): ''' Emboss images and alpha-blend the result with the original input images. The embossed version pronounces highlights and shadows, letting the image look as if it was recreated on a metal plate ("embossed"). **Supported dtypes**: See :class:`~imgaug.augmenters.convolut...
2
1
16
2
14
0
1
3.33
1
2
1
0
1
0
1
56
81
16
15
7
11
50
6
5
4
1
3
0
1
20,261
aleju/imgaug
aleju_imgaug/imgaug/augmenters/convolutional.py
imgaug.augmenters.convolutional.Sharpen
from .. import parameters as iap class Sharpen(Convolve): """ Sharpen images and alpha-blend the result with the original input images. **Supported dtypes**: See :class:`~imgaug.augmenters.convolutional.Convolve`. Parameters ---------- alpha : number or tuple of number or list of number ...
class Sharpen(Convolve): ''' Sharpen images and alpha-blend the result with the original input images. **Supported dtypes**: See :class:`~imgaug.augmenters.convolutional.Convolve`. Parameters ---------- alpha : number or tuple of number or list of number or imgaug.parameters.StochasticParam...
2
1
16
2
14
0
1
3.53
1
2
1
0
1
0
1
56
85
17
15
7
11
53
6
5
4
1
3
0
1
20,262
aleju/imgaug
aleju_imgaug/imgaug/augmenters/convolutional.py
imgaug.augmenters.convolutional._DirectedEdgeDetectMatrixGenerator
import numpy as np import itertools import imgaug as ia class _DirectedEdgeDetectMatrixGenerator(object): def __init__(self, alpha, direction): self.alpha = alpha self.direction = direction def __call__(self, _image, nb_channels, random_state): alpha_sample = self.alpha.draw_sample(ra...
class _DirectedEdgeDetectMatrixGenerator(object): def __init__(self, alpha, direction): pass def __call__(self, _image, nb_channels, random_state): pass
3
0
23
3
21
0
2
0
1
2
0
0
2
2
2
2
48
6
42
19
39
0
27
19
24
3
1
2
4
20,263
aleju/imgaug
aleju_imgaug/imgaug/augmenters/convolutional.py
imgaug.augmenters.convolutional._EdgeDetectMatrixGenerator
import numpy as np class _EdgeDetectMatrixGenerator(object): def __init__(self, alpha): self.alpha = alpha def __call__(self, _image, nb_channels, random_state): alpha_sample = self.alpha.draw_sample(random_state=random_state) assert 0 <= alpha_sample <= 1.0, "Expected 'alpha' to be i...
class _EdgeDetectMatrixGenerator(object): def __init__(self, alpha): pass def __call__(self, _image, nb_channels, random_state): pass
3
0
11
0
11
0
1
0
1
0
0
0
2
1
2
2
24
1
23
8
20
0
10
8
7
1
1
0
2
20,264
aleju/imgaug
aleju_imgaug/imgaug/augmenters/convolutional.py
imgaug.augmenters.convolutional._EmbossMatrixGenerator
import numpy as np class _EmbossMatrixGenerator(object): def __init__(self, alpha, strength): self.alpha = alpha self.strength = strength def __call__(self, _image, nb_channels, random_state): alpha_sample = self.alpha.draw_sample(random_state=random_state) assert 0 <= alpha_s...
class _EmbossMatrixGenerator(object): def __init__(self, alpha, strength): pass def __call__(self, _image, nb_channels, random_state): pass
3
0
12
0
12
0
1
0
1
0
0
0
2
2
2
2
26
1
25
10
22
0
12
10
9
1
1
0
2
20,265
aleju/imgaug
aleju_imgaug/imgaug/augmenters/convolutional.py
imgaug.augmenters.convolutional._SharpeningMatrixGenerator
import numpy as np class _SharpeningMatrixGenerator(object): def __init__(self, alpha, lightness): self.alpha = alpha self.lightness = lightness def __call__(self, _image, nb_channels, random_state): alpha_sample = self.alpha.draw_sample(random_state=random_state) assert 0 <= ...
class _SharpeningMatrixGenerator(object): def __init__(self, alpha, lightness): pass def __call__(self, _image, nb_channels, random_state): pass
3
0
12
0
12
0
1
0
1
0
0
0
2
2
2
2
26
1
25
10
22
0
12
10
9
1
1
0
2
20,266
aleju/imgaug
aleju_imgaug/imgaug/augmenters/debug.py
imgaug.augmenters.debug.SaveDebugImageEveryNBatches
import os class SaveDebugImageEveryNBatches(_SaveDebugImage): """Visualize data in batches and save corresponding plots to a folder. Added in 0.4.0. **Supported dtypes**: See :func:`~imgaug.augmenters.debug.draw_debug_image`. Parameters ---------- destination : str or _IImageDestination...
class SaveDebugImageEveryNBatches(_SaveDebugImage): '''Visualize data in batches and save corresponding plots to a folder. Added in 0.4.0. **Supported dtypes**: See :func:`~imgaug.augmenters.debug.draw_debug_image`. Parameters ---------- destination : str or _IImageDestination Path ...
3
1
13
0
13
0
2
1.67
1
5
4
0
2
0
2
56
85
13
27
7
22
45
10
5
7
2
3
1
3
20,267
aleju/imgaug
aleju_imgaug/imgaug/augmenters/debug.py
imgaug.augmenters.debug._DebugGrid
import numpy as np class _DebugGrid(object): """A debug image grid. Columns correspond to the input datatypes (e.g. images, bounding boxes). Rows correspond to the examples within a batch. Added in 0.4.0. """ def __init__(self, columns): assert len(columns) > 0 self.columns ...
class _DebugGrid(object): '''A debug image grid. Columns correspond to the input datatypes (e.g. images, bounding boxes). Rows correspond to the examples within a batch. Added in 0.4.0. ''' def __init__(self, columns): pass def draw(self): '''Convert this grid to an image ...
3
2
9
1
6
2
2
0.69
1
1
0
0
2
1
2
2
29
7
13
7
10
9
12
7
9
2
1
1
3
20,268
aleju/imgaug
aleju_imgaug/imgaug/augmenters/debug.py
imgaug.augmenters.debug._DebugGridBorderCell
from . import size as sizelib class _DebugGridBorderCell(_IDebugGridCell): """Helper to add a border around a cell within the debug image grid. Added in 0.4.0. """ def __init__(self, size, color, child): self.size = size self.color = color self.child = child @property ...
class _DebugGridBorderCell(_IDebugGridCell): '''Helper to add a border around a cell within the debug image grid. Added in 0.4.0. ''' def __init__(self, size, color, child): pass @property def min_height(self): pass @property def min_width(self): pass def d...
7
1
4
0
4
0
1
0.39
1
0
0
0
4
3
4
7
31
6
18
11
11
7
13
9
8
1
2
0
4
20,269
aleju/imgaug
aleju_imgaug/imgaug/augmenters/debug.py
imgaug.augmenters.debug._DebugGridCBAsOICell
class _DebugGridCBAsOICell(_IDebugGridCell): """Cell visualizing a coordinate-based augmentable. CBAsOI = coordinate-based augmentables on images, e.g. ``KeypointsOnImage``. Added in 0.4.0. """ def __init__(self, cbasoi, image): self.cbasoi = cbasoi self.image = image @p...
class _DebugGridCBAsOICell(_IDebugGridCell): '''Cell visualizing a coordinate-based augmentable. CBAsOI = coordinate-based augmentables on images, e.g. ``KeypointsOnImage``. Added in 0.4.0. ''' def __init__(self, cbasoi, image): pass @property def min_height(self): pass ...
7
1
4
1
4
0
1
0.5
1
0
0
0
4
2
4
7
36
9
18
11
11
9
15
9
10
1
2
0
4
20,270
aleju/imgaug
aleju_imgaug/imgaug/augmenters/debug.py
imgaug.augmenters.debug._DebugGridColumn
import numpy as np class _DebugGridColumn(object): """A single column within the debug image grid. Added in 0.4.0. """ def __init__(self, cells): self.cells = cells @property def nb_rows(self): """Number of rows in the column, i.e. examples in batch. Added in 0.4.0....
class _DebugGridColumn(object): '''A single column within the debug image grid. Added in 0.4.0. ''' def __init__(self, cells): pass @property def nb_rows(self): '''Number of rows in the column, i.e. examples in batch. Added in 0.4.0. ''' pass @proper...
9
5
7
2
3
2
1
0.88
1
1
0
0
5
1
5
5
47
15
17
11
8
15
12
8
6
1
1
0
5
20,271
aleju/imgaug
aleju_imgaug/imgaug/augmenters/debug.py
imgaug.augmenters.debug._DebugGridImageCell
import numpy as np from . import size as sizelib from .. import dtypes as iadt from . import blend as blendlib import imgaug as ia class _DebugGridImageCell(_IDebugGridCell): """Cell containing an image, possibly with an different-shaped overlay. Added in 0.4.0. """ def __init__(self, image, overlay...
class _DebugGridImageCell(_IDebugGridCell): '''Cell containing an image, possibly with an different-shaped overlay. Added in 0.4.0. ''' def __init__(self, image, overlay=None, overlay_alpha=0.75): pass @property def min_height(self): pass @property def min_width(self): ...
9
1
9
1
8
0
2
0.19
1
0
0
0
4
3
5
8
63
12
43
21
34
8
32
18
26
6
2
1
10
20,272
aleju/imgaug
aleju_imgaug/imgaug/augmenters/debug.py
imgaug.augmenters.debug._DebugGridTextCell
import numpy as np import imgaug as ia class _DebugGridTextCell(_IDebugGridCell): """Cell containing text. Added in 0.4.0. """ def __init__(self, text): self.text = text @property def min_height(self): return max(20, len(self.text.split('\n')) * 17) @property def mi...
class _DebugGridTextCell(_IDebugGridCell): '''Cell containing text. Added in 0.4.0. ''' def __init__(self, text): pass @property def min_height(self): pass @property def min_width(self): pass def draw(self, height, width): pass
7
1
4
0
4
0
1
0.41
1
1
0
0
4
1
4
7
30
6
17
10
10
7
14
8
9
2
2
1
5
20,273
aleju/imgaug
aleju_imgaug/imgaug/augmenters/debug.py
imgaug.augmenters.debug._EveryNBatchesSchedule
class _EveryNBatchesSchedule(_IBatchwiseSchedule): """A schedule that generates a signal at every ``N`` th batch. This schedule must be called for *every* batch in order to count them. Added in 0.4.0. """ def __init__(self, interval): self.interval = interval self._batch_id = -1 ...
class _EveryNBatchesSchedule(_IBatchwiseSchedule): '''A schedule that generates a signal at every ``N`` th batch. This schedule must be called for *every* batch in order to count them. Added in 0.4.0. ''' def __init__(self, interval): pass def on_batch(self, batch): pass
3
1
4
0
4
0
1
0.63
1
0
0
0
2
2
2
3
18
5
8
6
5
5
8
6
5
1
2
0
2
20,274
aleju/imgaug
aleju_imgaug/imgaug/augmenters/debug.py
imgaug.augmenters.debug._FolderImageDestination
import imageio import os class _FolderImageDestination(_IImageDestination): """A destination which saves images to a directory.""" def __init__(self, folder_path, filename_pattern='batch_{batch_id:06d}.png'): super(_FolderImageDestination, self).__init__() self.folder_path = folder_path ...
class _FolderImageDestination(_IImageDestination): '''A destination which saves images to a directory.''' def __init__(self, folder_path, filename_pattern='batch_{batch_id:06d}.png'): pass def on_batch(self, batch): pass def receive(self, image): pass
4
1
5
0
5
0
1
0.27
1
1
0
0
3
4
3
5
22
3
15
9
10
4
12
8
8
1
2
0
3
20,275
aleju/imgaug
aleju_imgaug/imgaug/augmenters/debug.py
imgaug.augmenters.debug._IBatchwiseSchedule
from abc import ABCMeta, abstractmethod, abstractproperty import six @six.add_metaclass(ABCMeta) class _IBatchwiseSchedule(object): """A schedule determining per batch whether a condition is met.""" def on_batch(self, batch): """Determine for the given batch whether the condition is met. Adde...
@six.add_metaclass(ABCMeta) class _IBatchwiseSchedule(object): '''A schedule determining per batch whether a condition is met.''' def on_batch(self, batch): '''Determine for the given batch whether the condition is met. Added in 0.4.0. Parameters ---------- batch : _Batc...
3
2
16
4
1
11
1
6
1
0
0
1
1
0
1
1
19
5
2
2
0
12
2
2
0
1
1
0
1
20,276
aleju/imgaug
aleju_imgaug/imgaug/augmenters/debug.py
imgaug.augmenters.debug._IDebugGridCell
import six from abc import ABCMeta, abstractmethod, abstractproperty @six.add_metaclass(ABCMeta) class _IDebugGridCell(object): """A single cell within a debug image's grid. Usually corresponds to one image, but can also be e.g. a title/description. Added in 0.4.0. """ @abstractproperty def...
@six.add_metaclass(ABCMeta) class _IDebugGridCell(object): '''A single cell within a debug image's grid. Usually corresponds to one image, but can also be e.g. a title/description. Added in 0.4.0. ''' @abstractproperty def min_width(self): '''Minimum width in pixels that the cell require...
8
4
10
3
1
6
1
3.29
1
0
0
4
3
0
3
3
45
15
7
7
0
23
4
4
0
1
1
0
3
20,277
aleju/imgaug
aleju_imgaug/imgaug/augmenters/debug.py
imgaug.augmenters.debug._IImageDestination
import six from abc import ABCMeta, abstractmethod, abstractproperty @six.add_metaclass(ABCMeta) class _IImageDestination(object): """A destination which receives images to save.""" def on_batch(self, batch): """Signal to the destination that a new batch is processed. This is intended to be u...
@six.add_metaclass(ABCMeta) class _IImageDestination(object): '''A destination which receives images to save.''' def on_batch(self, batch): '''Signal to the destination that a new batch is processed. This is intended to be used by the destination e.g. to count batches. Added in 0.4.0. ...
4
3
12
4
1
8
1
5.33
1
0
0
3
2
0
2
2
28
9
3
3
0
16
3
3
0
1
1
0
2
20,278
aleju/imgaug
aleju_imgaug/imgaug/augmenters/debug.py
imgaug.augmenters.debug._ListOfArraysStats
import numpy as np class _ListOfArraysStats(object): """Class to derive aggregated values from a list of arrays. E.g. shape of the largest array, number of unique dtypes etc. Added in 0.4.0. """ def __init__(self, arrays): self.arrays = arrays @property def empty(self): ...
class _ListOfArraysStats(object): '''Class to derive aggregated values from a list of arrays. E.g. shape of the largest array, number of unique dtypes etc. Added in 0.4.0. ''' def __init__(self, arrays): pass @property def empty(self): pass @property def areas(self)...
48
1
3
0
3
0
2
0.27
1
4
0
0
25
1
25
25
158
28
102
57
54
28
77
34
51
3
1
1
39
20,279
aleju/imgaug
aleju_imgaug/imgaug/augmenters/debug.py
imgaug.augmenters.debug._MultiDestination
class _MultiDestination(_IImageDestination): """A list of multiple destinations behaving like a single one.""" def __init__(self, destinations): self.destinations = destinations def on_batch(self, batch): for destination in self.destinations: destination.on_batch(batch) de...
class _MultiDestination(_IImageDestination): '''A list of multiple destinations behaving like a single one.''' def __init__(self, destinations): pass def on_batch(self, batch): pass def receive(self, image): pass
4
1
3
0
3
0
2
0.44
1
0
0
0
3
1
3
5
16
3
9
7
5
4
9
7
5
2
2
1
5
20,280
aleju/imgaug
aleju_imgaug/imgaug/augmenters/debug.py
imgaug.augmenters.debug._SaveDebugImage
from . import meta class _SaveDebugImage(meta.Augmenter): """Augmenter saving debug images to a destination according to a schedule. Added in 0.4.0. Parameters ---------- destination : _IImageDestination The destination receiving debug images. schedule : _IBatchwiseSchedule T...
class _SaveDebugImage(meta.Augmenter): '''Augmenter saving debug images to a destination according to a schedule. Added in 0.4.0. Parameters ---------- destination : _IImageDestination The destination receiving debug images. schedule : _IBatchwiseSchedule The schedule to use to ...
3
1
13
2
11
0
2
1.09
1
1
0
1
2
2
2
54
61
13
23
9
18
25
12
7
9
2
2
1
3
20,281
aleju/imgaug
aleju_imgaug/imgaug/augmenters/edges.py
imgaug.augmenters.edges.Canny
import imgaug as ia from . import blend import numpy as np import cv2 from imgaug.imgaug import _normalize_cv2_input_arr_ from .. import parameters as iap from . import meta from .. import dtypes as iadt class Canny(meta.Augmenter): """ Apply a canny edge detector to input images. **Supported dtypes**: ...
class Canny(meta.Augmenter): ''' Apply a canny edge detector to input images. **Supported dtypes**: * ``uint8``: yes; fully tested * ``uint16``: no; not tested * ``uint32``: no; not tested * ``uint64``: no; not tested * ``int8``: no; not tested * ``int16``: n...
6
2
30
4
25
2
2
1.12
1
5
1
0
5
4
5
57
309
47
124
37
112
139
52
31
46
4
2
2
12
20,282
aleju/imgaug
aleju_imgaug/imgaug/augmenters/edges.py
imgaug.augmenters.edges.IBinaryImageColorizer
from abc import ABCMeta, abstractmethod import six @six.add_metaclass(ABCMeta) class IBinaryImageColorizer(object): """Interface for classes that convert binary masks to color images.""" @abstractmethod def colorize(self, image_binary, image_original, nth_image, random_state): """ Convert ...
@six.add_metaclass(ABCMeta) class IBinaryImageColorizer(object): '''Interface for classes that convert binary masks to color images.''' @abstractmethod def colorize(self, image_binary, image_original, nth_image, random_state): ''' Convert a binary image to a colorized one. Parameters...
4
2
24
6
1
17
1
6
1
0
0
1
1
0
1
1
28
7
3
3
0
18
2
2
0
1
1
0
1
20,283
aleju/imgaug
aleju_imgaug/imgaug/augmenters/edges.py
imgaug.augmenters.edges.RandomColorsBinaryImageColorizer
import numpy as np from .. import dtypes as iadt from .. import parameters as iap class RandomColorsBinaryImageColorizer(IBinaryImageColorizer): """ Colorizer using two randomly sampled foreground/background colors. Parameters ---------- color_true : int or tuple of int or list of int or imgaug.pa...
class RandomColorsBinaryImageColorizer(IBinaryImageColorizer): ''' Colorizer using two randomly sampled foreground/background colors. Parameters ---------- color_true : int or tuple of int or list of int or imgaug.parameters.StochasticParameter, optional Color of the foreground, i.e. all pi...
5
1
18
2
16
1
2
0.4
1
0
0
0
4
2
4
5
102
14
63
12
58
25
27
12
22
3
2
1
6
20,284
aleju/imgaug
aleju_imgaug/imgaug/augmenters/flip.py
imgaug.augmenters.flip.Fliplr
from . import meta from .. import parameters as iap class Fliplr(meta.Augmenter): """Flip/mirror input images horizontally. .. note:: The default value for the probability is ``0.0``. So, to flip *all* input images use ``Fliplr(1.0)`` and *not* just ``Fliplr()``. **Supported dtyp...
class Fliplr(meta.Augmenter): '''Flip/mirror input images horizontally. .. note:: The default value for the probability is ``0.0``. So, to flip *all* input images use ``Fliplr(1.0)`` and *not* just ``Fliplr()``. **Supported dtypes**: See :func:`~imgaug.augmenters.flip.fliplr`. ...
4
2
19
2
15
2
5
0.85
1
3
0
0
3
1
3
55
110
25
46
19
40
39
39
17
35
14
2
4
16
20,285
aleju/imgaug
aleju_imgaug/imgaug/augmenters/flip.py
imgaug.augmenters.flip.Flipud
from . import meta from .. import parameters as iap class Flipud(meta.Augmenter): """Flip/mirror input images vertically. .. note:: The default value for the probability is ``0.0``. So, to flip *all* input images use ``Flipud(1.0)`` and *not* just ``Flipud()``. **Supported dtypes...
class Flipud(meta.Augmenter): '''Flip/mirror input images vertically. .. note:: The default value for the probability is ``0.0``. So, to flip *all* input images use ``Flipud(1.0)`` and *not* just ``Flipud()``. **Supported dtypes**: See :func:`~imgaug.augmenters.flip.flipud`. ...
4
2
20
2
15
3
5
0.89
1
3
0
0
3
1
3
55
111
24
46
19
40
41
39
17
35
14
2
4
16
20,286
aleju/imgaug
aleju_imgaug/imgaug/augmenters/geometric.py
imgaug.augmenters.geometric.Affine
from . import meta from skimage import transform as tf from .. import parameters as iap import numpy as np import imgaug as ia class Affine(meta.Augmenter): """ Augmenter to apply affine transformations to images. This is mostly a wrapper around the corresponding classes and functions in OpenCV and sk...
class Affine(meta.Augmenter): ''' Augmenter to apply affine transformations to images. This is mostly a wrapper around the corresponding classes and functions in OpenCV and skimage. Affine transformations involve: - Translation ("move" image on the x-/y-axis) - Rotation - Sc...
13
2
40
3
33
3
5
1.37
1
6
1
8
6
16
9
61
839
117
305
75
285
417
158
65
148
9
2
5
47
20,287
aleju/imgaug
aleju_imgaug/imgaug/augmenters/geometric.py
imgaug.augmenters.geometric.AffineCv2
from . import meta import math from skimage import transform as tf from .. import dtypes as iadt from imgaug.imgaug import _normalize_cv2_input_arr_ from .. import parameters as iap import numpy as np import imgaug as ia import six.moves as sm import cv2 class AffineCv2(meta.Augmenter): """ **Deprecated.** Aug...
class AffineCv2(meta.Augmenter): ''' **Deprecated.** Augmenter to apply affine transformations to images using cv2 (i.e. opencv) backend. .. warning:: This augmenter is deprecated since 0.4.0. Use ``Affine(..., backend='cv2')`` instead. Affine transformations involve: - ...
13
2
40
3
36
1
4
0.64
1
14
4
0
10
7
11
63
745
93
398
114
374
254
185
98
173
17
2
3
44
20,288
aleju/imgaug
aleju_imgaug/imgaug/augmenters/geometric.py
imgaug.augmenters.geometric.ElasticTransformation
from . import meta from imgaug.augmentables.polys import _ConcavePolygonRecoverer from .. import dtypes as iadt from scipy import ndimage from imgaug.imgaug import _normalize_cv2_input_arr_ from .. import parameters as iap import numpy as np import imgaug as ia import six.moves as sm import functools import cv2 class ...
class ElasticTransformation(meta.Augmenter): ''' Transform images by moving pixels locally around using displacement fields. The augmenter has the parameters ``alpha`` and ``sigma``. ``alpha`` controls the strength of the displacement: higher values mean that pixels are moved further. ``sigma`` con...
18
3
38
4
23
11
4
0.97
1
16
6
0
11
13
13
65
727
104
316
97
293
308
195
90
181
19
2
4
57
20,289
aleju/imgaug
aleju_imgaug/imgaug/augmenters/geometric.py
imgaug.augmenters.geometric.Jigsaw
import numpy as np from . import meta from . import size as size_lib from .. import parameters as iap class Jigsaw(meta.Augmenter): """Move cells within images similar to jigsaw patterns. .. note:: This augmenter will by default pad images until their height is a multiple of `nb_rows`. Analog...
class Jigsaw(meta.Augmenter): '''Move cells within images similar to jigsaw patterns. .. note:: This augmenter will by default pad images until their height is a multiple of `nb_rows`. Analogous for `nb_cols`. .. note:: This augmenter will resize heatmaps and segmentation maps to th...
13
1
19
2
14
2
3
0.88
1
6
2
0
4
4
8
60
275
53
118
49
101
104
76
41
67
12
2
2
25
20,290
aleju/imgaug
aleju_imgaug/imgaug/augmenters/geometric.py
imgaug.augmenters.geometric.PerspectiveTransform
from . import meta from imgaug.augmentables.polys import _ConcavePolygonRecoverer from .. import dtypes as iadt from imgaug.imgaug import _normalize_cv2_input_arr_ from .. import parameters as iap import numpy as np import imgaug as ia import six.moves as sm import functools import cv2 class PerspectiveTransform(meta....
class PerspectiveTransform(meta.Augmenter): ''' Apply random four point perspective transformations to images. Each of the four points is placed on the image using a random distance from its respective corner. The distance is sampled from a normal distribution. As a result, most transformations don...
15
2
45
6
32
8
5
0.68
1
15
6
0
7
15
10
62
642
98
327
108
308
221
220
101
209
11
2
4
52
20,291
aleju/imgaug
aleju_imgaug/imgaug/augmenters/geometric.py
imgaug.augmenters.geometric.PiecewiseAffine
from . import meta from skimage import transform as tf from imgaug.augmentables.polys import _ConcavePolygonRecoverer from .. import dtypes as iadt from .. import parameters as iap import numpy as np import imgaug as ia import functools class PiecewiseAffine(meta.Augmenter): """ Apply affine transformations th...
class PiecewiseAffine(meta.Augmenter): ''' Apply affine transformations that differ between local neighbourhoods. This augmenter places a regular grid of points on an image and randomly moves the neighbourhood of these point around via affine transformations. This leads to local distortions. Th...
9
2
43
6
29
8
5
0.78
1
8
3
0
8
15
8
60
495
83
231
75
216
181
132
69
123
7
2
4
36
20,292
aleju/imgaug
aleju_imgaug/imgaug/augmenters/geometric.py
imgaug.augmenters.geometric.Rot90
from . import meta from .. import parameters as iap import numpy as np import imgaug as ia import six.moves as sm import functools class Rot90(meta.Augmenter): """ Rotate images clockwise by multiples of 90 degrees. This could also be achieved using ``Affine``, but ``Rot90`` is significantly more effi...
class Rot90(meta.Augmenter): ''' Rotate images clockwise by multiples of 90 degrees. This could also be achieved using ``Affine``, but ``Rot90`` is significantly more efficient. **Supported dtypes**: if (keep_size=False): * ``uint8``: yes; fully tested * ``uint16``: yes; tested ...
9
2
18
2
14
2
4
0.92
1
6
0
0
6
2
7
59
238
43
102
43
91
94
81
40
73
7
2
4
27
20,293
aleju/imgaug
aleju_imgaug/imgaug/augmenters/geometric.py
imgaug.augmenters.geometric.Rotate
class Rotate(Affine): """Apply affine rotation on the y-axis to input data. This is a wrapper around :class:`Affine`. It is the same as ``Affine(rotate=<value>)``. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.geometric.Affine`. Parameters ---------- rotat...
class Rotate(Affine): '''Apply affine rotation on the y-axis to input data. This is a wrapper around :class:`Affine`. It is the same as ``Affine(rotate=<value>)``. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.geometric.Affine`. Parameters ---------- rotate : n...
2
1
13
0
13
0
1
2.93
1
1
0
0
1
0
1
62
73
18
14
5
9
41
3
2
1
1
3
0
1
20,294
aleju/imgaug
aleju_imgaug/imgaug/augmenters/geometric.py
imgaug.augmenters.geometric.ScaleX
class ScaleX(Affine): """Apply affine scaling on the x-axis to input data. This is a wrapper around :class:`Affine`. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.geometric.Affine`. Parameters ---------- scale : number or tuple of number or list of number or i...
class ScaleX(Affine): '''Apply affine scaling on the x-axis to input data. This is a wrapper around :class:`Affine`. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.geometric.Affine`. Parameters ---------- scale : number or tuple of number or list of number or imgaug...
2
1
13
0
13
0
1
3.07
1
1
0
0
1
0
1
62
75
18
14
5
9
43
3
2
1
1
3
0
1
20,295
aleju/imgaug
aleju_imgaug/imgaug/augmenters/geometric.py
imgaug.augmenters.geometric.ScaleY
class ScaleY(Affine): """Apply affine scaling on the y-axis to input data. This is a wrapper around :class:`Affine`. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.geometric.Affine`. Parameters ---------- scale : number or tuple of number or list of number or i...
class ScaleY(Affine): '''Apply affine scaling on the y-axis to input data. This is a wrapper around :class:`Affine`. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.geometric.Affine`. Parameters ---------- scale : number or tuple of number or list of number or imgaug...
2
1
13
0
13
0
1
3.07
1
1
0
0
1
0
1
62
75
18
14
5
9
43
3
2
1
1
3
0
1
20,296
aleju/imgaug
aleju_imgaug/imgaug/augmenters/geometric.py
imgaug.augmenters.geometric.ShearX
class ShearX(Affine): """Apply affine shear on the x-axis to input data. This is a wrapper around :class:`Affine`. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.geometric.Affine`. Parameters ---------- shear : number or tuple of number or list of number or img...
class ShearX(Affine): '''Apply affine shear on the x-axis to input data. This is a wrapper around :class:`Affine`. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.geometric.Affine`. Parameters ---------- shear : number or tuple of number or list of number or imgaug.p...
2
1
13
0
13
0
1
2.93
1
1
0
0
1
0
1
62
73
18
14
5
9
41
3
2
1
1
3
0
1
20,297
aleju/imgaug
aleju_imgaug/imgaug/augmenters/geometric.py
imgaug.augmenters.geometric.ShearY
class ShearY(Affine): """Apply affine shear on the y-axis to input data. This is a wrapper around :class:`Affine`. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.geometric.Affine`. Parameters ---------- shear : number or tuple of number or list of number or img...
class ShearY(Affine): '''Apply affine shear on the y-axis to input data. This is a wrapper around :class:`Affine`. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.geometric.Affine`. Parameters ---------- shear : number or tuple of number or list of number or imgaug.p...
2
1
13
0
13
0
1
2.93
1
1
0
0
1
0
1
62
73
18
14
5
9
41
3
2
1
1
3
0
1
20,298
aleju/imgaug
aleju_imgaug/imgaug/augmenters/geometric.py
imgaug.augmenters.geometric.TranslateX
class TranslateX(Affine): """Apply affine translation on the x-axis to input data. This is a wrapper around :class:`Affine`. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.geometric.Affine`. Parameters ---------- percent : None or number or tuple of number or l...
class TranslateX(Affine): '''Apply affine translation on the x-axis to input data. This is a wrapper around :class:`Affine`. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.geometric.Affine`. Parameters ---------- percent : None or number or tuple of number or list o...
2
1
17
1
16
0
4
2.88
1
1
0
0
1
0
1
62
88
22
17
5
12
49
5
2
3
4
3
1
4
20,299
aleju/imgaug
aleju_imgaug/imgaug/augmenters/geometric.py
imgaug.augmenters.geometric.TranslateY
class TranslateY(Affine): """Apply affine translation on the y-axis to input data. This is a wrapper around :class:`Affine`. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.geometric.Affine`. Parameters ---------- percent : None or number or tuple of number or l...
class TranslateY(Affine): '''Apply affine translation on the y-axis to input data. This is a wrapper around :class:`Affine`. Added in 0.4.0. **Supported dtypes**: See :class:`~imgaug.augmenters.geometric.Affine`. Parameters ---------- percent : None or number or tuple of number or list o...
2
1
17
1
16
0
4
2.88
1
1
0
0
1
0
1
62
88
22
17
5
12
49
5
2
3
4
3
1
4