You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Add 3D rotations
This adds 3D support to the Rotate transformation, and introduces
RotateX, RotateY, and RotateZ for 3D rotations around the x, y, and z
axes.
* Add check to `getprojection` for `ComposedProjectiveTransform`
Ensure the number of transforms equals the number of random states.
Previously, the projection would silently be calculated only for the
number of transforms equal to the number of random states.
* Add RotateX, RotateY, and RotateZ to documentation
* Clean up documentation, add 3D rotation to gallery
* Use `@docs; canonical=false` for documentation outside of ref.md.
This allows documentation to exist on a second page. Previously,
documentation was split between multiple pages. Some were in ref.md,
and some were in other pages (transformations.md, buffering.md). Now,
all documentation is at least in ref.md, but can also be duplicated
on other pages with `canonical=false`.
* Add missing documentation to ref.md, and transformations.md.
* Enable the visualizations in gallery.md, and clean up the code a bit.
* Add visualizations in gallery.md for 3D rotations.
Since `Buffered` only stores one buffer, you may run into problems when using it in a multi-threading context where different threads invalidate the buffer before it can be used. In that case, you can use [`DataAugmentation.BufferedThreadsafe`](@ref), a version of `Buffered` that keeps a separate buffer for every thread.
Affine transformations are a subgroup of projective transformations that can be composed very efficiently: composing two affine transformations results in another affine transformation. Affine transformations can represent translation, scaling, reflection and rotation. Available `Transform`s are:
27
27
28
-
```@docs
29
-
ScaleRatio
30
-
ScaleKeepAspect
28
+
```@docs; canonical=false
31
29
FlipX
32
30
FlipY
33
31
Reflect
32
+
Rotate
33
+
RotateX
34
+
RotateY
35
+
RotateZ
36
+
ScaleKeepAspect
37
+
ScaleFixed
38
+
ScaleRatio
34
39
WarpAffine
40
+
Zoom
35
41
```
36
42
37
43
## Crops
38
44
39
45
To get a cropped result, simply `compose` any `ProjectiveTransform` with
40
46
41
-
```@docs
47
+
```@docs; canonical=false
42
48
CenterCrop
43
49
RandomCrop
44
50
```
@@ -47,17 +53,17 @@ RandomCrop
47
53
48
54
DataAugmentation.jl currently supports the following color transformations for augmentation:
49
55
50
-
```@docs
51
-
AdjustContrast
56
+
```@docs; canonical=false
52
57
AdjustBrightness
58
+
AdjustContrast
53
59
```
54
60
55
61
# Stochastic transformations
56
62
When augmenting data, it is often useful to apply a transformation only with some probability or choose from a set of transformations. Unlike in other data augmentation libraries like *albumentations*, in DataAugmentation.jl you can use wrapper transformations for this functionality.
57
63
58
64
-[`Maybe`](@ref)`(tfm, p = 0.5)` applies a transformation with probability `p`; and
59
65
-[`OneOf`](@ref)`([tfm1, tfm2])` randomly selects a transformation to apply.
60
-
```@docs
66
+
```@docs; canonical=false
61
67
Maybe
62
68
OneOf
63
69
```
@@ -72,6 +78,6 @@ titems = [apply(tfm, item) for _ in 1:8]
0 commit comments