{"id":13861656,"url":"https://github.com/SuperKogito/spafe","last_synced_at":"2025-07-14T09:33:03.008Z","repository":{"id":35996562,"uuid":"208756619","full_name":"SuperKogito/spafe","owner":"SuperKogito","description":":sound: spafe: Simplified Python Audio Features Extraction","archived":false,"fork":false,"pushed_at":"2024-05-29T07:23:11.000Z","size":21507,"stargazers_count":434,"open_issues_count":0,"forks_count":75,"subscribers_count":9,"default_branch":"master","last_synced_at":"2024-05-29T15:51:00.331Z","etag":null,"topics":["audio","audio-analysis","beat","dsp","features-extraction","filterbank","frequencies","frequency","frequency-analysis","gammatone-filterbanks","mfcc","music","music-information-retrieval","pitch","python","signal-processing","sound","speech-processing","time-frequency-analysis","voice"],"latest_commit_sha":null,"homepage":"https://superkogito.github.io/spafe/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/SuperKogito.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-09-16T09:07:00.000Z","updated_at":"2024-05-30T20:38:39.258Z","dependencies_parsed_at":"2024-05-30T20:38:26.721Z","dependency_job_id":null,"html_url":"https://github.com/SuperKogito/spafe","commit_stats":{"total_commits":323,"total_committers":12,"mean_commits":"26.916666666666668","dds":0.5603715170278638,"last_synced_commit":"b6b1428df52694c95bb295a6ec291ae442053fcc"},"previous_names":[],"tags_count":8,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SuperKogito%2Fspafe","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SuperKogito%2Fspafe/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SuperKogito%2Fspafe/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/SuperKogito%2Fspafe/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/SuperKogito","download_url":"https://codeload.github.com/SuperKogito/spafe/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":225968847,"owners_count":17553147,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["audio","audio-analysis","beat","dsp","features-extraction","filterbank","frequencies","frequency","frequency-analysis","gammatone-filterbanks","mfcc","music","music-information-retrieval","pitch","python","signal-processing","sound","speech-processing","time-frequency-analysis","voice"],"created_at":"2024-08-05T06:01:27.361Z","updated_at":"2024-11-22T21:30:57.945Z","avatar_url":"https://github.com/SuperKogito.png","language":"Python","readme":"![](https://github.com/SuperKogito/spafe/blob/master/media/logo.png?raw=true)\n\n# Spafe\n\nSimplified Python Audio Features Extraction\n\n[![Build Status](https://github.com/SuperKogito/spafe/actions/workflows/ci.yml/badge.svg)](https://github.com/SuperKogito/spafe/actions)\n[![docs.rs](https://img.shields.io/docsrs/docs)](https://superkogito.github.io/spafe/)\n[![License](https://img.shields.io/badge/license-BSD%203--Clause%20License%20(Revised)%20-blue)](https://github.com/SuperKogito/spafe/blob/master/LICENSE)\n[![Python](https://img.shields.io/badge/python-3.5%20%7C%203.6%20%7C%203.7%20%7C%203.8%20%7C%203.9%20%7C%203.10-blue)](https://www.python.org/doc/versions/)\n[![codecov](https://codecov.io/gh/SuperKogito/spafe/branch/master/graph/badge.svg)](https://codecov.io/gh/SuperKogito/spafe)\n[![codebeat badge](https://codebeat.co/badges/97f81ec3-b8a3-42ff-a9f5-f6cf165f4448)](https://codebeat.co/projects/github-com-superkogito-spafe-master)\n[![PyPI version](https://badge.fury.io/py/spafe.svg)](https://badge.fury.io/py/spafe)\n[![anaconda](https://anaconda.org/superkogito/spafe/badges/version.svg)](https://anaconda.org/SuperKogito/spafe)\n[![Downloads](https://pepy.tech/badge/spafe)](https://pepy.tech/project/spafe)\n[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.7686438.svg)](https://doi.org/10.5281/zenodo.7686438)\n[![DOI](https://joss.theoj.org/papers/10.21105/joss.04739/status.svg)](https://doi.org/10.21105/joss.04739)\n\n#  Table of Contents\n\n- [Spafe](#spafe)\n- [Table of Contents](#table-of-contents)\n- [Structure](#structure)\n  - [Filter banks](#filter-banks)\n  - [Spectrograms](#spectrograms)\n  - [Features](#features)\n  - [Frequencies](#frequencies)\n  - [Installation](#installation)\n    - [Dependencies](#dependencies)\n    - [Installation guide](#installation-guide)\n      - [Install from PyPI](#install-from-pypi)\n      - [Install from Anaconda](#install-from-anaconda)\n    - [Install from source](#install-from-source)\n  - [Why use Spafe?](#why-use-spafe)\n  - [How to use](#how-to-use)\n  - [Contributing](#contributing)\n  - [Citing](#citing)\n\n# Structure\nspafe aims to simplify feature extractions from **mono audio** files.\nSpafe includes various computations related to filter banks, spectrograms, frequencies and cepstral features .\nThe library has the following structure:\n![](https://github.com/SuperKogito/spafe/raw/master/media/spafe-structure.png)\n\n## Filter banks\n![](https://github.com/SuperKogito/spafe/blob/master/media/bark_fbanks.png?raw=true)\n  - Bark filter banks\n  - Gammatone filter banks\n  - Linear filter banks\n  - Mel filter banks\n\n## Spectrograms\n![](https://github.com/SuperKogito/spafe/blob/master/media/melspectrogram.png?raw=true)  \n  - Bark spectrogram\n  - CQT spectrogram\n  - Erb spectrogram\n  - Mel spectrogram\n\n## Features\n![](https://github.com/SuperKogito/spafe/blob/master/media/gfcc.png?raw=true)\n  - Bark Frequency Cepstral Coefﬁcients (BFCCs)\n  - Constant Q-transform Cepstral Coeﬃcients (CQCCs)\n  - Gammatone Frequency Cepstral Coefﬁcients (GFCCs)\n  - Linear Frequency Cepstral Coefﬁcients (LFCCs)\n  - Linear Prediction Components (LPCs)\n  - Mel Frequency Cepstral Coefﬁcients (MFCCs)\n  - Inverse Mel Frequency Cepstral Coefﬁcients (IMFCCs)\n  - Magnitude based Spectral Root Cepstral Coefficients (MSRCCs)\n  - Normalized Gammachirp Cepstral Coefficients (NGCCs)\n  - Power-Normalized Cepstral Coefficients (PNCCs)\n  - Phase based Spectral Root Cepstral Coefficients (PSRCCs)\n  - Perceptual Linear Prediction Coefficents (PLPs)\n  - Rasta Perceptual Linear Prediction Coefficents (RPLPs)\n\nThe theory behind features computed using spafe can be summmarized in the following graph:\n![](https://github.com/SuperKogito/spafe/blob/master/media/features-extraction-algorithms.png?raw=true)\n\n## Frequencies\n![](https://github.com/SuperKogito/spafe/blob/master/media/dominant_frequencies.png?raw=true)\n  - Dominant frequencies\n  - Fundamental frequencies\n\n## Installation\n### Dependencies\n\nspafe requires:\n\n-\t[Python](https://www.python.org/) (\u003e= 3.5)\n-\t[NumPy](https://numpy.org/) (\u003e= 1.22.0)\n-\t[SciPy](https://scipy.org/) (\u003e= 1.8.0)\n\nif you want to use the visualization module/ functions of spafe, you will need to install:\n\n- [Matplotlib](https://matplotlib.org/) (\u003e= 3.5.2)\n\n\n### Installation guide\nOnce you have the Dependencies installed, use one of the following install options.\n\n#### Install from PyPI\n- To freshly install spafe:\n```\npip install spafe\n```\n-  To update an existing installation:\n```\npip install -U spafe\n```\n\n#### Install from Anaconda\n- Spafe is also available on anaconda:\n```\nconda install spafe\n```\n\n### Install from source\n- You can build spafe from source, by following:\n```\ngit clone git@github.com:SuperKogito/spafe.git\ncd spafe\npython setup.py install\n```\n\n## Why use Spafe?\n\nUnlike most existing audio feature extraction libraries ([python_speech_features](https://github.com/jameslyons/python_speech_features), [SpeechPy](https://github.com/astorfi/speechpy), [surfboard](https://github.com/novoic/surfboard) and [Bob](https://gitlab.idiap.ch/bob)), Spafe provides more options for spectral features extraction algorithms, notably:\n- Bark Frequency Cepstral Coefﬁcients (BFCCs)\n- Constant Q-transform Cepstral Coeﬃcients (CQCCs)\n- Gammatone Frequency Cepstral Coefﬁcients (GFCCs)\n- Power-Normalized Cepstral Coefficients (PNCCs)\n- Phase based Spectral Root Cepstral Coefficients (PSRCCs)\n\nMost existing libraries and to their credits provide great implementations for features extraction but are unfortunately limited to the Mel Frequency Features (MFCC) and at best have Bark frequency and linear predictive coefficients additionally. [Librosa](https://github.com/librosa/librosa) for example includes great implementation of various algorithms (only MFCC and LPC are included), based on the **Short Time Fourrier Transform (STFT)**, which is theoretically more accurate but slower than the **Discret Fourrier Transform used in Spafe**'s implementation.\n\n\n## How to use\n\nVarious examples on how to use spafe are present in the documentation [https://superkogito.github.io/spafe](https://superkogito.github.io/spafe).\n\n\u003e !Please make sure you are referring to the correct documentation version.\n\n## Contributing\n\nContributions are welcome and encouraged. To learn more about how to contribute to spafe please refer to the [Contributing guidelines](https://github.com/SuperKogito/spafe/blob/master/CONTRIBUTING.md)\n\n## Citing\n\n-  **If you want to cite spafe as a software, please cite the version used as indexed in** [Zenodo](https://zenodo.org/):\n\n   *Ayoub Malek, Hadrien Titeux, Stefano Borzì, Christian Heider Nielsen, Fabian-Robert Stöter, Hervé Bredin, Eryk Urbański \u0026 Kevin Mattheus Moerman. (2023). SuperKogito/spafe: v0.3.3 (v0.3.3). Zenodo.* https://doi.org/10.5281/zenodo.11396240\n  \n   [![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.11396240.svg)](https://doi.org/10.5281/zenodo.11396240)\n \n\n- **You can also cite spafe's paper as follows:**\n\n  *Malek, A., (2023). Spafe: Simplified python audio features extraction. Journal of Open Source Software, 8(81), 4739,* https://doi.org/10.21105/joss.04739\n\n  [![DOI](https://joss.theoj.org/papers/10.21105/joss.04739/status.svg)](https://doi.org/10.21105/joss.04739)\n","funding_links":[],"categories":["Python","Audio Related Packages"],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FSuperKogito%2Fspafe","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FSuperKogito%2Fspafe","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FSuperKogito%2Fspafe/lists"}