augmentation
Project description
Augmentation_Package
This packages utilizes two augmentation methods namely.
They were taken from this paper: https://arxiv.org/abs/1910.04176
- Noise injection (aka radiation therapy): this simply upsamples a given list of embeddings with random noise.
- Delta_S: Which takes in a given array and extrapolates data given a target label.
How To Install?
!pip install autograde-aug==0.0.1
How do i use them?
First you need to import the library and instantiate it
import Augmentation
ag = Augmentation.Augmentation()
Noise Injection:
l1, l2 = ag.add_noise(list_of_embeddings, list_of_labels)
l1 will be a new list with doubles the size including original embeddings + new embeddings l2 will be new list of labels
Chnage the level of noise you want to inject
l1, l2 = ag.add_noise(list_of_embeddings, list_of_labels, noise_low= 0.0, nose_high= 0.1)
Delta_S:
This stems from formula
X_hat =( Xi − Xj ) + Xk
Xi is random sample 1 Xj is random sample 2 Xk is random sample 3
Sample a pair of sentences (Xi, Xj) from the target category.
DELTAS applies deltas from the same target category to another sample Xk
l1, l2 = ag.delta_S(list_of_embeddings, list_of_labels, target=0)
NEW !
This lambda with delta_s fusion is a novel technique that has not been tested yet or introduced yet.
if lambda_ is used then we use the lambda_ value times the delta
X_hat =( Xi − Xj ) * λ + Xk
l1, l2 = ag.delta_S(list_of_embeddings, list_of_labels, target=0, lambda_= 0.3)
More Features will be added soon. Enjoy!
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
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 SpaceAugmentation-0.0.1.tar.gz.
File metadata
- Download URL: SpaceAugmentation-0.0.1.tar.gz
- Upload date:
- Size: 4.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.63.0 importlib-metadata/4.11.3 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.8.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
73c68361cc84ba86933f6fac6962f2ca1c2a42d340b7225b0735c9ebbe92aeb8
|
|
| MD5 |
26e3069a6182491461df21f1aa22d5a7
|
|
| BLAKE2b-256 |
4331e1648dfd1779f0998976a4e6ab0867946d61497a1f89e55749393cb77161
|
File details
Details for the file SpaceAugmentation-0.0.1-py3-none-any.whl.
File metadata
- Download URL: SpaceAugmentation-0.0.1-py3-none-any.whl
- Upload date:
- Size: 2.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.8.0 pkginfo/1.8.2 readme-renderer/34.0 requests/2.27.1 requests-toolbelt/0.9.1 urllib3/1.26.9 tqdm/4.63.0 importlib-metadata/4.11.3 keyring/23.5.0 rfc3986/2.0.0 colorama/0.4.4 CPython/3.8.8
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
81e5d74aec4592cef93510b487485d28326c901bb5c77f28f6237c65be20140a
|
|
| MD5 |
4701c7844f1d98151898dcc2b06d8f3d
|
|
| BLAKE2b-256 |
e1467d574998642f8d752da2e3610359505c3eb08d9f7b5819ec19a760bca935
|