https://github.com/dansuh17/segan-pytorch
SEGAN pytorch implementation https://arxiv.org/abs/1703.09452
https://github.com/dansuh17/segan-pytorch
audio data-preprocessing mir pytorch segan segan-pytorch source-separation speech-enhancement
Last synced: about 2 months ago
JSON representation
SEGAN pytorch implementation https://arxiv.org/abs/1703.09452
- Host: GitHub
- URL: https://github.com/dansuh17/segan-pytorch
- Owner: dansuh17
- License: gpl-3.0
- Created: 2017-12-04T11:55:28.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2019-03-11T06:27:09.000Z (about 6 years ago)
- Last Synced: 2025-03-29T05:05:01.394Z (2 months ago)
- Topics: audio, data-preprocessing, mir, pytorch, segan, segan-pytorch, source-separation, speech-enhancement
- Language: Python
- Homepage:
- Size: 82 KB
- Stars: 108
- Watchers: 2
- Forks: 32
- Open Issues: 8
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Pytorch Implementation of SEGAN (Speech Enhancement GAN)
Implementation of [SEGAN](https://arxiv.org/abs/1703.09452) by Pascual et al. in 2017, using pytorch.
Original Tensorflow version can be found [here](https://github.com/santi-pdp/segan).## Prerequisites
- python v3.5.2 or higher
- pytorch v0.4.0
- CUDA preferred
- noisy speech dataset downloaded from [here](https://datashare.is.ed.ac.uk/handle/10283/2791)
- libraries specified in `requirements.txt`### Installing Required Libraries
`pip install -r requirements.txt`
## Data Preprocessing
Use `data_preprocess.py` file to preprocess downloaded data.
Adjust the file paths at the beginning of the file to properly locate the data files, output folder, etc.
Uncomment functions in `__main__` to perform desired preprocessing stage.Data preprocessing consists of three main stages:
1. Downsampling - downsample original audio files (48k) to sampling rate of 16000.
2. Serialization - Splitting the audio files into 2^14-sample (about 1 second) snippets.
3. Verification - whether it contains proper number of samples.Note that the second stage takes a fairly long time - more than an hour.
## Training
```
python model.py
```Again, fix and adjust datapaths in `model.py` according to your needs.
Especially, provide accurate path to where serialized data are stored.## Using Tensorboard
In order to use tensorboard, you need to first install tensorboard:
```
pip install tensorboard
```Then run tensorboard by specifing the log directory.
```
tensorboard --logdir=segan_data_out/tblogs
```