semvec/pypi-packages huggingface dataset:
abbreviator 0.0.4
Abbreviate Long Sentences/Names based on hyphenation
Requires Python: >=3.6

# Abbreviator

Python Package to Abbreviate (product) names, using hyphenation provided by the [pyphen](https://pyphen.org/) package.

## Installation

`pip install abbreviator`

## Example Usage

```
import abbreviator

abbreviator.sentence_shortener('what fantastic')
```
sbo 1.1.0
SBO defines an iterative approach to translate points by a most likely distance from a given dataset

# soft-brownian-offset
Soft Brownian Offset (SBO) defines an iterative approach to translate points by a most likely distance from a given dataset.
It can be used for generating out-of-distribution samples.

## Installation

This project is hosted on [PyPI](https://pypi.org/project/sbo/) and can therefore be installed easily through `pip`:

```
pip install sbo
```

Dependending on your setup you may need to add `--user` after the `install`.

## Usage

For brevity's sake here's a short introduction to the library's usage:

```python
from sklearn.datasets import make_moons
from sbo import soft_brownian_offset

X, _ = make_moons(n_samples=60, noise=.08)
X_ood = soft_brownian_offset(X, d_min=.35, d_off=.24, n_samples=120, softness=0)
```

For more details please see the [documentation](https://soft-brownian-offset.readthedocs.io/en/latest/).

## Background

The technique allows for trivial OOD generation -- as shown above -- or more complex schemes that apply the transformation of learned representations.
For an in-depth look at the latter please refer to the paper that is available [as open access from the CVF](https://openaccess.thecvf.com/content/CVPR2021W/SAIAD/papers/Moller_Out-of-Distribution_Detection_and_Generation_Using_Soft_Brownian_Offset_Sampling_and_CVPRW_2021_paper.pdf).
For citations please see [*cite*](#cite).

## Demonstration

See the following plot to gain intuition on the approach's results:

![demonstration](docs/img/sbo-demo.svg)

Please see the [documentation](https://soft-brownian-offset.readthedocs.io/en/latest/#demonstration) for the source code to recreate the plot.

## Cite

Please cite SBO in your paper if it helps your research:

```bibtex
@inproceedings{MBH21,
  author    = {Möller, Felix and Botache, Diego and Huseljic, Denis and Heidecker, Florian and Bieshaar, Maarten and Sick, Bernhard},
  booktitle = {{Proc. of CVPR SAIAD Workshop}},
  title     = {{Out-of-distribution Detection and Generation using Soft Brownian Offset Sampling and Autoencoders}},
  year      = 2021
}
```
wav2mel 0.3.0
Convert WAV files to Mel spectrograms
Requires Python: >=3.6

# wav2mel

Converts WAV audio [1] to Mel spectrograms for use in machine learning systems like Tacotron2.

This library contains portions of the copy-pasted code you see everywhere for WAV to Mel conversion.

[1] Or any audio format supported by [librosa](https://librosa.org) (which uses [soundfile](https://pysoundfile.readthedocs.io) and [audioread](https://github.com/beetbox/audioread)).

## Installation

```sh
pip install wav2mel
```

## Dependencies

* Python 3.6 or higher
* librosa, numpy, scipy, numba

## Format

`wav2mel` outputs [numpy save data](https://numpy.org/doc/stable/reference/generated/numpy.save.html): one `.npy` file each input file. 

## Usage

You can convert a single WAVE file from `.wav` to a mel spectrogram (`.npy`) as follows:

```sh
wav2mel < WAVE_FILE > NPY_FILE
```

Multiple WAVE files can also be converted and saved to a directory:

```sh
wav2mel --output-dir /path/to/mels WAVE_FILE [WAVE_FILE ...]
```

Each `.npy` file will be named after the corresponding `.wav` file.

See `wav2mel --help` for more options (filter/hop/window length, sample rate, etc.).

## With GNU Parallel

```sh
find /path/to/wavs -name '*.wav' -type f | parallel -X wav2mel --output-dir /path/to/mels
```

## mel2wav (Griffin-Lim)

You can convert a mel spectrogram to WAV audio too using [griffin-lim](https://paperswithcode.com/method/griffin-lim-algorithm):

```sh
mel2wav < NPY_FILE > WAVE_FILE
```

or

```sh
mel2wav --output-dir /path/to/wavs NPY_FILE [NPY_FILE ...]
```

See `mel2wav --help` for more options.