Data augmentation methods for deep learning (CutMix, MixUp, PuzzleMix)
Project description
mlxops-aug
Data augmentation methods for deep learning, including CutMix, MixUp, and PuzzleMix.
Installation
pip install mlxops-aug
For PuzzleMix support (requires pygco):
pip install "mlxops-aug[puzzlemix]"
Note:
pygcorequires a C compiler. See pyGCO for installation instructions.
Usage
CutMix / MixUp
from mlxops_aug import CutMixUp
aug = CutMixUp(
num_classes=10,
config={
"use_cutmix": True,
"use_mixup": True,
"alpha": 1.0,
"prob": 0.5,
},
)
x_aug, y_aug = aug(x, y)
PuzzleMix
from mlxops_aug import PuzzleMix
aug = PuzzleMix(
num_classes=10,
config={
"block_num": 2,
"transport": True,
"prob": 1.0,
},
)
Requirements
- Python >= 3.10
- PyTorch >= 2.0
- torchvision >= 0.15
License
MIT
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
mlxops_aug-0.1.4.tar.gz
(2.0 MB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file mlxops_aug-0.1.4.tar.gz.
File metadata
- Download URL: mlxops_aug-0.1.4.tar.gz
- Upload date:
- Size: 2.0 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ffe82e9eb6597b1be5a1ae74fb897018b16b61ff83aa8f521363e1011375324b
|
|
| MD5 |
639ea7c07f946e6e5202445cff47da16
|
|
| BLAKE2b-256 |
29407b76f7ef331763a3605ae444dff7d176b8366070944a6bdc89dab60177eb
|
File details
Details for the file mlxops_aug-0.1.4-py3-none-any.whl.
File metadata
- Download URL: mlxops_aug-0.1.4-py3-none-any.whl
- Upload date:
- Size: 22.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.11.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a381ad28beeb27f3d0a119e86c3abac90f31be7ef728f25bef174ae96082c867
|
|
| MD5 |
d90d7567d8cf53849f015d010f7ff002
|
|
| BLAKE2b-256 |
e3372d850eaa82e09af2805ce5b52c34301d20be891dc9ced98ac2878b28dc0c
|