Albumentations 1.4.0 Release Notes
- Request
- Highlights
- New transform
- Backwards Incompatible Changes
- Improvements
- Bug fixes
Request
- If you enjoy using the library as an individual developer or during the day job as a part of the company, please consider becoming a sponsor for the library. Every dollar helps.
- If you did not give our repo a ⭐, it is [only one mouse click].(https://github.com/albumentations-team/albumentations)
- If you have feature requests, proposals, or encounter issues - submit your request to issues or, our new initiative, - Discord server for albumentations
Highlights
In this release, we mainly focused on the technical debt as its decrease allows faster iterations and bug fixes in the codebase. We added only one new transform, did not work on speeding up transforms, and other changes are minor.
- We are removing the dependency on the imgaug library. The library was one of our inspirations when we created Albumentations, but maintainers of imgaug ceased its support which caused inconsistencies in library versions. It was done in 2021, say commit ba44eff by @Dipet .
But, somehow, we are cutting this dependency only in 2024.
- Added typing in all of the codebase. When we started the library, Python 2 was still widely used; hence, none of the original codebases had types specified for function arguments and return types. Since the end of the support for Python 2, we added types to the new or updated code, but only now have we covered all the codebase.
New transform
- Added
XYMasking
transform: applies masking strips to an image, either horizontally (X axis) or vertically (Y axis), simulating occlusions. This transform is helpful for training models to recognize images with varied visibility conditions. It's particularly effective for spectrogram images, allowing spectral and frequency masking to improve model robustness.
As other dropout transforms CoarseDropout, MaskDropout, GridDropout it supports images, masks and keypoints as targets. (004fabb by @ternaus )
Backward Incompatible Changes
The deprecated code, including 15 transforms, was removed.
Dependency on the imgaug library was removed.
Deleted Transforms
JpegCompression
. Use ImageCompression instead.RandomBrightness
. Use RandomBrigtnessContrast instead.RandomContrast
. Use RandomBrigtnessContrast instead.Cutout
. Use CoarseDropout instead.ToTensor
. Use ToTensorV2 instead.IAAAdditiveGaussianNoise
. Use GaussNoise instead.IAAAffine
. Use Affine instead.- IAACropAndPad. Use CropAndPad instead.
IAAEmboss
. Use Emboss instead.IAAFliplr
. Use HorizontalFlip instead.IAAFlipud
. Use VerticalFlip instead.IAAPerspective
. Use Perspective instead.IAAPiecewiseAffine
. Use PiecewiseAffine instead.IAASharpen
. Use Sharpen instead.IAASuperpixels
. Use Superpixels instead.
Other deprecated functionality
- Removed
eps
parameter in RandomGamma - Removed
lambda_transforms
inserialization.from_dict
function.
Minor changes and Bug Fixes
- Added details Contributor's guide
- Added support for
matrix=None
case for Piecewise affine transform (c70e664 @Dipet ) - Bugfix - Eliminated the possibility of the Perspective transform collapsing (a919a77 @alicangok )
- Fixes in docstrings (@domef, @aaronzs, @Dipet, @ternaus )
- Added checks for python 3.12