Skip to main content

Package that uses extracted audio classification model from neonbjb/DL-Art-School - for filtering fine audio files.

Project description

AudClas

Package that uses audio classification model extracted from neonbjb/DL-Art-School - for filtering fine audio files.

Classes

Classifier model returns one of 6 possible labels:

label class name
0 fine
1 env_noise
2 music
3 two_voices
4 reverb
- unknown

Installation

pip install audclas

examples of usage

For single audio file:

    from audclas.tortoise_audio_classifier import TortoiseAudioClassifier
    classifier = TortoiseAudioClassifier()

    label = classifier('wavs/test.wav')

    print(label)

For directory containing audio files (it searches recursively for all .wav / .mp3 files):

    from tqdm import tqdm
    from audclas.tortoise_audio_classifier import TortoiseAudioClassifier
    classifier = TortoiseAudioClassifier()

    batch_size = 32
    do_classify, total = classifier.prepare_classify_dir_job('/content/wavs', batch_size)

    fine_audio_paths = []

    for result in tqdm(do_classify(), total=total):
        for audio_path, audio_label in result:
            if audio_label == 'fine':
                fine_audio_paths.append(audio_path)

    print(f'directory contains {len(fine_audio_paths)} fine files (total files: {total * batch_size})')

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

audclas-0.0.6.tar.gz (12.8 kB view details)

Uploaded Source

Built Distribution

audclas-0.0.6-py3-none-any.whl (14.0 kB view details)

Uploaded Python 3

File details

Details for the file audclas-0.0.6.tar.gz.

File metadata

  • Download URL: audclas-0.0.6.tar.gz
  • Upload date:
  • Size: 12.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.9

File hashes

Hashes for audclas-0.0.6.tar.gz
Algorithm Hash digest
SHA256 127f63f0434a8b694487ea7065b3c1a88e174735a92d0f43f1edd1bd7e3fa16d
MD5 9e10834fa385d7295d1474cdea99ec38
BLAKE2b-256 ed15a32209db528e7625f89cc3919f7bd0cd2ad5a720cf22f0447aba383af3ae

See more details on using hashes here.

File details

Details for the file audclas-0.0.6-py3-none-any.whl.

File metadata

  • Download URL: audclas-0.0.6-py3-none-any.whl
  • Upload date:
  • Size: 14.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.8.9

File hashes

Hashes for audclas-0.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 99c143b6a424d4bac6dcd578c73f9af0c59363de8d1346a71c394474a8514bf5
MD5 38b8c88e7443589ad745b3c47a66770e
BLAKE2b-256 5e6847e0524e02145c73dc1925478f9fc9b5c05b06f8cc70518043dba25c4103

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page