├── .github └── workflows │ ├── doc.yml │ ├── linter.yml │ ├── publish.yml │ └── test.yml ├── .gitignore ├── .pre-commit-config.yaml ├── CHANGELOG.rst ├── CONTRIBUTING.rst ├── LICENSE ├── README.rst ├── docs ├── _templates │ └── autosummary │ │ ├── base.rst │ │ ├── class.rst │ │ └── function.rst ├── api-src │ └── opensmile.rst ├── changelog.rst ├── conf.py ├── contributing.rst ├── genindex.rst ├── index.rst ├── install.rst ├── requirements.txt └── usage.rst ├── opensmile ├── __init__.py └── core │ ├── __init__.py │ ├── bin │ ├── macosx_10_4_x86_64 │ │ ├── SMILExtract │ │ └── libSMILEapi.dylib │ ├── macosx_11_0_arm64 │ │ ├── SMILExtract │ │ └── libSMILEapi.dylib │ ├── manylinux_2_17_aarch64 │ │ ├── SMILExtract │ │ └── libSMILEapi.so │ ├── manylinux_2_17_armv7l │ │ ├── SMILExtract │ │ └── libSMILEapi.so │ ├── manylinux_2_17_x86_64 │ │ ├── SMILExtract │ │ └── libSMILEapi.so │ └── win_amd64 │ │ ├── SMILEapi.dll │ │ └── SMILExtract.exe │ ├── config.py │ ├── config │ ├── compare │ │ ├── ComParE_2016.conf │ │ ├── ComParE_2016_core.func.conf.inc │ │ ├── ComParE_2016_core.lld.conf.inc │ │ └── basic_functionals_2016.conf.inc │ ├── egemaps │ │ ├── v01a │ │ │ ├── eGeMAPSv01a.conf │ │ │ ├── eGeMAPSv01a_core.func.conf.inc │ │ │ └── eGeMAPSv01a_core.lld.conf.inc │ │ ├── v01b │ │ │ ├── eGeMAPSv01b.conf │ │ │ ├── eGeMAPSv01b_core.func.conf.inc │ │ │ └── eGeMAPSv01b_core.lld.conf.inc │ │ └── v02 │ │ │ ├── eGeMAPSv02.conf │ │ │ ├── eGeMAPSv02_core.func.conf.inc │ │ │ └── eGeMAPSv02_core.lld.conf.inc │ ├── emobase │ │ └── emobase.conf │ ├── gemaps │ │ ├── v01a │ │ │ ├── GeMAPSv01a.conf │ │ │ ├── GeMAPSv01a_core.func.conf.inc │ │ │ └── GeMAPSv01a_core.lld.conf.inc │ │ └── v01b │ │ │ ├── GeMAPSv01b.conf │ │ │ ├── GeMAPSv01b_core.func.conf.inc │ │ │ └── GeMAPSv01b_core.lld.conf.inc │ └── shared │ │ ├── BufferMode.conf.inc │ │ ├── BufferModeRb.conf.inc │ │ ├── BufferModeRbLag.conf.inc │ │ ├── BufferModeRbMulti.conf.inc │ │ ├── FrameModeFunctionals.conf.inc │ │ ├── FrameModeFunctionalsMulti.conf.inc │ │ ├── standard_data_output.conf.inc │ │ ├── standard_data_output_no_lld_de.conf.inc │ │ ├── standard_external_data_output_multi.conf.inc │ │ ├── standard_external_data_output_single.conf.inc │ │ ├── standard_external_wave_input.conf.inc │ │ └── standard_wave_input.conf.inc │ ├── define.py │ ├── lib.py │ └── smile.py ├── pyproject.toml ├── requirements.txt ├── setup.py └── tests ├── conftest.py ├── requirements.txt ├── test.conf ├── test.wav └── test_smile.py /.github/workflows/doc.yml: -------------------------------------------------------------------------------- 1 | name: Documentation 2 | 3 | on: 4 | push: 5 | branches: [ main ] 6 | pull_request: 7 | branches: [ main ] 8 | 9 | jobs: 10 | build: 11 | 12 | runs-on: ${{ matrix.os }} 13 | strategy: 14 | matrix: 15 | os: [ ubuntu-latest ] 16 | python-version: [ '3.10' ] 17 | 18 | steps: 19 | - uses: actions/checkout@v4 20 | 21 | - name: Set up Python ${{ matrix.python-version }} 22 | uses: actions/setup-python@v5 23 | with: 24 | python-version: ${{ matrix.python-version }} 25 | 26 | - name: Install package 27 | run: | 28 | python -m pip install --upgrade pip 29 | pip install -r requirements.txt 30 | 31 | - name: Install docs requirements 32 | run: pip install -r docs/requirements.txt 33 | 34 | - name: Test building documentation 35 | run: python -m sphinx docs/ docs/_build/ -b html -W 36 | 37 | - name: Check links in documentation 38 | run: python -m sphinx docs/ docs/_build/ -b linkcheck -W 39 | -------------------------------------------------------------------------------- /.github/workflows/linter.yml: -------------------------------------------------------------------------------- 1 | name: Linter 2 | 3 | on: 4 | push: 5 | branches: [ main ] 6 | pull_request: 7 | branches: [ main ] 8 | 9 | jobs: 10 | build: 11 | 12 | runs-on: ubuntu-latest 13 | 14 | steps: 15 | - uses: actions/checkout@v4 16 | 17 | - name: Set up Python 3.10 18 | uses: actions/setup-python@v5 19 | with: 20 | python-version: '3.10' 21 | 22 | - name: Install pre-commit hooks 23 | run: | 24 | pip install pre-commit 25 | pre-commit install --install-hooks 26 | 27 | - name: Code style check via pre-commit 28 | run: | 29 | pre-commit run --all-files 30 | -------------------------------------------------------------------------------- /.github/workflows/publish.yml: -------------------------------------------------------------------------------- 1 | name: Publish 2 | 3 | on: 4 | push: 5 | tags: 6 | - 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10 7 | 8 | jobs: 9 | build: 10 | 11 | runs-on: 'ubuntu-latest' 12 | environment: release 13 | permissions: 14 | contents: write 15 | id-token: write 16 | strategy: 17 | matrix: 18 | platform: 19 | - macosx_10_4_x86_64 20 | - macosx_11_0_arm64 21 | - manylinux_2_17_aarch64 22 | - manylinux_2_17_armv7l 23 | - manylinux_2_17_x86_64 24 | - win_amd64 25 | 26 | steps: 27 | - uses: actions/checkout@v4 28 | # Need more than a shallow clone to get version from tags 29 | with: 30 | fetch-depth: 2 31 | 32 | - name: Set up Python 33 | uses: actions/setup-python@v5 34 | with: 35 | python-version: '3.10' 36 | 37 | - name: Install build dependencies 38 | run: | 39 | python -m pip install --upgrade pip 40 | pip install build virtualenv 41 | 42 | - name: Build wheels 43 | run: python -m build --wheel --outdir wheelhouse 44 | env: 45 | PLAT_NAME: ${{ matrix.platform }} 46 | 47 | - name: Build source distribution 48 | run: python -m build --sdist --outdir wheelhouse 49 | if: matrix.platform == 'manylinux_2_17_x86_64' 50 | 51 | - uses: actions/upload-artifact@v4 52 | with: 53 | name: ${{ matrix.platform }} 54 | path: ./wheelhouse/* 55 | 56 | deploy: 57 | 58 | runs-on: 'ubuntu-latest' 59 | needs: [ build ] 60 | environment: release 61 | permissions: 62 | contents: write 63 | id-token: write 64 | 65 | steps: 66 | 67 | - name: Clone repository 68 | uses: actions/checkout@v4 69 | # Need depth to get diff for changelog 70 | with: 71 | fetch-depth: 1 72 | 73 | - name: Download dist artifacts 74 | uses: actions/download-artifact@v4 75 | with: 76 | name: ${{ matrix.platform }} 77 | path: wheelhouse 78 | merge-multiple: true 79 | 80 | - name: Set up Python 81 | uses: actions/setup-python@v5 82 | with: 83 | python-version: '3.10' 84 | 85 | - name: Install dependencies 86 | run: | 87 | python -m pip install --upgrade pip 88 | pip install build virtualenv 89 | 90 | # PyPI package 91 | - name: Build Python package 92 | run: python -m build 93 | 94 | - name: Publish Python package to PyPI 95 | uses: pypa/gh-action-pypi-publish@release/v1 96 | with: 97 | packages-dir: wheelhouse/ 98 | 99 | # Documentation 100 | - name: Setup Ubuntu 101 | run: | 102 | sudo apt-get update 103 | sudo apt-get -y install libsndfile1 sox 104 | 105 | - name: Install doc dependencies 106 | run: | 107 | python -m pip install --upgrade pip 108 | pip install -r requirements.txt 109 | pip install -r docs/requirements.txt 110 | 111 | - name: Build documentation 112 | run: | 113 | python -m sphinx docs/ docs/_build/ -b html 114 | 115 | - name: Deploy documentation to Github pages 116 | uses: peaceiris/actions-gh-pages@v4 117 | with: 118 | github_token: ${{ secrets.GITHUB_TOKEN }} 119 | publish_dir: ./docs/_build 120 | 121 | # Github release 122 | - name: Read CHANGELOG 123 | id: changelog 124 | run: | 125 | # Get bullet points from last CHANGELOG entry 126 | CHANGELOG=$(git diff -U0 HEAD^ HEAD | grep '^[+][\* ]' | sed 's/\+//') 127 | echo "Got changelog: $CHANGELOG" 128 | # Support for multiline, see 129 | # https://docs.github.com/en/actions/using-workflows/workflow-commands-for-github-actions#multiline-strings 130 | { 131 | echo 'body<> "$GITHUB_OUTPUT" 135 | 136 | - name: Create release on Github 137 | id: create_release 138 | uses: softprops/action-gh-release@v2 139 | env: 140 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} 141 | with: 142 | tag_name: ${{ github.ref }} 143 | name: Release ${{ github.ref_name }} 144 | body: ${{ steps.changelog.outputs.body }} 145 | -------------------------------------------------------------------------------- /.github/workflows/test.yml: -------------------------------------------------------------------------------- 1 | name: Test 2 | 3 | on: 4 | push: 5 | branches: [ main ] 6 | pull_request: 7 | branches: [ main ] 8 | 9 | jobs: 10 | build: 11 | 12 | runs-on: ${{ matrix.os }} 13 | strategy: 14 | matrix: 15 | os: [ ubuntu-latest, windows-latest, macos-latest ] 16 | python-version: [ '3.9', '3.10', '3.11', '3.12', '3.13' ] 17 | 18 | steps: 19 | - uses: actions/checkout@v4 20 | 21 | - name: Set up Python ${{ matrix.python-version }} 22 | uses: actions/setup-python@v5 23 | with: 24 | python-version: ${{ matrix.python-version }} 25 | 26 | - name: Setup Ubuntu 27 | run: | 28 | sudo apt-get update 29 | sudo apt-get -y install libsndfile1 sox 30 | if: matrix.os == 'ubuntu-latest' 31 | 32 | - name: Install dependencies 33 | run: | 34 | python -m pip install --upgrade pip 35 | pip install -r requirements.txt 36 | pip install -r tests/requirements.txt 37 | 38 | - name: Test with pytest 39 | run: | 40 | python -m pytest 41 | 42 | - name: Upload coverage to Codecov 43 | uses: codecov/codecov-action@v4 44 | with: 45 | token: ${{ secrets.CODECOV_TOKEN }} 46 | file: ./coverage.xml 47 | if: matrix.os == 'ubuntu-latest' 48 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | __pycache__ 2 | *.egg-info/ 3 | .eggs/ 4 | build/ 5 | dist/ 6 | .idea/ 7 | venv/ 8 | simle.log 9 | .coverage 10 | docs/api/ 11 | -------------------------------------------------------------------------------- /.pre-commit-config.yaml: -------------------------------------------------------------------------------- 1 | # Configuration of checks run by pre-commit 2 | # 3 | # The tests are executed in the CI pipeline, 4 | # see CONTRIBUTING.rst for further instructions. 5 | # You can also run the checks directly at the terminal, e.g. 6 | # 7 | # $ pre-commit install 8 | # $ pre-commit run --all-files 9 | # 10 | # 11 | default_language_version: 12 | python: python3.10 13 | 14 | repos: 15 | - repo: https://github.com/astral-sh/ruff-pre-commit 16 | rev: v0.7.0 17 | hooks: 18 | - id: ruff 19 | args: [ --fix ] 20 | - id: ruff-format 21 | - repo: https://github.com/codespell-project/codespell 22 | rev: v2.3.0 23 | hooks: 24 | - id: codespell 25 | additional_dependencies: 26 | - tomli 27 | -------------------------------------------------------------------------------- /CHANGELOG.rst: -------------------------------------------------------------------------------- 1 | Changelog 2 | ========= 3 | 4 | All notable changes to this project will be documented in this file. 5 | 6 | The format is based on `Keep a Changelog`_, 7 | and this project adheres to `Semantic Versioning`_. 8 | 9 | 10 | Version 2.5.1 (2024-12-16) 11 | -------------------------- 12 | 13 | * Added: support for Python 3.12 14 | * Added: support for Python 3.13 15 | * Removed: support for Python 3.8 16 | 17 | 18 | Version 2.5.0 (2023-10-19) 19 | -------------------------- 20 | 21 | * Added: support for ``manylinux_2_17_armv7l`` aka Raspberry PI 22 | * Added: support for ``manylinux_2_17_aarch64`` 23 | * Added: support for ``macosx_11_0_arm64`` aka M1 24 | * Added: support for Python 3.11 25 | * Added: support for Python 3.10 26 | * Changed: use binaries from ``opensmile`` v3.0.2 27 | * Changed: build platform dependent wheels 28 | to reduce installation size 29 | * Removed: support for Python 3.7 30 | 31 | 32 | Version 2.4.2 (2023-01-03) 33 | -------------------------- 34 | 35 | * Added: support for Python 3.9 36 | * Changed: split API documentation into sub-pages 37 | for each function 38 | * Removed: support for Python 3.6 39 | 40 | 41 | Version 2.4.1 (2022-01-10) 42 | -------------------------- 43 | 44 | * Changed: switch to ``Python 3.8`` during publishing 45 | 46 | 47 | Version 2.4.0 (2022-01-10) 48 | -------------------------- 49 | 50 | * Added: ``multiprocessing`` argument to ``Smile`` 51 | * Changed: update binaries to ``3.0.1`` to support multi-threading 52 | 53 | 54 | Version 2.3.0 (2021-12-16) 55 | -------------------------- 56 | 57 | * Changed: update to ``audobject >0.6.1`` 58 | 59 | 60 | Version 2.2.0 (2021-07-23) 61 | -------------------------- 62 | 63 | * Fixed: ``Smile.__call__()`` always returns (channels, features, frames) 64 | 65 | 66 | Version 2.1.3 (2021-07-06) 67 | -------------------------- 68 | 69 | * Fixed: include ``emobase`` config files into package 70 | 71 | 72 | Version 2.1.2 (2021-06-21) 73 | -------------------------- 74 | 75 | * Fixed: short underline in CHANGELOG 76 | 77 | 78 | Version 2.1.1 (2021-06-18) 79 | -------------------------- 80 | 81 | * Changed: enable Windows tests again 82 | 83 | 84 | Version 2.1.0 (2021-06-16) 85 | -------------------------- 86 | 87 | * Added: ``channels``, ``mixdown``, ``resample`` argument 88 | * Added: support for ``audformat`` 89 | * Changed: disable Windows tests 90 | * Changed: dependency to ``audinterface`` and ``audobject`` 91 | * Changed: use ``emodb`` in usage section 92 | * Removed: static files from docs 93 | 94 | 95 | Version 2.0.2 (2021-05-14) 96 | -------------------------- 97 | 98 | * Fixed: building docs in publish workflow 99 | 100 | 101 | Version 2.0.1 (2021-05-14) 102 | -------------------------- 103 | 104 | * Added: ``FeatureSet.emobase`` 105 | 106 | 107 | Version 2.0.0 (2021-02-12) 108 | -------------------------- 109 | 110 | WARNING: Introduces a breaking change by changing the number of LLDs 111 | in all sets of the GeMAPS family and removing support for deltas 112 | in those sets. 113 | 114 | * Added: ``FeatureSet.eGeMAPSv02`` 115 | * Changed: add ``lld_de`` features to ``lld`` for the GeMAPS family 116 | * Changed: raise error if ``lld_de`` is requested for a set of the GeMAPS family 117 | 118 | 119 | Version 1.0.1 (2020-10-23) 120 | -------------------------- 121 | 122 | * Fixed: add missing binaries to wheel 123 | * Fixed: building docs in publish workflow 124 | * Fixed: link to documentation in badge 125 | 126 | 127 | Version 1.0.0 (2020-10-23) 128 | -------------------------- 129 | 130 | * Added: initial release using openSMILE 3.0 131 | 132 | 133 | .. _Keep a Changelog: https://keepachangelog.com/en/1.0.0/ 134 | .. _Semantic Versioning: https://semver.org/spec/v2.0.0.html 135 | -------------------------------------------------------------------------------- /CONTRIBUTING.rst: -------------------------------------------------------------------------------- 1 | Contributing 2 | ============ 3 | 4 | Everyone is invited to contribute to this project. 5 | Feel free to create a `pull request`_ . 6 | If you find errors, omissions, inconsistencies or other things 7 | that need improvement, please create an issue_. 8 | 9 | .. _issue: https://github.com/audeering/opensmile-python/issues/new/ 10 | .. _pull request: https://github.com/audeering/opensmile-python/compare/ 11 | 12 | 13 | Development Installation 14 | ------------------------ 15 | 16 | Instead of pip-installing the latest release from PyPI_, 17 | you should get the newest development version from Github_:: 18 | 19 | git clone https://github.com/audeering/opensmile-python/ 20 | cd opensmile-python 21 | # Create virtual environment for this project 22 | # e.g. 23 | # virtualenv --python="python3" $HOME/.envs/opensmile-python 24 | # source $HOME/.envs/opensmile-python/bin/activate 25 | pip install -r requirements.txt 26 | 27 | 28 | This way, 29 | your installation always stays up-to-date, 30 | even if you pull new changes from the Github repository. 31 | 32 | .. _PyPI: https://pypi.org/project/opensmile/ 33 | .. _Github: https://github.com/audeering/opensmile-python/ 34 | 35 | 36 | Coding Convention 37 | ----------------- 38 | 39 | We follow the PEP8_ convention for Python code 40 | and use ruff_ as a linter and code formatter. 41 | In addition, 42 | we check for common spelling errors with codespell_. 43 | Both tools and possible exceptions 44 | are defined in :file:`pyproject.toml`. 45 | 46 | The checks are executed in the CI using `pre-commit`_. 47 | You can enable those checks locally by executing:: 48 | 49 | pip install pre-commit # consider system wide installation 50 | pre-commit install 51 | pre-commit run --all-files 52 | 53 | Afterwards ruff_ and codespell_ are executed 54 | every time you create a commit. 55 | 56 | You can also install ruff_ and codespell_ 57 | and call it directly:: 58 | 59 | pip install ruff codespell # consider system wide installation 60 | ruff check --fix . # lint all Python files, and fix any fixable errors 61 | ruff format . # format code of all Python files 62 | codespell 63 | 64 | It can be restricted to specific folders:: 65 | 66 | ruff check opensmile/ tests/ 67 | codespell opensmile/ tests/ 68 | 69 | 70 | .. _codespell: https://github.com/codespell-project/codespell/ 71 | .. _PEP8: http://www.python.org/dev/peps/pep-0008/ 72 | .. _pre-commit: https://pre-commit.com 73 | .. _ruff: https://beta.ruff.rs 74 | 75 | 76 | Building the Documentation 77 | -------------------------- 78 | 79 | If you make changes to the documentation, 80 | you can re-create the HTML pages using Sphinx_. 81 | You can install it and a few other necessary packages with:: 82 | 83 | pip install -r docs/requirements.txt 84 | 85 | To create the HTML pages, use:: 86 | 87 | python -m sphinx docs/ build/sphinx/html -b html 88 | 89 | The generated files will be available 90 | in the directory :file:`build/sphinx/html/`. 91 | 92 | It is also possible to automatically check if all links are still valid:: 93 | 94 | python -m sphinx docs/ build/sphinx/html -b linkcheck 95 | 96 | .. _Sphinx: http://sphinx-doc.org 97 | 98 | 99 | Running the Tests 100 | ----------------- 101 | 102 | You'll need pytest_ for that. 103 | It can be installed with:: 104 | 105 | pip install -r tests/requirements.txt 106 | 107 | To execute the tests, simply run:: 108 | 109 | python -m pytest 110 | 111 | .. _pytest: https://pytest.org 112 | 113 | 114 | Creating a New Release 115 | ---------------------- 116 | 117 | New releases are made using the following steps: 118 | 119 | #. Update ``CHANGELOG.rst`` 120 | #. Commit those changes as "Release X.Y.Z" 121 | #. Create an (annotated) tag with ``git tag -a X.Y.Z`` 122 | #. Push the commit and the tag to Github 123 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | openSMILE 2 | - open-source Speech and Music Interpretation by Large-space Extraction - 3 | 4 | Copyright (c) audEERING GmbH, Gilching, Germany. All rights reserved. 5 | http://www.audeering.com/ 6 | 7 | Copyright (c) 2016-2020, audEERING GmbH 8 | Copyright (c) 2013-2015, audEERING UG (haftungsbeschraenkt) 9 | Copyright (c) 2008-2013, Institute for Human-Machine Communication, 10 | Technische Universitaet Muenchen, Germany 11 | 12 | Licensing terms & your rights 13 | ============================= 14 | 15 | ********************************************************************** 16 | If you use openSMILE or any code from openSMILE in your research work, 17 | you are kindly asked to acknowledge the use of openSMILE in your 18 | publications. See the file CITING for details. 19 | ********************************************************************** 20 | 21 | This audEERING Research License Agreement (license, license agreement, 22 | or agreement in the ongoing), is a legal agreement between you 23 | and audEERING GmbH, Gilching, Germany (audEERING or we in the following) 24 | for the software or data identified above, which may include source code, 25 | and any associated materials, text or speech files, 26 | associated media and "online" or electronic documentation 27 | (together, the "Software"). 28 | 29 | By installing, copying, or otherwise using this Software, 30 | you agree to be bound by the terms in this license. 31 | If you do not agree, you may not install, copy or use the Software. 32 | The Software is protected by copyright and other intellectual 33 | property laws and is licensed, not sold. 34 | 35 | This license grants you the following rights: 36 | A. You may use, copy, reproduce, and distribute this Software 37 | for any non-commercial purpose, subject to the restrictions 38 | set out below. Some purposes which can be non-commercial are teaching, 39 | academic research, public demonstrations and personal experimentation 40 | or personal home use. You may also distribute this Software with 41 | books or other teaching materials, or publish the Software on websites, 42 | that are intended to teach the use of the Software for academic or 43 | other non-commercial purposes. 44 | You may NOT use or distribute this Software or any derivative works 45 | in any form for commercial purposes, except those outlined in (B). 46 | Examples of commercial purposes are running business operations, 47 | licensing, leasing, or selling the Software, distributing the 48 | Software for use with commercial products (no matter whether free or paid), 49 | using the Software in the creation or use of commercial products or any 50 | other activity which purpose is to procure a commercial gain to you or 51 | others (except for conditions set out in (B)). 52 | B. Further, you may use the software for commercial research, which meets 53 | the following conditions: commercial research which is not directly 54 | associated with product development and has the primary purpose of 55 | publishing and sharing results with the academic world; pre-product 56 | evaluations of algorithms and methods, as long as these evaluations 57 | are more of an evaluatory, planning, and research nature than 58 | of a product development nature. 59 | Any further commercial use requires you to obtain a commercial 60 | license or written approval from audEERING GmbH which grants 61 | you extended usage rights for this software. In particular any direct 62 | (software) or indirect (models, features extracted with the software) 63 | use of the software, parts of the software, or derivatives in a 64 | product (no matter whether free or paid), is not allowed without 65 | an additional commercial license. 66 | C. If the software includes source code or data, you may create 67 | derivative works of such portions of the software and distribute the 68 | modified software for non-commercial purposes, as provided herein. 69 | If you distribute the software or any derivative works of the Software, 70 | you must distribute them under the same terms and conditions as in this 71 | license, and you must not grant other rights to the software or 72 | derivative works that are different from those provided by this 73 | license agreement. 74 | If you have created derivative works of the software, and distribute 75 | such derivative works, you will cause the modified files to carry 76 | prominent notices so that recipients know that they are not receiving 77 | the original software. Such notices must state: 78 | (i) that you have altered the software; 79 | and (ii) the date of any changes as well as your name. 80 | 81 | In return for the above rights, you agree: 82 | 1. That you will not remove any copyright or other notices (authors 83 | and citing information, for example) from the software. 84 | 2. That if any of the software is in binary format, you will not attempt 85 | to modify such portions of the software, or to reverse engineer or 86 | decompile them, except and only to the extent authorized by applicable 87 | law. 88 | 3. That the copyright holders (audEERING) are granted back, 89 | without any restrictions or limitations, a non-exclusive, perpetual, 90 | irrevocable, royalty-free, assignable and sub-licensable license, 91 | to reproduce, publicly perform or display, install, use, modify, post, 92 | distribute, make and have made, sell and transfer your modifications 93 | to and/or derivative works of the software source code or data, 94 | for any purpose. 95 | 4. That any feedback about the software provided by you to us is voluntarily 96 | given, and audEERING shall be free to use the feedback 97 | as they see fit without obligation or restriction of any kind, 98 | even if the feedback is designated by you as confidential. 99 | 100 | 5. THAT THE SOFTWARE COMES "AS IS", WITH NO WARRANTIES. 101 | THIS MEANS NO EXPRESS, IMPLIED OR STATUTORY WARRANTY, INCLUDING 102 | WITHOUT LIMITATION, WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A 103 | PARTICULAR PURPOSE, ANY WARRANTY AGAINST INTERFERENCE WITH YOUR 104 | ENJOYMENT OF THE SOFTWARE OR ANY WARRANTY OF TITLE OR NON-INFRINGEMENT. 105 | THERE IS NO WARRANTY THAT THIS SOFTWARE WILL FULFILL ANY OF YOUR 106 | PARTICULAR PURPOSES OR NEEDS. ALSO, YOU MUST PASS THIS DISCLAIMER ON 107 | WHENEVER YOU DISTRIBUTE THE SOFTWARE OR DERIVATIVE WORKS. 108 | 109 | 6. THAT NEITHER AUDEERING NOR ANY AUTHOR OR CONTRIBUTOR TO THE 110 | SOFTWARE WILL BE LIABLE FOR ANY DAMAGES RELATED TO THE SOFTWARE OR THIS 111 | LICENSE, INCLUDING DIRECT, INDIRECT, SPECIAL, CONSEQUENTIAL OR INCIDENTAL 112 | DAMAGES, TO THE MAXIMUM EXTENT THE LAW PERMITS, NO MATTER WHAT LEGAL 113 | THEORY IT IS BASED ON. ALSO, YOU MUST PASS THIS LIMITATION OF LIABILITY 114 | ON WHENEVER YOU DISTRIBUTE THE SOFTWARE OR DERIVATIVE WORKS. 115 | 116 | 7. That we have no duty of reasonable care or lack of negligence, 117 | and we are not obligated to (and will not) provide technical support for 118 | the Software. 119 | 8. That if you breach this license agreement or if you sue anyone over 120 | patents that you think may apply to or read on the software or anyone's 121 | use of the software, this license agreement (and your license and rights 122 | obtained herein) terminate automatically. Upon any such termination, 123 | you shall destroy all of your copies of the software immediately. 124 | Sections 3, 4, 5, 6, 7, 10 and 11 of this license agreement shall survive 125 | any termination of this license agreement. 126 | 9. That the patent rights, if any, granted to you in this license agreement 127 | only apply to the software, not to any derivative works you make. 128 | 10.That the software may be subject to European export or import laws or such 129 | laws in other places. You agree to comply with all such laws and regulations 130 | that may apply to the software after the delivery of the software to you. 131 | 11.That all rights not expressly granted to you in this license agreement 132 | are reserved by audEERING. 133 | 12.That this license agreement shall be construed and controlled by the laws 134 | of the Federal Republic of Germany, without regard to conflicts of law. 135 | If any provision of this license agreement shall be deemed unenforceable 136 | or contrary to law, the rest of this license agreement shall remain in 137 | full effect and interpreted in an enforceable manner that most closely 138 | captures the intent of the original language. 139 | 140 | 141 | Commercial license options 142 | ========================== 143 | 144 | For commercial and other licensing options, please contact us at audEERING 145 | via e-mail: 146 | 147 | info@audeering.com 148 | 149 | 150 | Third-party contributions and dependencies 151 | ========================================== 152 | 153 | openSMILE uses a number of third-party components for which you can 154 | find the licensing terms in the folder "licenses". 155 | 156 | As part of the build process, a number of third-party CMake modules 157 | are used. Please see the license notices in the folder "cmake". 158 | -------------------------------------------------------------------------------- /README.rst: -------------------------------------------------------------------------------- 1 | ================ 2 | openSMILE Python 3 | ================ 4 | 5 | |tests| |coverage| |docs| |python-versions| |license| 6 | 7 | Python interface for extracting openSMILE_ features. 8 | 9 | .. code-block:: 10 | 11 | $ pip install opensmile 12 | 13 | .. note:: Only 64-bit Python is supported. 14 | 15 | Feature sets 16 | ------------ 17 | 18 | Currently, three standard sets are supported. 19 | `ComParE 2016`_ is the largest with more than 6k features. 20 | The smaller sets GeMAPS_ and eGeMAPS_ 21 | come in variants ``v01a``, ``v01b`` and ``v02`` (only eGeMAPS_). 22 | We suggest to use the latest version 23 | unless backward compatibility with 24 | the original papers is desired. 25 | 26 | Each feature set can be extracted on two levels: 27 | 28 | * Low-level descriptors (LDD) 29 | * Functionals 30 | 31 | For `ComParE 2016`_ a third level is available: 32 | 33 | * LLD deltas 34 | 35 | .. note:: Pre v2.0.0 some LLDs of the GeMAPS family were incorrectly output 36 | as deltas. This was corrected with v2.0.0 and these features are now 37 | correctly returned as LLDs. Note that with v2.0.0 deltas are no 38 | longer available for the GeMAPS family. 39 | 40 | The following table lists the number of features 41 | for each set and level. 42 | 43 | With v2.0.0 44 | ~~~~~~~~~~~ 45 | 46 | ============ ============== 47 | Name #features 48 | ============ ============== 49 | ComParE_2016 65 / 65 / 6373 50 | GeMAPSv01a 18 / - / 62 51 | GeMAPSv01b 18 / - / 62 52 | eGeMAPSv01a 23 / - / 88 53 | eGeMAPSv01b 23 / - / 88 54 | eGeMAPSv02 25 / - / 88 55 | ============ ============== 56 | 57 | .. note:: Additional feature sets have been added by the community. 58 | For a full list please see the documentation of ``opensmile.FeatureSet``. 59 | 60 | Pre v2.0.0 61 | ~~~~~~~~~~ 62 | 63 | ============ ============== 64 | Name #features 65 | ============ ============== 66 | ComParE_2016 65 / 65 / 6373 67 | GeMAPSv01a 5 / 13 / 62 68 | GeMAPSv01b 5 / 13 / 62 69 | eGeMAPSv01a 10 / 13 / 88 70 | eGeMAPSv01b 10 / 13 / 88 71 | ============ ============== 72 | 73 | Code example 74 | ------------ 75 | 76 | Code example, 77 | that extracts `ComParE 2016`_ functionals from an audio file: 78 | 79 | .. code-block:: python 80 | 81 | import opensmile 82 | 83 | smile = opensmile.Smile( 84 | feature_set=opensmile.FeatureSet.ComParE_2016, 85 | feature_level=opensmile.FeatureLevel.Functionals, 86 | ) 87 | y = smile.process_file('audio.wav') 88 | 89 | License 90 | ------- 91 | 92 | openSMILE follows a dual-licensing model. Since the main goal of the project 93 | is a widespread use of the software to facilitate research in the field of 94 | machine learning from audio-visual signals, the source code and binaries are 95 | freely available for private, research, and educational use under an open-source license 96 | (see LICENSE). 97 | It is not allowed to use the open-source version of openSMILE for any sort of commercial product. 98 | Fundamental research in companies, for example, is permitted, but if a product is the result of 99 | the research, we require you to buy a commercial development license. 100 | Contact us at info@audeering.com (or visit us at https://www.audeering.com) for more information. 101 | 102 | Original authors: Florian Eyben, Felix Weninger, Martin Wöllmer, Björn Schuller 103 | 104 | Copyright © 2008-2013, Institute for Human-Machine Communication, Technische Universität München, Germany 105 | 106 | Copyright © 2013-2015, audEERING UG (haftungsbeschränkt) 107 | 108 | Copyright © 2016-2020, audEERING GmbH 109 | 110 | Citing 111 | ------ 112 | 113 | Please cite openSMILE in your publications by citing the following paper: 114 | 115 | Florian Eyben, Martin Wöllmer, Björn Schuller: "openSMILE - The Munich Versatile and Fast Open-Source Audio Feature Extractor", Proc. ACM Multimedia (MM), ACM, Florence, Italy, ISBN 978-1-60558-933-6, pp. 1459-1462, 25.-29.10.2010. 116 | 117 | 118 | .. _openSMILE: https://github.com/audeering/opensmile 119 | .. _ComParE 2016: http://www.tangsoo.de/documents/Publications/Schuller16-TI2.pdf 120 | .. _GeMAPS: https://sail.usc.edu/publications/files/eyben-preprinttaffc-2015.pdf 121 | .. _eGeMAPS: https://sail.usc.edu/publications/files/eyben-preprinttaffc-2015.pdf 122 | .. _audformat: https://github.com/audeering/audformat 123 | 124 | .. badges images and links: 125 | .. |tests| image:: https://github.com/audeering/opensmile-python/workflows/Test/badge.svg 126 | :target: https://github.com/audeering/opensmile-python/actions?query=workflow%3ATest 127 | :alt: Test status 128 | .. |coverage| image:: https://codecov.io/gh/audeering/opensmile-python/branch/main/graph/badge.svg?token=PUA9P2UJW1 129 | :target: https://codecov.io/gh/audeering/opensmile-python 130 | :alt: code coverage 131 | .. |docs| image:: https://img.shields.io/pypi/v/opensmile?label=docs 132 |    :target: https://audeering.github.io/opensmile-python/ 133 |    :alt: opensmile's documentation 134 | .. |license| image:: https://img.shields.io/badge/license-audEERING-red.svg 135 |    :target: https://github.com/audeering/opensmile-python/blob/main/LICENSE 136 |    :alt: opensmile's audEERING license 137 | .. |python-versions| image:: https://img.shields.io/pypi/pyversions/opensmile.svg 138 | :target: https://pypi.org/project/opensmile/ 139 | :alt: opensmile's supported Python versions 140 | -------------------------------------------------------------------------------- /docs/_templates/autosummary/base.rst: -------------------------------------------------------------------------------- 1 | {{ name | escape | underline}} 2 | 3 | .. currentmodule:: {{ module }} 4 | 5 | .. auto{{ objtype }}:: {{ fullname }} 6 | -------------------------------------------------------------------------------- /docs/_templates/autosummary/class.rst: -------------------------------------------------------------------------------- 1 | {{ objname | escape | underline}} 2 | 3 | .. currentmodule:: {{ module }} 4 | 5 | .. autoclass:: {{ objname }} 6 | 7 | {% block methods %} 8 | {%- for item in (all_methods + attributes)|sort %} 9 | {%- if not item.startswith('_') or item in ['__call__'] %} 10 | {%- if item in all_methods %} 11 | {{ (item + '()') | escape | underline(line='-') }} 12 | .. automethod:: {{ name }}.{{ item }} 13 | {%- elif item in attributes %} 14 | {{ item | escape | underline(line='-') }} 15 | .. autoattribute:: {{ name }}.{{ item }} 16 | {%- endif %} 17 | {% endif %} 18 | {%- endfor %} 19 | {% endblock %} 20 | -------------------------------------------------------------------------------- /docs/_templates/autosummary/function.rst: -------------------------------------------------------------------------------- 1 | {{ (name + '()') | escape | underline}} 2 | 3 | .. currentmodule:: {{ module }} 4 | 5 | .. auto{{ objtype }}:: {{ fullname }} 6 | -------------------------------------------------------------------------------- /docs/api-src/opensmile.rst: -------------------------------------------------------------------------------- 1 | opensmile 2 | ========= 3 | 4 | .. automodule:: opensmile 5 | 6 | .. autosummary:: 7 | :toctree: 8 | :nosignatures: 9 | 10 | config 11 | FeatureLevel 12 | FeatureSet 13 | Smile 14 | -------------------------------------------------------------------------------- /docs/changelog.rst: -------------------------------------------------------------------------------- 1 | .. include:: ../CHANGELOG.rst 2 | -------------------------------------------------------------------------------- /docs/conf.py: -------------------------------------------------------------------------------- 1 | from datetime import date 2 | import os 3 | import shutil 4 | 5 | import toml 6 | 7 | import audeer 8 | 9 | 10 | config = toml.load(audeer.path("..", "pyproject.toml")) 11 | 12 | 13 | # Project ----------------------------------------------------------------- 14 | 15 | project = config["project"]["name"] 16 | author = ", ".join(author["name"] for author in config["project"]["authors"]) 17 | copyright = f"2020-{date.today().year} audEERING GmbH" 18 | version = audeer.git_repo_version() 19 | title = "Documentation" 20 | 21 | 22 | # General ----------------------------------------------------------------- 23 | 24 | master_doc = "index" 25 | source_suffix = ".rst" 26 | exclude_patterns = [ 27 | "api-src", 28 | "build", 29 | "tests", 30 | "Thumbs.db", 31 | ".DS_Store", 32 | ] 33 | templates_path = ["_templates"] 34 | pygments_style = None 35 | extensions = [ 36 | "jupyter_sphinx", # executing code blocks 37 | "sphinx.ext.autodoc", 38 | "sphinx.ext.napoleon", # support for Google-style docstrings 39 | "sphinx.ext.autosummary", 40 | "sphinx.ext.viewcode", 41 | "sphinx.ext.intersphinx", 42 | "sphinx.ext.autosectionlabel", 43 | "sphinx_autodoc_typehints", 44 | "sphinx_copybutton", # for "copy to clipboard" buttons 45 | ] 46 | 47 | napoleon_use_ivar = True # List of class attributes 48 | autodoc_inherit_docstrings = False # disable docstring inheritance 49 | 50 | intersphinx_mapping = { 51 | "python": ("https://docs.python.org/3/", None), 52 | "numpy": ("https://docs.scipy.org/doc/numpy/", None), 53 | "pandas": ("https://pandas.pydata.org/pandas-docs/stable/", None), 54 | } 55 | 56 | # Do not copy prompot output 57 | copybutton_prompt_text = r">>> |\.\.\. |\$ " 58 | copybutton_prompt_is_regexp = True 59 | 60 | # Disable auto-generation of TOC entries in the API 61 | # https://github.com/sphinx-doc/sphinx/issues/6316 62 | toc_object_entries = False 63 | 64 | 65 | # HTML -------------------------------------------------------------------- 66 | 67 | html_theme = "sphinx_audeering_theme" 68 | html_theme_options = { 69 | "display_version": True, 70 | "footer_links": False, 71 | "logo_only": False, 72 | "wide_pages": ["usage"], 73 | } 74 | html_context = { 75 | "display_github": True, 76 | } 77 | html_title = title 78 | 79 | 80 | # Linkcheck --------------------------------------------------------------- 81 | 82 | linkcheck_ignore = [ 83 | "https://sail.usc.edu/", 84 | "http://sphinx-doc.org/", 85 | ] 86 | 87 | 88 | # Copy API (sub-)module RST files to docs/api/ folder --------------------- 89 | 90 | audeer.rmdir("api") 91 | audeer.mkdir("api") 92 | api_src_files = audeer.list_file_names("api-src") 93 | api_dst_files = [ 94 | audeer.path("api", os.path.basename(src_file)) for src_file in api_src_files 95 | ] 96 | for src_file, dst_file in zip(api_src_files, api_dst_files): 97 | shutil.copyfile(src_file, dst_file) 98 | -------------------------------------------------------------------------------- /docs/contributing.rst: -------------------------------------------------------------------------------- 1 | .. include:: ../CONTRIBUTING.rst 2 | -------------------------------------------------------------------------------- /docs/genindex.rst: -------------------------------------------------------------------------------- 1 | Index 2 | ----- 3 | -------------------------------------------------------------------------------- /docs/index.rst: -------------------------------------------------------------------------------- 1 | .. include:: ../README.rst 2 | 3 | .. toctree:: 4 | :caption: Getting started 5 | :hidden: 6 | 7 | install 8 | usage 9 | 10 | .. Warning: the usage of genindex is a hack to get a TOC entry, see 11 | .. https://stackoverflow.com/a/42310803. This might break the usage of sphinx if 12 | .. you want to create something different than HTML output. 13 | .. toctree:: 14 | :caption: API Documentation 15 | :hidden: 16 | 17 | api/opensmile 18 | genindex 19 | 20 | .. toctree:: 21 | :caption: Development 22 | :hidden: 23 | 24 | contributing 25 | changelog 26 | -------------------------------------------------------------------------------- /docs/install.rst: -------------------------------------------------------------------------------- 1 | Installation 2 | ============ 3 | 4 | To install :mod:`opensmile` run: 5 | 6 | .. code-block:: bash 7 | 8 | $ # Create and activate Python virtual environment, e.g. 9 | $ # virtualenv --no-download --python=python3 ${HOME}/.envs/opensmile 10 | $ # source ${HOME}/.envs/opensmile/bin/activate 11 | $ pip install opensmile 12 | -------------------------------------------------------------------------------- /docs/requirements.txt: -------------------------------------------------------------------------------- 1 | audb 2 | ipykernel 3 | jupyter-sphinx 4 | sphinx 5 | sphinx-audeering-theme >=1.2.1 6 | sphinx-autodoc-typehints 7 | sphinx-copybutton 8 | toml 9 | -------------------------------------------------------------------------------- /docs/usage.rst: -------------------------------------------------------------------------------- 1 | Usage 2 | ===== 3 | 4 | The aim of :mod:`opensmile` is to provide 5 | a high-level interface to openSMILE_. 6 | It ships pre-compiled binaries and default feature sets, 7 | but it's also possible to run custom config files. 8 | 9 | .. Load from internal audb repository 10 | .. jupyter-execute:: 11 | :hide-code: 12 | 13 | import audb 14 | 15 | audb.config.REPOSITORIES = [ 16 | audb.Repository( 17 | name="data-public", 18 | host="https://audeering.jfrog.io/artifactory", 19 | backend="artifactory", 20 | ), 21 | ] 22 | 23 | Getting ready 24 | ------------- 25 | 26 | Let's do some imports and 27 | load some files from the 28 | emodb_ database. 29 | 30 | .. jupyter-execute:: 31 | :hide-output: 32 | :stderr: 33 | 34 | import os 35 | import time 36 | 37 | import numpy as np 38 | import pandas as pd 39 | 40 | import audb 41 | import audiofile 42 | import opensmile 43 | 44 | 45 | db = audb.load( 46 | "emodb", 47 | version="1.1.1", 48 | format="wav", 49 | mixdown=True, 50 | sampling_rate=16000, 51 | media="wav/03a01.*", # load subset 52 | full_path=False, 53 | verbose=False, 54 | ) 55 | 56 | .. jupyter-execute:: 57 | :hide-code: 58 | 59 | pd.set_option("display.max_columns", 4) 60 | 61 | Process signal 62 | -------------- 63 | 64 | Read first ten seconds of a file into memory. 65 | 66 | .. jupyter-execute:: 67 | 68 | file = os.path.join(db.root, db.files[0]) 69 | signal, sampling_rate = audiofile.read( 70 | file, 71 | duration=10, 72 | always_2d=True, 73 | ) 74 | 75 | We set up a feature extractor for functionals 76 | of a pre-defined feature set. 77 | 78 | .. jupyter-execute:: 79 | 80 | smile = opensmile.Smile( 81 | feature_set=opensmile.FeatureSet.eGeMAPSv02, 82 | feature_level=opensmile.FeatureLevel.Functionals, 83 | ) 84 | smile.feature_names 85 | 86 | And extract features for the signal. 87 | 88 | .. jupyter-execute:: 89 | 90 | smile.process_signal( 91 | signal, 92 | sampling_rate 93 | ) 94 | 95 | Now we create a feature extractor 96 | for low-level descriptors (LLDs). 97 | 98 | .. jupyter-execute:: 99 | 100 | smile = opensmile.Smile( 101 | feature_set=opensmile.FeatureSet.eGeMAPSv02, 102 | feature_level=opensmile.FeatureLevel.LowLevelDescriptors, 103 | ) 104 | smile.feature_names 105 | 106 | And re-run feature extraction. 107 | 108 | .. jupyter-execute:: 109 | 110 | smile = opensmile.Smile( 111 | feature_set=opensmile.FeatureSet.eGeMAPSv02, 112 | feature_level=opensmile.FeatureLevel.LowLevelDescriptors, 113 | ) 114 | smile.process_signal( 115 | signal, 116 | sampling_rate 117 | ) 118 | 119 | Logging 120 | ------- 121 | 122 | To know what happens under the hood 123 | we can create a log file. 124 | 125 | .. jupyter-execute:: 126 | 127 | smile = opensmile.Smile( 128 | feature_set=opensmile.FeatureSet.eGeMAPSv02, 129 | feature_level=opensmile.FeatureLevel.Functionals, 130 | loglevel=2, 131 | logfile="smile.log", 132 | ) 133 | smile.process_signal( 134 | signal, 135 | sampling_rate 136 | ) 137 | with open("./smile.log", "r") as fp: 138 | log = fp.readlines() 139 | log 140 | 141 | Custom config 142 | ------------- 143 | 144 | We can create a custom config. 145 | 146 | .. jupyter-execute:: 147 | 148 | config_str = """ 149 | [componentInstances:cComponentManager] 150 | instance[dataMemory].type=cDataMemory 151 | 152 | ;;; default source 153 | [componentInstances:cComponentManager] 154 | instance[dataMemory].type=cDataMemory 155 | 156 | ;;; source 157 | 158 | \{\cm[source{?}:include external source]} 159 | 160 | ;;; main section 161 | 162 | [componentInstances:cComponentManager] 163 | instance[framer].type = cFramer 164 | instance[lld].type = cEnergy 165 | instance[func].type=cFunctionals 166 | 167 | [framer:cFramer] 168 | reader.dmLevel = wave 169 | writer.dmLevel = frames 170 | copyInputName = 1 171 | frameMode = fixed 172 | frameSize = 0.025000 173 | frameStep = 0.010000 174 | frameCenterSpecial = left 175 | noPostEOIprocessing = 1 176 | 177 | [lld:cEnergy] 178 | reader.dmLevel = frames 179 | writer.dmLevel = lld 180 | \{\cm[bufferModeRbConf{?}:path to included config to set the buffer mode for the standard ringbuffer levels]} 181 | nameAppend = energy 182 | copyInputName = 1 183 | rms = 1 184 | log = 1 185 | 186 | [func:cFunctionals] 187 | reader.dmLevel=lld 188 | writer.dmLevel=func 189 | copyInputName = 1 190 | \{\cm[bufferModeRbConf]} 191 | \{\cm[frameModeFunctionalsConf{?}:path to included config to set frame mode for all functionals]} 192 | functionalsEnabled=Moments 193 | Moments.variance = 0 194 | Moments.stddev = 1 195 | Moments.skewness = 0 196 | Moments.kurtosis = 0 197 | Moments.amean = 1 198 | Moments.doRatioLimit = 0 199 | 200 | ;;; sink 201 | 202 | \{\cm[sink{?}:include external sink]} 203 | 204 | """ 205 | 206 | It's important to always set the 207 | ``source`` and ``sink`` as we did above. 208 | But we are free in choosing the levels. 209 | In the above we have added two 210 | levels ``"func"`` and ``"lld"``. 211 | Now, we simply pass the level 212 | we are interested in. 213 | 214 | .. jupyter-execute:: 215 | 216 | with open("my.conf", "w") as fp: 217 | fp.write(config_str) 218 | 219 | smile = opensmile.Smile( 220 | feature_set="my.conf", 221 | feature_level="func", 222 | ) 223 | smile.process_signal( 224 | signal, 225 | sampling_rate 226 | ) 227 | 228 | And... 229 | 230 | .. jupyter-execute:: 231 | 232 | smile = opensmile.Smile( 233 | feature_set="my.conf", 234 | feature_level="lld", 235 | ) 236 | smile.process_signal( 237 | signal, 238 | sampling_rate, 239 | ) 240 | 241 | Resample 242 | -------- 243 | 244 | It's possible to resample the 245 | input signals on the fly. 246 | 247 | .. jupyter-execute:: 248 | 249 | smile = opensmile.Smile( 250 | feature_set=opensmile.FeatureSet.eGeMAPSv02, 251 | feature_level=opensmile.FeatureLevel.Functionals, 252 | sampling_rate=8000, 253 | resample=True, 254 | ) 255 | smile.process_signal( 256 | signal, 257 | sampling_rate, 258 | ) 259 | 260 | Multi-channel 261 | ------------- 262 | 263 | We can process multi-channel audio. 264 | Note that we need to set the channels 265 | we want to process when we create 266 | the feature extractor. 267 | 268 | .. jupyter-execute:: 269 | 270 | smile = opensmile.Smile( 271 | feature_set=opensmile.FeatureSet.eGeMAPSv02, 272 | feature_level=opensmile.FeatureLevel.Functionals, 273 | channels=[0, -1], # process first and last channel 274 | ) 275 | signal = np.concatenate([signal, signal, signal], axis=0) 276 | smile.process_signal( 277 | signal, 278 | sampling_rate, 279 | ) 280 | 281 | File input 282 | ---------- 283 | 284 | We can extract features from files. 285 | Note that we only process 286 | the first ten seconds of the files 287 | 288 | .. jupyter-execute:: 289 | 290 | files = db.files # pick files 291 | smile = opensmile.Smile( 292 | feature_set=opensmile.FeatureSet.eGeMAPSv02, 293 | feature_level=opensmile.FeatureLevel.Functionals, 294 | ) 295 | smile.process_files( 296 | files, 297 | ends=["2s"] * len(files), 298 | root=db.root, 299 | ) 300 | 301 | audformat 302 | --------- 303 | 304 | We can extract features from an index 305 | in the `audformat`_. 306 | Note that we set five workers 307 | to speed up the processing. 308 | 309 | .. jupyter-execute:: 310 | 311 | index = db["emotion"].index # pick table index 312 | smile = opensmile.Smile( 313 | feature_set=opensmile.FeatureSet.eGeMAPSv02, 314 | feature_level=opensmile.FeatureLevel.Functionals, 315 | num_workers=5, 316 | ) 317 | smile.process_index( 318 | index, 319 | root=db.root, 320 | ) 321 | 322 | 323 | .. _audformat: https://audeering.github.io/audformat/data-format.html 324 | .. _emodb: https://github.com/audeering/emodb 325 | .. _openSMILE: https://github.com/audeering/opensmile 326 | -------------------------------------------------------------------------------- /opensmile/__init__.py: -------------------------------------------------------------------------------- 1 | from opensmile.core.config import config 2 | from opensmile.core.define import FeatureLevel 3 | from opensmile.core.define import FeatureSet 4 | from opensmile.core.smile import Smile 5 | 6 | 7 | __all__ = [] 8 | 9 | 10 | __version__ = "unknown" 11 | 12 | # Dynamically get the version of the installed module 13 | try: 14 | import importlib.metadata 15 | 16 | __version__ = importlib.metadata.version(__name__) 17 | except Exception: # pragma: no cover 18 | importlib = None # pragma: no cover 19 | finally: 20 | del importlib 21 | -------------------------------------------------------------------------------- /opensmile/core/__init__.py: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/audeering/opensmile-python/9d7fd3da103a4e72c35c7b8f7978ce36b6f174b3/opensmile/core/__init__.py -------------------------------------------------------------------------------- /opensmile/core/bin/macosx_10_4_x86_64/SMILExtract: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/audeering/opensmile-python/9d7fd3da103a4e72c35c7b8f7978ce36b6f174b3/opensmile/core/bin/macosx_10_4_x86_64/SMILExtract -------------------------------------------------------------------------------- /opensmile/core/bin/macosx_10_4_x86_64/libSMILEapi.dylib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/audeering/opensmile-python/9d7fd3da103a4e72c35c7b8f7978ce36b6f174b3/opensmile/core/bin/macosx_10_4_x86_64/libSMILEapi.dylib -------------------------------------------------------------------------------- /opensmile/core/bin/macosx_11_0_arm64/SMILExtract: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/audeering/opensmile-python/9d7fd3da103a4e72c35c7b8f7978ce36b6f174b3/opensmile/core/bin/macosx_11_0_arm64/SMILExtract -------------------------------------------------------------------------------- /opensmile/core/bin/macosx_11_0_arm64/libSMILEapi.dylib: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/audeering/opensmile-python/9d7fd3da103a4e72c35c7b8f7978ce36b6f174b3/opensmile/core/bin/macosx_11_0_arm64/libSMILEapi.dylib -------------------------------------------------------------------------------- /opensmile/core/bin/manylinux_2_17_aarch64/SMILExtract: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/audeering/opensmile-python/9d7fd3da103a4e72c35c7b8f7978ce36b6f174b3/opensmile/core/bin/manylinux_2_17_aarch64/SMILExtract -------------------------------------------------------------------------------- /opensmile/core/bin/manylinux_2_17_aarch64/libSMILEapi.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/audeering/opensmile-python/9d7fd3da103a4e72c35c7b8f7978ce36b6f174b3/opensmile/core/bin/manylinux_2_17_aarch64/libSMILEapi.so -------------------------------------------------------------------------------- /opensmile/core/bin/manylinux_2_17_armv7l/SMILExtract: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/audeering/opensmile-python/9d7fd3da103a4e72c35c7b8f7978ce36b6f174b3/opensmile/core/bin/manylinux_2_17_armv7l/SMILExtract -------------------------------------------------------------------------------- /opensmile/core/bin/manylinux_2_17_armv7l/libSMILEapi.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/audeering/opensmile-python/9d7fd3da103a4e72c35c7b8f7978ce36b6f174b3/opensmile/core/bin/manylinux_2_17_armv7l/libSMILEapi.so -------------------------------------------------------------------------------- /opensmile/core/bin/manylinux_2_17_x86_64/SMILExtract: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/audeering/opensmile-python/9d7fd3da103a4e72c35c7b8f7978ce36b6f174b3/opensmile/core/bin/manylinux_2_17_x86_64/SMILExtract -------------------------------------------------------------------------------- /opensmile/core/bin/manylinux_2_17_x86_64/libSMILEapi.so: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/audeering/opensmile-python/9d7fd3da103a4e72c35c7b8f7978ce36b6f174b3/opensmile/core/bin/manylinux_2_17_x86_64/libSMILEapi.so -------------------------------------------------------------------------------- /opensmile/core/bin/win_amd64/SMILEapi.dll: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/audeering/opensmile-python/9d7fd3da103a4e72c35c7b8f7978ce36b6f174b3/opensmile/core/bin/win_amd64/SMILEapi.dll -------------------------------------------------------------------------------- /opensmile/core/bin/win_amd64/SMILExtract.exe: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/audeering/opensmile-python/9d7fd3da103a4e72c35c7b8f7978ce36b6f174b3/opensmile/core/bin/win_amd64/SMILExtract.exe -------------------------------------------------------------------------------- /opensmile/core/config.py: -------------------------------------------------------------------------------- 1 | class config: 2 | r"""Get/set defaults for the :mod:`opensmile` module.""" 3 | 4 | CONFIG_ROOT = "config" 5 | """Root directory of config files.""" 6 | 7 | CONFIG_EXT = ".conf" 8 | """Extension of config files.""" 9 | 10 | EXTERNAL_SOURCE_COMPONENT = "extsource" 11 | """Standard component name for external input.""" 12 | 13 | EXTERNAL_OUTPUT_COMPONENT = "extsink" 14 | """Standard component name for external data output.""" 15 | 16 | FILE_INPUT_CONFIG = "shared/standard_wave_input.conf.inc" 17 | """Standard config name for wave input from file.""" 18 | 19 | EXTERNAL_INPUT_CONFIG = "shared/standard_external_wave_input.conf.inc" 20 | """Standard config name for external wave input.""" 21 | 22 | EXTERNAL_OUTPUT_SINGLE_CONFIG = ( 23 | "shared/standard_external_data_output_single.conf.inc" 24 | ) 25 | """Standard config name for external data output from a single level.""" 26 | 27 | EXTERNAL_OUTPUT_MULTI_CONFIG = "shared/standard_external_data_output_multi.conf.inc" 28 | """Standard config name for external data output from multiple levels.""" 29 | 30 | FILE_OUTPUT_CONFIG = "shared/standard_data_output.conf.inc" 31 | """Standard config name for external data output.""" 32 | 33 | FILE_OUTPUT_CONFIG_NO_LLD_DE = "shared/standard_data_output_no_lld_de.conf.inc" 34 | """Standard config name for external data output without lld_de level.""" 35 | -------------------------------------------------------------------------------- /opensmile/core/config/compare/ComParE_2016.conf: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file for ComParE < ////////////////// 3 | ///////// updated version of ComParE 2013 set, numerical fixes ////////////////// 4 | ///////// ////////////////// 5 | ///////// (c) 2014-2016 by audEERING, ////////////////// 6 | ///////// All rights reserved. See file COPYING for details. ////////////////// 7 | /////////////////////////////////////////////////////////////////////////////////////// 8 | 9 | [componentInstances:cComponentManager] 10 | instance[dataMemory].type=cDataMemory 11 | 12 | ;;; source 13 | 14 | \{\cm[source{?}:include external source]} 15 | 16 | ;;; main section 17 | 18 | \{ComParE_2016_core.lld.conf.inc} 19 | \{ComParE_2016_core.func.conf.inc} 20 | 21 | ;;; prepare output 22 | 23 | [componentInstances:cComponentManager] 24 | instance[is13_lldconcat].type=cVectorConcat 25 | instance[is13_llddeconcat].type=cVectorConcat 26 | instance[is13_funcconcat].type=cVectorConcat 27 | 28 | [is13_lldconcat:cVectorConcat] 29 | reader.dmLevel = is13_lld_nzsmo;is13_lldA_smo;is13_lldB_smo 30 | writer.dmLevel = lld 31 | includeSingleElementFields = 1 32 | 33 | [is13_llddeconcat:cVectorConcat] 34 | reader.dmLevel = is13_lld_nzsmo_de;is13_lldA_smo_de;is13_lldB_smo_de 35 | writer.dmLevel = lld_de 36 | includeSingleElementFields = 1 37 | 38 | [is13_funcconcat:cVectorConcat] 39 | reader.dmLevel = is13_functionalsA;is13_functionalsB;is13_functionalsNz;is13_functionalsF0;is13_functionalsLLD;is13_functionalsDelta 40 | writer.dmLevel = func 41 | includeSingleElementFields = 1 42 | 43 | ;;; sink 44 | 45 | \{\cm[sink{?}:include external sink]} 46 | -------------------------------------------------------------------------------- /opensmile/core/config/compare/ComParE_2016_core.func.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file for ComParE < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014 by audEERING ////////////////// 5 | ///////// All rights reserved. See file COPYING for details. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | ;;;;;;;;; functionals / statistics 9 | 10 | [componentInstances:cComponentManager] 11 | instance[is13_functionalsA].type=cFunctionals 12 | instance[is13_functionalsB].type=cFunctionals 13 | instance[is13_functionalsF0].type=cFunctionals 14 | instance[is13_functionalsNz].type=cFunctionals 15 | ; shared functionals for LLD 16 | instance[is13_functionalsLLD].type=cFunctionals 17 | ; shared functionals for Delta LLD 18 | instance[is13_functionalsDelta].type=cFunctionals 19 | 20 | ; functionals for energy related lld 21 | [is13_functionalsA:cFunctionals] 22 | reader.dmLevel = is13_lldA_smo;is13_lldA_smo_de 23 | writer.dmLevel = is13_functionalsA 24 | // nameAppend = 25 | copyInputName = 1 26 | \{\cm[bufferModeRbConf]} 27 | \{\cm[frameModeFunctionalsConf{../shared/FrameModeFunctionals.conf.inc}:path to included config to set frame mode for all functionals]} 28 | functionalsEnabled = Extremes ; Percentiles ; Moments ; Segments ; Times ; Lpc 29 | Extremes.max = 0 30 | Extremes.min = 0 31 | Extremes.maxpos = 1 32 | Extremes.minpos = 1 33 | Extremes.maxameandist = 0 34 | Extremes.minameandist = 0 35 | Segments.maxNumSeg = 100 36 | Segments.segmentationAlgorithm = relTh 37 | Segments.thresholds = 0.25 ; 0.75 38 | Segments.ravgLng = 3 39 | Segments.numSegments = 0 40 | Segments.meanSegLen = 1 41 | Segments.maxSegLen = 1 42 | Segments.minSegLen = 1 43 | Segments.segLenStddev = 1 44 | Segments.norm = second 45 | Moments.variance = 0 46 | Moments.stddev = 1 47 | Moments.skewness = 1 48 | Moments.kurtosis = 1 49 | Moments.amean = 0 50 | Moments.doRatioLimit = 1 51 | Percentiles.quartiles = 1 52 | Percentiles.iqr = 1 53 | Percentiles.percentile[0] = 0.01 54 | Percentiles.percentile[1] = 0.99 55 | Percentiles.pctlrange[0] = 0-1 56 | Percentiles.interp = 1 57 | Times.upleveltime25 = 1 58 | Times.downleveltime25 = 0 59 | Times.upleveltime50 = 1 60 | Times.downleveltime50 = 0 61 | Times.upleveltime75 = 1 62 | Times.downleveltime75 = 0 63 | Times.upleveltime90 = 1 64 | Times.downleveltime90 = 0 65 | Times.risetime = 1 66 | Times.falltime = 0 67 | Times.leftctime = 1 68 | Times.rightctime = 0 69 | Times.duration = 0 70 | Times.buggySecNorm = 0 71 | Times.norm = segment 72 | Lpc.lpGain = 1 73 | Lpc.lpc = 1 74 | Lpc.firstCoeff = 0 75 | Lpc.order = 5 76 | nonZeroFuncts = 0 77 | masterTimeNorm = segment 78 | 79 | ; functionals for spectrum related lld 80 | [is13_functionalsB:cFunctionals] 81 | reader.dmLevel = is13_lldB_smo;is13_lldB_smo_de 82 | writer.dmLevel = is13_functionalsB 83 | // nameAppend = 84 | copyInputName = 1 85 | \{\cm[bufferModeRbConf]} 86 | \{\cm[frameModeFunctionalsConf]} 87 | functionalsEnabled = Extremes ; Percentiles ; Moments ; Segments ; Times ; Lpc 88 | Extremes.max = 0 89 | Extremes.min = 0 90 | Extremes.maxpos = 1 91 | Extremes.minpos = 1 92 | Extremes.maxameandist = 0 93 | Extremes.minameandist = 0 94 | Segments.maxNumSeg = 100 95 | Segments.segmentationAlgorithm = relTh 96 | Segments.thresholds = 0.25 ; 0.75 97 | Segments.rangeRelThreshold = 0.200000 98 | Segments.numSegments = 0 99 | Segments.meanSegLen = 1 100 | Segments.maxSegLen = 1 101 | Segments.minSegLen = 1 102 | Segments.segLenStddev = 1 103 | Segments.norm = second 104 | Moments.variance = 0 105 | Moments.stddev = 1 106 | Moments.skewness = 1 107 | Moments.kurtosis = 1 108 | Moments.amean = 0 109 | Moments.doRatioLimit = 1 110 | Percentiles.quartiles = 1 111 | Percentiles.iqr = 1 112 | Percentiles.percentile[0] = 0.01 113 | Percentiles.percentile[1] = 0.99 114 | Percentiles.pctlrange[0] = 0-1 115 | Percentiles.interp = 1 116 | Times.upleveltime25 = 1 117 | Times.downleveltime25 = 0 118 | Times.upleveltime50 = 1 119 | Times.downleveltime50 = 0 120 | Times.upleveltime75 = 1 121 | Times.downleveltime75 = 0 122 | Times.upleveltime90 = 1 123 | Times.downleveltime90 = 0 124 | Times.risetime = 1 125 | Times.falltime = 0 126 | Times.leftctime = 1 127 | Times.rightctime = 0 128 | Times.duration = 0 129 | Times.buggySecNorm = 0 130 | Times.norm = segment 131 | Lpc.lpGain = 1 132 | Lpc.lpc = 1 133 | Lpc.firstCoeff = 0 134 | Lpc.order = 5 135 | nonZeroFuncts = 0 136 | masterTimeNorm = segment 137 | 138 | ; functionals for pitch onsets/offsets 139 | [is13_functionalsF0:cFunctionals] 140 | reader.dmLevel = is13_lld_f0_nzsmo 141 | writer.dmLevel = is13_functionalsF0 142 | //nameAppend = ff0 143 | copyInputName = 1 144 | \{\cm[bufferModeRbConf]} 145 | \{\cm[frameModeFunctionalsConf]} 146 | functionalsEnabled = Means ; Segments 147 | Means.amean = 0 148 | Means.absmean = 0 149 | Means.qmean = 0 150 | Means.nzamean = 0 151 | Means.nzabsmean = 0 152 | Means.nzqmean = 0 153 | Means.nzgmean = 0 154 | Means.nnz = 1 155 | Means.norm = segment 156 | Segments.maxNumSeg = 100 157 | Segments.segmentationAlgorithm = nonX 158 | Segments.X = 0.0 159 | Segments.numSegments = 0 160 | Segments.meanSegLen = 1 161 | Segments.maxSegLen = 1 162 | Segments.minSegLen = 1 163 | Segments.segLenStddev = 1 164 | Segments.norm = second 165 | nonZeroFuncts = 0 166 | masterTimeNorm = segment 167 | 168 | ; functionals for pitch and vq related lld in voiced regions 169 | [is13_functionalsNz:cFunctionals] 170 | reader.dmLevel = is13_lld_nzsmo;is13_lld_nzsmo_de 171 | writer.dmLevel = is13_functionalsNz 172 | // nameAppend = 173 | copyInputName = 1 174 | \{\cm[bufferModeRbConf]} 175 | \{\cm[frameModeFunctionalsConf]} 176 | functionalsEnabled = Means ; Extremes ; Regression ; Percentiles ; Moments ; Times ; Lpc 177 | Means.amean = 1 178 | Means.posamean = 1 179 | Means.absmean = 0 180 | Means.qmean = 0 181 | Means.rqmean = 1 182 | Means.nzamean = 0 183 | Means.nzabsmean = 0 184 | Means.nzqmean = 0 185 | Means.posrqmean = 0 186 | Means.nzgmean = 0 187 | Means.nnz = 0 188 | Means.flatness = 1 189 | Means.norm = frames 190 | Extremes.max = 0 191 | Extremes.min = 0 192 | Extremes.maxpos = 1 193 | Extremes.minpos = 1 194 | Extremes.maxameandist = 0 195 | Extremes.minameandist = 0 196 | Moments.variance = 0 197 | Moments.stddev = 1 198 | Moments.skewness = 1 199 | Moments.kurtosis = 1 200 | Moments.amean = 0 201 | Moments.doRatioLimit = 1 202 | Regression.linregc1 = 1 203 | Regression.linregc2 = 1 204 | Regression.linregerrA = 0 205 | Regression.linregerrQ = 1 206 | Regression.qregc1 = 1 207 | Regression.qregc2 = 1 208 | Regression.qregc3 = 1 209 | Regression.qregerrA = 0 210 | Regression.qregerrQ = 1 211 | Regression.oldBuggyQerr = 0 212 | Regression.centroid = 1 213 | Regression.centroidUseAbsValues = 1 214 | Regression.centroidRatioLimit = 1 215 | Regression.normRegCoeff = 0 216 | Regression.normInputs = 1 217 | Regression.doRatioLimit = 1 218 | Percentiles.quartiles = 1 219 | Percentiles.iqr = 1 220 | Percentiles.percentile[0] = 0.01 221 | Percentiles.percentile[1] = 0.99 222 | Percentiles.pctlrange[0] = 0-1 223 | Percentiles.interp = 1 224 | Times.upleveltime25 = 1 225 | Times.downleveltime25 = 0 226 | Times.upleveltime50 = 1 227 | Times.downleveltime50 = 0 228 | Times.upleveltime75 = 1 229 | Times.downleveltime75 = 0 230 | Times.upleveltime90 = 1 231 | Times.downleveltime90 = 0 232 | Times.risetime = 1 233 | Times.falltime = 0 234 | Times.leftctime = 1 235 | Times.rightctime = 0 236 | Times.duration = 0 237 | Times.buggySecNorm = 0 238 | Times.norm = segment 239 | Lpc.lpGain = 1 240 | Lpc.lpc = 1 241 | Lpc.firstCoeff = 0 242 | Lpc.order = 5 243 | nonZeroFuncts = 1 244 | masterTimeNorm = segment 245 | 246 | 247 | [is13_functionalsLLD:cFunctionals] 248 | reader.dmLevel = is13_lldA_smo;is13_lldB_smo 249 | writer.dmLevel = is13_functionalsLLD 250 | copyInputName = 1 251 | \{\cm[bufferModeRbConf]} 252 | \{\cm[frameModeFunctionalsConf]} 253 | functionalsEnabled = Means ; Peaks2 ; Regression 254 | Means.amean = 1 255 | Means.posamean = 0 256 | Means.absmean = 0 257 | Means.qmean = 0 258 | Means.rqmean = 1 259 | Means.nzamean = 0 260 | Means.nzabsmean = 0 261 | Means.nzqmean = 0 262 | Means.posrqmean = 0 263 | Means.nzgmean = 0 264 | Means.nnz = 0 265 | Means.flatness = 1 266 | Means.norm = frames 267 | Regression.linregc1 = 1 268 | Regression.linregc2 = 1 269 | Regression.linregerrA = 0 270 | Regression.linregerrQ = 1 271 | Regression.qregc1 = 1 272 | Regression.qregc2 = 1 273 | Regression.qregc3 = 1 274 | Regression.qregerrA = 0 275 | Regression.qregerrQ = 1 276 | Regression.oldBuggyQerr = 0 277 | Regression.centroid = 1 278 | Regression.centroidUseAbsValues = 1 279 | Regression.centroidRatioLimit = 1 280 | Regression.normRegCoeff = 2 281 | Regression.normInputs = 1 282 | Regression.doRatioLimit = 1 283 | Peaks2.doRatioLimit = 1 284 | Peaks2.numPeaks = 0 285 | Peaks2.meanPeakDist = 1 286 | Peaks2.meanPeakDistDelta = 0 287 | Peaks2.peakDistStddev = 1 288 | Peaks2.peakRangeAbs = 1 289 | Peaks2.peakRangeRel = 1 290 | Peaks2.peakMeanAbs = 1 291 | Peaks2.peakMeanMeanDist = 1 292 | Peaks2.peakMeanRel = 1 293 | Peaks2.ptpAmpMeanAbs = 0 294 | Peaks2.ptpAmpMeanRel = 0 295 | Peaks2.ptpAmpStddevAbs = 0 296 | Peaks2.ptpAmpStddevRel = 0 297 | Peaks2.minRangeAbs = 0 298 | Peaks2.minRangeRel = 1 299 | Peaks2.minMeanAbs = 0 300 | Peaks2.minMeanMeanDist = 0 301 | Peaks2.minMeanRel = 0 302 | Peaks2.mtmAmpMeanAbs = 0 303 | Peaks2.mtmAmpMeanRel = 0 304 | Peaks2.mtmAmpStddevAbs = 0 305 | Peaks2.mtmAmpStddevRel = 0 306 | Peaks2.meanRisingSlope = 1 307 | Peaks2.maxRisingSlope = 0 308 | Peaks2.minRisingSlope = 0 309 | Peaks2.stddevRisingSlope = 1 310 | Peaks2.meanFallingSlope = 1 311 | Peaks2.maxFallingSlope = 0 312 | Peaks2.minFallingSlope = 0 313 | Peaks2.stddevFallingSlope = 1 314 | Peaks2.norm = seconds 315 | Peaks2.relThresh = 0.100000 316 | Peaks2.dynRelThresh = 0 317 | ;Peaks2.posDbgOutp = minmax.txt 318 | Peaks2.posDbgAppend = 0 319 | Peaks2.consoleDbg = 0 320 | 321 | 322 | [is13_functionalsDelta:cFunctionals] 323 | reader.dmLevel = is13_lldA_smo_de;is13_lldB_smo_de 324 | writer.dmLevel = is13_functionalsDelta 325 | copyInputName = 1 326 | \{\cm[bufferModeRbConf]} 327 | \{\cm[frameModeFunctionalsConf]} 328 | functionalsEnabled = Means ; Peaks2 329 | Means.amean = 0 330 | Means.posamean = 1 331 | Means.absmean = 0 332 | Means.qmean = 0 333 | Means.rqmean = 1 334 | Means.nzamean = 0 335 | Means.nzabsmean = 0 336 | Means.nzqmean = 0 337 | Means.posrqmean = 0 338 | Means.nzgmean = 0 339 | Means.nnz = 0 340 | Means.flatness = 1 341 | Means.norm = frames 342 | Peaks2.doRatioLimit = 1 343 | Peaks2.numPeaks = 0 344 | Peaks2.meanPeakDist = 1 345 | Peaks2.meanPeakDistDelta = 0 346 | Peaks2.peakDistStddev = 1 347 | Peaks2.peakRangeAbs = 1 348 | Peaks2.peakRangeRel = 1 349 | Peaks2.peakMeanAbs = 1 350 | Peaks2.peakMeanMeanDist = 1 351 | Peaks2.peakMeanRel = 1 352 | Peaks2.ptpAmpMeanAbs = 0 353 | Peaks2.ptpAmpMeanRel = 0 354 | Peaks2.ptpAmpStddevAbs = 0 355 | Peaks2.ptpAmpStddevRel = 0 356 | Peaks2.minRangeAbs = 0 357 | Peaks2.minRangeRel = 1 358 | Peaks2.minMeanAbs = 0 359 | Peaks2.minMeanMeanDist = 0 360 | Peaks2.minMeanRel = 0 361 | Peaks2.mtmAmpMeanAbs = 0 362 | Peaks2.mtmAmpMeanRel = 0 363 | Peaks2.mtmAmpStddevAbs = 0 364 | Peaks2.mtmAmpStddevRel = 0 365 | Peaks2.meanRisingSlope = 1 366 | Peaks2.maxRisingSlope = 0 367 | Peaks2.minRisingSlope = 0 368 | Peaks2.stddevRisingSlope = 1 369 | Peaks2.meanFallingSlope = 1 370 | Peaks2.maxFallingSlope = 0 371 | Peaks2.minFallingSlope = 0 372 | Peaks2.stddevFallingSlope = 1 373 | Peaks2.norm = seconds 374 | Peaks2.relThresh = 0.100000 375 | Peaks2.dynRelThresh = 0 376 | ;Peaks2.posDbgOutp = minmax.txt 377 | Peaks2.posDbgAppend = 0 378 | Peaks2.consoleDbg = 0 379 | 380 | 381 | 382 | -------------------------------------------------------------------------------- /opensmile/core/config/compare/ComParE_2016_core.lld.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file for ComParE < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) audEERING GmbH, ////////////////// 5 | ///////// All rights reserved. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | [componentInstances:cComponentManager] 9 | instance[is13_frame60].type=cFramer 10 | instance[is13_win60].type=cWindower 11 | instance[is13_fft60].type=cTransformFFT 12 | instance[is13_fftmp60].type=cFFTmagphase 13 | 14 | [is13_frame60:cFramer] 15 | reader.dmLevel=wave 16 | writer.dmLevel=is13_frame60 17 | \{\cm[bufferModeRbConf{../shared/BufferModeRb.conf.inc}:path to included config to set the buffer mode for the standard ringbuffer levels]} 18 | frameSize = 0.060 19 | frameStep = 0.010 20 | frameCenterSpecial = left 21 | 22 | [is13_win60:cWindower] 23 | reader.dmLevel=is13_frame60 24 | writer.dmLevel=is13_winG60 25 | winFunc=gauss 26 | gain=1.0 27 | sigma=0.4 28 | 29 | [is13_fft60:cTransformFFT] 30 | reader.dmLevel=is13_winG60 31 | writer.dmLevel=is13_fftcG60 32 | zeroPadSymmetric = 1 33 | 34 | [is13_fftmp60:cFFTmagphase] 35 | reader.dmLevel=is13_fftcG60 36 | writer.dmLevel=is13_fftmagG60 37 | 38 | 39 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 40 | 41 | [componentInstances:cComponentManager] 42 | instance[is13_frame25].type=cFramer 43 | instance[is13_win25].type=cWindower 44 | instance[is13_fft25].type=cTransformFFT 45 | instance[is13_fftmp25].type=cFFTmagphase 46 | 47 | [is13_frame25:cFramer] 48 | reader.dmLevel=wave 49 | writer.dmLevel=is13_frame25 50 | \{\cm[bufferModeRbConf]} 51 | frameSize = 0.020 52 | frameStep = 0.010 53 | frameCenterSpecial = left 54 | 55 | [is13_win25:cWindower] 56 | reader.dmLevel=is13_frame25 57 | writer.dmLevel=is13_winH25 58 | winFunc=hamming 59 | 60 | [is13_fft25:cTransformFFT] 61 | reader.dmLevel=is13_winH25 62 | writer.dmLevel=is13_fftcH25 63 | zeroPadSymmetric = 1 64 | 65 | [is13_fftmp25:cFFTmagphase] 66 | reader.dmLevel=is13_fftcH25 67 | writer.dmLevel=is13_fftmagH25 68 | 69 | 70 | 71 | ;;;;;;;;;;;;;;;;;;;; HPS pitch 72 | 73 | [componentInstances:cComponentManager] 74 | instance[is13_scale].type=cSpecScale 75 | instance[is13_shs].type=cPitchShs 76 | 77 | [is13_scale:cSpecScale] 78 | reader.dmLevel=is13_fftmagG60 79 | writer.dmLevel=is13_hpsG60 80 | copyInputName = 1 81 | processArrayFields = 0 82 | scale=octave 83 | sourceScale = lin 84 | interpMethod = spline 85 | minF = 25 86 | maxF = -1 87 | nPointsTarget = 0 88 | specSmooth = 1 89 | specEnhance = 1 90 | auditoryWeighting = 1 91 | 92 | [is13_shs:cPitchShs] 93 | reader.dmLevel=is13_hpsG60 94 | writer.dmLevel=is13_pitchShsG60 95 | \{\cm[bufferModeRbLagConf{../shared/BufferModeRbLag.conf.inc}:path to included config to set the buffer mode for levels which will be joint with Viterbi smoothed -lagged- F0]} 96 | copyInputName = 1 97 | processArrayFields = 0 98 | maxPitch = 620 99 | minPitch = 52 100 | nCandidates = 6 101 | scores = 1 102 | voicing = 1 103 | F0C1 = 0 104 | voicingC1 = 0 105 | F0raw = 1 106 | voicingClip = 1 107 | voicingCutoff = 0.700000 108 | inputFieldSearch = Mag_octScale 109 | octaveCorrection = 0 110 | nHarmonics = 15 111 | compressionFactor = 0.850000 112 | greedyPeakAlgo = 1 113 | 114 | ;;;;; Pitch with Viterbi smoother 115 | [componentInstances:cComponentManager] 116 | instance[is13_energy60].type=cEnergy 117 | 118 | [is13_energy60:cEnergy] 119 | reader.dmLevel=is13_winG60 120 | writer.dmLevel=is13_e60 121 | ; This must be > than buffersize of viterbi smoother 122 | \{\cm[bufferModeRbLagConf]} 123 | rms=1 124 | log=0 125 | 126 | [componentInstances:cComponentManager] 127 | instance[is13_pitchSmoothViterbi].type=cPitchSmootherViterbi 128 | 129 | [is13_pitchSmoothViterbi:cPitchSmootherViterbi] 130 | reader.dmLevel=is13_pitchShsG60 131 | reader2.dmLevel=is13_pitchShsG60 132 | writer.dmLevel=is13_pitchG60_viterbi 133 | \{\cm[bufferModeRbLagConf]} 134 | copyInputName = 1 135 | bufferLength=30 136 | F0final = 1 137 | F0finalEnv = 0 138 | voicingFinalClipped = 0 139 | voicingFinalUnclipped = 1 140 | F0raw = 0 141 | voicingC1 = 0 142 | voicingClip = 0 143 | wTvv =10.0 144 | wTvvd= 5.0 145 | wTvuv=10.0 146 | wThr = 4.0 147 | wTuu = 0.0 148 | wLocal=2.0 149 | wRange=1.0 150 | 151 | [componentInstances:cComponentManager] 152 | instance[is13_volmerge].type = cValbasedSelector 153 | 154 | [is13_volmerge:cValbasedSelector] 155 | reader.dmLevel = is13_e60;is13_pitchG60_viterbi 156 | writer.dmLevel = is13_pitchG60 157 | \{\cm[bufferModeRbLagConf]} 158 | idx=0 159 | threshold=0.001 160 | removeIdx=1 161 | zeroVec=1 162 | outputVal=0.0 163 | 164 | ;;;;;;;;;;;;;;;;;;; Voice Quality (VQ) 165 | 166 | [componentInstances:cComponentManager] 167 | instance[is13_pitchJitter].type=cPitchJitter 168 | 169 | [is13_pitchJitter:cPitchJitter] 170 | reader.dmLevel = wave 171 | writer.dmLevel = is13_jitterShimmer 172 | \{\cm[bufferModeRbLagConf]} 173 | copyInputName = 1 174 | F0reader.dmLevel = is13_pitchG60 175 | F0field = F0final 176 | searchRangeRel = 0.250000 177 | jitterLocal = 1 178 | jitterDDP = 1 179 | jitterLocalEnv = 0 180 | jitterDDPEnv = 0 181 | shimmerLocal = 1 182 | shimmerLocalEnv = 0 183 | onlyVoiced = 0 184 | logHNR = 1 185 | inputMaxDelaySec = 2.0 186 | ;periodLengths = 0 187 | ;periodStarts = 0 188 | useBrokenJitterThresh = 0 189 | 190 | ;;;;;;;;;;;;;;;;;;;;; Energy / loudness 191 | 192 | 193 | [componentInstances:cComponentManager] 194 | instance[is13_energy].type=cEnergy 195 | instance[is13_melspec1].type=cMelspec 196 | instance[is13_audspec].type=cPlp 197 | instance[is13_audspecRasta].type=cPlp 198 | instance[is13_audspecSum].type=cVectorOperation 199 | instance[is13_audspecRastaSum].type=cVectorOperation 200 | 201 | [is13_energy:cEnergy] 202 | reader.dmLevel = is13_frame25 203 | writer.dmLevel = is13_energy 204 | log=0 205 | rms=1 206 | 207 | [is13_melspec1:cMelspec] 208 | reader.dmLevel=is13_fftmagH25 209 | writer.dmLevel=is13_melspec1 210 | ; htk compatible sample value scaling 211 | htkcompatible = 0 212 | nBands = 26 213 | ; use power spectrum instead of magnitude spectrum 214 | usePower = 1 215 | lofreq = 20 216 | hifreq = 8000 217 | specScale = mel 218 | showFbank = 0 219 | 220 | ; perform auditory weighting of spectrum 221 | [is13_audspec:cPlp] 222 | reader.dmLevel=is13_melspec1 223 | writer.dmLevel=is13_audspec 224 | firstCC = 0 225 | lpOrder = 5 226 | cepLifter = 22 227 | compression = 0.33 228 | htkcompatible = 0 229 | doIDFT = 0 230 | doLpToCeps = 0 231 | doLP = 0 232 | doInvLog = 0 233 | doAud = 1 234 | doLog = 0 235 | newRASTA=0 236 | RASTA=0 237 | 238 | ; perform RASTA style filtering of auditory spectra 239 | [is13_audspecRasta:cPlp] 240 | reader.dmLevel=is13_melspec1 241 | writer.dmLevel=is13_audspecRasta 242 | nameAppend = Rfilt 243 | firstCC = 0 244 | lpOrder = 5 245 | cepLifter = 22 246 | compression = 0.33 247 | htkcompatible = 0 248 | doIDFT = 0 249 | doLpToCeps = 0 250 | doLP = 0 251 | doInvLog = 0 252 | doAud = 1 253 | doLog = 0 254 | newRASTA=1 255 | RASTA=0 256 | 257 | [is13_audspecSum:cVectorOperation] 258 | reader.dmLevel = is13_audspec 259 | writer.dmLevel = is13_audspecSum 260 | // nameAppend = 261 | copyInputName = 1 262 | processArrayFields = 0 263 | operation = ll1 264 | nameBase = audspec 265 | 266 | [is13_audspecRastaSum:cVectorOperation] 267 | reader.dmLevel = is13_audspecRasta 268 | writer.dmLevel = is13_audspecRastaSum 269 | // nameAppend = 270 | copyInputName = 1 271 | processArrayFields = 0 272 | operation = ll1 273 | nameBase = audspecRasta 274 | 275 | ;;;;;;;;;;;;;;; spectral 276 | 277 | [componentInstances:cComponentManager] 278 | instance[is13_spectral].type=cSpectral 279 | 280 | 281 | [is13_spectral:cSpectral] 282 | reader.dmLevel=is13_fftmagH25 283 | writer.dmLevel=is13_spectral 284 | bands[0]=250-650 285 | bands[1]=1000-4000 286 | rollOff[0] = 0.25 287 | rollOff[1] = 0.50 288 | rollOff[2] = 0.75 289 | rollOff[3] = 0.90 290 | flux=1 291 | centroid=1 292 | maxPos=0 293 | minPos=0 294 | entropy=1 295 | variance=1 296 | skewness=1 297 | kurtosis=1 298 | slope=1 299 | harmonicity=1 300 | sharpness=1 301 | 302 | 303 | ;;;;;;;;;;;;;;; mfcc 304 | 305 | [componentInstances:cComponentManager] 306 | instance[is13_melspecMfcc].type=cMelspec 307 | instance[is13_mfcc].type=cMfcc 308 | 309 | [is13_melspecMfcc:cMelspec] 310 | reader.dmLevel=is13_fftmagH25 311 | writer.dmLevel=is13_melspecMfcc 312 | copyInputName = 1 313 | processArrayFields = 1 314 | ; htk compatible sample value scaling 315 | htkcompatible = 1 316 | nBands = 26 317 | ; use power spectrum instead of magnitude spectrum 318 | usePower = 1 319 | lofreq = 20 320 | hifreq = 8000 321 | specScale = mel 322 | inverse = 0 323 | 324 | [is13_mfcc:cMfcc] 325 | reader.dmLevel=is13_melspecMfcc 326 | writer.dmLevel=is13_mfcc1_12 327 | copyInputName = 0 328 | processArrayFields = 1 329 | firstMfcc = 1 330 | lastMfcc = 14 331 | cepLifter = 22.0 332 | htkcompatible = 1 333 | 334 | 335 | ;;;;;;;;;;;;;;;; zcr 336 | 337 | [componentInstances:cComponentManager] 338 | instance[is13_mzcr].type=cMZcr 339 | 340 | [is13_mzcr:cMZcr] 341 | reader.dmLevel = is13_frame60 342 | writer.dmLevel = is13_zcr 343 | copyInputName = 1 344 | processArrayFields = 1 345 | zcr = 1 346 | mcr = 0 347 | amax = 0 348 | maxmin = 0 349 | dc = 0 350 | 351 | 352 | ;;;;;;;;;;;;;;;;;;;; smoothing 353 | 354 | [componentInstances:cComponentManager] 355 | instance[is13_smoNz].type=cContourSmoother 356 | instance[is13_smoA].type=cContourSmoother 357 | instance[is13_smoB].type=cContourSmoother 358 | instance[is13_f0sel].type=cDataSelector 359 | 360 | [is13_smoNz:cContourSmoother] 361 | reader.dmLevel = is13_pitchG60;is13_jitterShimmer 362 | writer.dmLevel = is13_lld_nzsmo 363 | \{\cm[bufferModeConf{../shared/BufferMode.conf.inc}:path to included config to set the buffer mode for the levels before the functionals]} 364 | nameAppend = sma 365 | copyInputName = 1 366 | noPostEOIprocessing = 0 367 | smaWin = 3 368 | noZeroSma = 1 369 | 370 | [is13_f0sel:cDataSelector] 371 | reader.dmLevel = is13_lld_nzsmo 372 | writer.dmLevel = is13_lld_f0_nzsmo 373 | \{\cm[bufferModeConf]} 374 | nameAppend = ff0 375 | selected = F0final_sma 376 | 377 | [is13_smoA:cContourSmoother] 378 | reader.dmLevel = is13_audspecSum;is13_audspecRastaSum;is13_energy;is13_zcr 379 | writer.dmLevel = is13_lldA_smo 380 | \{\cm[bufferModeConf]} 381 | nameAppend = sma 382 | copyInputName = 1 383 | noPostEOIprocessing = 0 384 | smaWin = 3 385 | 386 | [is13_smoB:cContourSmoother] 387 | reader.dmLevel = is13_audspecRasta;is13_spectral;is13_mfcc1_12 388 | writer.dmLevel = is13_lldB_smo 389 | \{\cm[bufferModeConf]} 390 | nameAppend = sma 391 | copyInputName = 1 392 | noPostEOIprocessing = 0 393 | smaWin = 3 394 | 395 | ;;;;;;;;; deltas 396 | [componentInstances:cComponentManager] 397 | instance[is13_deNz].type=cDeltaRegression 398 | instance[is13_deA].type=cDeltaRegression 399 | instance[is13_deB].type=cDeltaRegression 400 | instance[is13_def0sel].type=cDeltaRegression 401 | 402 | [is13_deNz:cDeltaRegression] 403 | reader.dmLevel = is13_lld_nzsmo 404 | writer.dmLevel = is13_lld_nzsmo_de 405 | \{\cm[bufferModeConf]} 406 | onlyInSegments = 1 407 | zeroSegBound = 1 408 | 409 | [is13_deA:cDeltaRegression] 410 | reader.dmLevel = is13_lldA_smo 411 | writer.dmLevel = is13_lldA_smo_de 412 | \{\cm[bufferModeConf]} 413 | 414 | [is13_deB:cDeltaRegression] 415 | reader.dmLevel = is13_lldB_smo 416 | writer.dmLevel = is13_lldB_smo_de 417 | \{\cm[bufferModeConf]} 418 | 419 | [is13_def0sel:cDeltaRegression] 420 | reader.dmLevel = is13_lld_f0_nzsmo 421 | writer.dmLevel = is13_lld_f0_nzsmo_de 422 | \{\cm[bufferModeConf]} 423 | onlyInSegments = 1 424 | zeroSegBound = 1 425 | 426 | 427 | -------------------------------------------------------------------------------- /opensmile/core/config/compare/basic_functionals_2016.conf.inc: -------------------------------------------------------------------------------- 1 | 2 | /////////////////////////////////////////////////////////////////////////////////////// 3 | ///////// > openSMILE configuration file < ////////////////// 4 | ///////// > basic functionals < ////////////////// 5 | ///////// (c) audEERING GmbH, ////////////////// 6 | ///////// All rights reserved. ////////////////// 7 | /////////////////////////////////////////////////////////////////////////////////////// 8 | 9 | /* 10 | Basic functionals: 11 | min, max, range, range-ratio, mean, stddev, linear slope & errorQ, quad slope & error Q 12 | */ 13 | 14 | [componentInstances:cComponentManager] 15 | instance[basic_func].type=cFunctionals 16 | 17 | [basic_func:cFunctionals] 18 | reader.dmLevel=is13_lld_nzsmo;is13_lldA_smo;is13_lldB_smo;is13_lld_nzsmo_de;is13_lldA_smo_de;is13_lldB_smo_de 19 | writer.dmLevel=compare2016_func 20 | copyInputName = 1 21 | \{\cm[bufferModeRbConf]} 22 | \{\cm[frameModeFunctionalsConf{../shared/FrameModeFunctionals.conf.inc}:path to included config to set frame mode for all functionals]} 23 | functionalsEnabled=Regression;Moments;Percentiles 24 | Regression.linregc1 = 1 25 | Regression.linregc2 = 0 26 | Regression.linregerrA = 0 27 | Regression.linregerrQ = 1 28 | Regression.qregc1 = 1 29 | Regression.qregc2 = 0 30 | Regression.qregc3 = 0 31 | Regression.qregerrA = 0 32 | Regression.qregerrQ = 1 33 | Regression.centroid = 0 34 | Regression.oldBuggyQerr = 0 35 | Regression.normInputs = 1 36 | Regression.normRegCoeff = 2 37 | Regression.doRatioLimit = 1 38 | Moments.variance = 0 39 | Moments.stddev = 1 40 | Moments.skewness = 0 41 | Moments.kurtosis = 0 42 | Moments.amean = 1 43 | Moments.doRatioLimit = 1 44 | Percentiles.quartiles = 0 45 | Percentiles.iqr = 0 46 | Percentiles.iqq = 0 47 | Percentiles.percentile[0] = 0.06 48 | Percentiles.percentile[1] = 0.94 49 | Percentiles.pctlrange[0] = 0-1 50 | ; NOTE: in compare2016_basic, pctlquotient was never used 51 | ; as the binary had the option, but it was not implemented. 52 | ; Percentiles.pctlquotient[0] = 0-1 53 | Percentiles.interp = 1 54 | 55 | -------------------------------------------------------------------------------- /opensmile/core/config/egemaps/v01a/eGeMAPSv01a.conf: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file, Geneva feature set < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014 by audEERING ////////////////// 5 | ///////// All rights reserved. See file COPYING for details. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | ;;;;;;; component list ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 9 | 10 | [componentInstances:cComponentManager] 11 | instance[dataMemory].type=cDataMemory 12 | printLevelStats=0 13 | 14 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;; main section ;;;;;;;;;;;;;;;;;;;;;;;;;;; 15 | 16 | \{\cm[source{?}:include external source]} 17 | \{../../gemaps/v01a/GeMAPSv01a_core.lld.conf.inc} 18 | \{eGeMAPSv01a_core.lld.conf.inc} 19 | \{../../gemaps/v01a/GeMAPSv01a_core.func.conf.inc} 20 | \{eGeMAPSv01a_core.func.conf.inc} 21 | 22 | [componentInstances:cComponentManager] 23 | instance[lldconcat].type=cVectorConcat 24 | instance[funcconcat].type=cVectorConcat 25 | 26 | [lldconcat:cVectorConcat] 27 | reader.dmLevel = egemapsv01a_lldsetE_smo;gemapsv01a_lldsetF_smo 28 | writer.dmLevel = lld 29 | includeSingleElementFields = 1 30 | 31 | [funcconcat:cVectorConcat] 32 | reader.dmLevel = gemapsv01a_functionalsF0;gemapsv01a_functionalsLoudness;egemapsv01a_functionalsMeanStddevZ;egemapsv01a_functionalsMeanStddevVoiced;egemapsv01a_functionalsMeanUnvoiced;gemapsv01a_temporalSet;egemapsv01a_leq 33 | writer.dmLevel = func 34 | includeSingleElementFields = 1 35 | 36 | \{\cm[sink{?}:include external sink]} 37 | -------------------------------------------------------------------------------- /opensmile/core/config/egemaps/v01a/eGeMAPSv01a_core.func.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file, Geneva feature set < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014 by audEERING ////////////////// 5 | ///////// All rights reserved. See file COPYING for details. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | 9 | [componentInstances:cComponentManager] 10 | instance[egemapsv01a_leqLin].type= cFunctionals 11 | instance[egemapsv01a_leq].type = cVectorOperation 12 | 13 | ;; LEq 14 | [egemapsv01a_leqLin:cFunctionals] 15 | reader.dmLevel = egemapsv01a_energyRMS 16 | writer.dmLevel = egemapsv01a_leqLin 17 | // nameAppend = 18 | preserveFields = 1 19 | \{\cm[bufferModeRbConf]} 20 | copyInputName = 1 21 | \{\cm[frameModeFunctionalsConf]} 22 | noPostEOIprocessing = 0 23 | functionalsEnabled = Means 24 | Means.amean = 1 25 | Means.posamean = 0 26 | Means.absmean = 0 27 | Means.qmean = 0 28 | Means.nzamean = 0 29 | Means.nzabsmean = 0 30 | Means.nzqmean = 0 31 | Means.nzgmean = 0 32 | Means.nnz = 0 33 | 34 | [egemapsv01a_leq:cVectorOperation] 35 | reader.dmLevel = egemapsv01a_leqLin 36 | writer.dmLevel = egemapsv01a_leq 37 | nameBase = equivalentSoundLevel 38 | copyInputName = 1 39 | processArrayFields = 0 40 | operation = dBp 41 | appendOperationToName = 1 42 | 43 | 44 | 45 | ;;;;;;;;;;;;;;;;;;;;; functionals / summaries ;;;;;;;;;;;;;;; 46 | 47 | [componentInstances:cComponentManager] 48 | instance[egemapsv01a_functionalsMVR].type=cFunctionals 49 | instance[egemapsv01a_functionalsMeanUV].type=cFunctionals 50 | instance[egemapsv01a_functionalsMVRVoiced].type = cFunctionals 51 | 52 | [egemapsv01a_functionalsMVR:cFunctionals] 53 | reader.dmLevel = egemapsv01a_lldSetNoF0AndLoudnessZ_smo 54 | writer.dmLevel = egemapsv01a_functionalsMeanStddevZ 55 | \{\cm[bufferModeRbConf]} 56 | copyInputName = 1 57 | \{\cm[frameModeFunctionalsConf]} 58 | functionalsEnabled = Moments 59 | Moments.variance = 0 60 | Moments.stddev = 0 61 | Moments.stddevNorm = 2 62 | Moments.skewness = 0 63 | Moments.kurtosis = 0 64 | Moments.amean = 1 65 | nonZeroFuncts = 0 66 | masterTimeNorm = segment 67 | 68 | [egemapsv01a_functionalsMeanUV:cFunctionals] 69 | reader.dmLevel = egemapsv01a_lldSetSpectralZ_smo 70 | writer.dmLevel = egemapsv01a_functionalsMeanUnvoiced 71 | \{\cm[bufferModeRbConf]} 72 | copyInputName = 1 73 | \{\cm[frameModeFunctionalsConf]} 74 | functionalsEnabled = Moments 75 | Moments.variance = 0 76 | Moments.stddev = 0 77 | Moments.stddevNorm = 0 78 | Moments.skewness = 0 79 | Moments.kurtosis = 0 80 | Moments.amean = 1 81 | nonZeroFuncts = 1 82 | masterTimeNorm = segment 83 | 84 | [egemapsv01a_functionalsMVRVoiced:cFunctionals] 85 | reader.dmLevel = egemapsv01a_lldSetNoF0AndLoudnessNz_smo;egemapsv01a_lldSetSpectralNz_smo 86 | writer.dmLevel = egemapsv01a_functionalsMeanStddevVoiced 87 | \{\cm[bufferModeRbConf]} 88 | copyInputName = 1 89 | \{\cm[frameModeFunctionalsConf]} 90 | functionalsEnabled = Moments 91 | Moments.variance = 0 92 | Moments.stddev = 0 93 | Moments.stddevNorm = 2 94 | Moments.skewness = 0 95 | Moments.kurtosis = 0 96 | Moments.amean = 1 97 | nonZeroFuncts = 1 98 | masterTimeNorm = segment 99 | 100 | 101 | -------------------------------------------------------------------------------- /opensmile/core/config/egemaps/v01a/eGeMAPSv01a_core.lld.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file, Geneva feature set < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014 by audEERING ////////////////// 5 | ///////// All rights reserved. See file COPYING for details. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | ;; for LEq 9 | [componentInstances:cComponentManager] 10 | instance[egemapsv01a_energyRMS].type=cEnergy 11 | 12 | [egemapsv01a_energyRMS:cEnergy] 13 | reader.dmLevel = gemapsv01a_frame25 14 | writer.dmLevel = egemapsv01a_energyRMS 15 | \{\cm[bufferModeConf]} 16 | htkcompatible = 0 17 | rms = 0 18 | energy2 = 1 19 | log = 0 20 | 21 | 22 | ;;;;;;;;;;;;;;; spectral 23 | [componentInstances:cComponentManager] 24 | instance[egemapsv01a_logSpectral_flux].type=cSpectral 25 | 26 | [egemapsv01a_logSpectral_flux:cSpectral] 27 | reader.dmLevel=gemapsv01a_fftmagH25 28 | writer.dmLevel=egemapsv01a_logSpectral_flux 29 | \{\cm[bufferModeRbLagConf]} 30 | flux = 1 31 | centroid = 0 32 | maxPos=0 33 | minPos=0 34 | entropy = 0 35 | flatness = 0 36 | harmonicity = 0 37 | sharpness = 0 38 | variance=0 39 | skewness=0 40 | kurtosis=0 41 | alphaRatio = 0 42 | hammarbergIndex = 0 43 | slope = 0 44 | normBandEnergies = 1 45 | squareInput = 1 46 | useLogSpectrum = 1 47 | freqRange = 0-5000 48 | oldSlopeScale = 0 49 | 50 | ;;;;;;;;;; cepstral ;;;;;;;;;;;;;;;;;;; 51 | [componentInstances:cComponentManager] 52 | instance[egemapsv01a_melspecMfcc].type=cMelspec 53 | instance[egemapsv01a_mfcc].type=cMfcc 54 | 55 | [egemapsv01a_melspecMfcc:cMelspec] 56 | reader.dmLevel=gemapsv01a_fftmagH25 57 | writer.dmLevel=egemapsv01a_melspecMfcc 58 | copyInputName = 1 59 | processArrayFields = 1 60 | ; htk compatible sample value scaling 61 | htkcompatible = 1 62 | nBands = 26 63 | ; use power spectrum instead of magnitude spectrum 64 | usePower = 1 65 | lofreq = 20 66 | hifreq = 8000 67 | specScale = mel 68 | inverse = 0 69 | 70 | [egemapsv01a_mfcc:cMfcc] 71 | reader.dmLevel=egemapsv01a_melspecMfcc 72 | writer.dmLevel=egemapsv01a_mfcc 73 | \{\cm[bufferModeRbLagConf]} 74 | copyInputName = 0 75 | processArrayFields = 1 76 | firstMfcc = 1 77 | lastMfcc = 4 78 | cepLifter = 22.0 79 | htkcompatible = 1 80 | 81 | 82 | ;;;;;;;;;;;; collecting, filtering, and renaming ;;;;;;;;;;;;;;;;, 83 | 84 | /* 85 | logSpectral Hammarberg, AlphaRatio, spectralSlope 0-500, 500-1500 86 | harmonics H1-H2, H1-A3, HNRlog 87 | logPitch F0finalLog 88 | jitterShimmer jitterLocal, shimmerLocal 89 | loudness 90 | formants F1-3 freq, F1 bandw (check!) 91 | harmonics F1-3 level relative 92 | */ 93 | 94 | [componentInstances:cComponentManager] 95 | instance[egemapsv01a_lldSetSelectorE].type=cDataSelector 96 | instance[egemapsv01a_lldSetSelectorNoF0LoudnZ].type=cDataSelector 97 | instance[egemapsv01a_lldSetSelectorNoF0LoudnNz].type = cDataSelector 98 | instance[egemapsv01a_logSpectralVoiced].type = cValbasedSelector 99 | instance[egemapsv01a_logSpectralUnvoiced].type = cValbasedSelector 100 | instance[egemapsv01a_lldSetSelectorSpectralNz].type=cDataSelector 101 | instance[egemapsv01a_lldSetSelectorSpectralZ].type=cDataSelector 102 | 103 | [egemapsv01a_lldSetSelectorE:cDataSelector] 104 | reader.dmLevel = gemapsv01a_loudness;gemapsv01a_logSpectral;egemapsv01a_logSpectral_flux;egemapsv01a_mfcc 105 | writer.dmLevel = egemapsv01a_lldsetE 106 | \{\cm[bufferModeRbConf]} 107 | selected = loudness;pcm_fftMag_alphaRatioDB;pcm_fftMag_hammarbergIndexDB;pcm_fftMag_logSpectralSlopeOfBand0-500;pcm_fftMag_logSpectralSlopeOfBand500-1500;pcm_fftMag_spectralFlux;mfcc[1];mfcc[2];mfcc[3];mfcc[4] 108 | newNames = Loudness;alphaRatio;hammarbergIndex;slope0-500;slope500-1500;spectralFlux;mfcc1;mfcc2;mfcc3;mfcc4 109 | 110 | [gemapsv01a_lldSetSelectorNoF0LoudnNz:cDataSelector] 111 | reader.dmLevel = gemapsv01a_jitterShimmer;gemapsv01a_harmonics;gemapsv01a_formantsNz 112 | writer.dmLevel = gemapsv01a_lldSetNoF0AndLoudnessNz 113 | \{\cm[bufferModeRbConf]} 114 | selected = jitterLocal;shimmerLocalDB;HarmonicsToNoiseRatioACFLogdB;HarmonicDifferenceLogRelH1-H2;HarmonicDifferenceLogRelH1-A3;formantFreqLpc[1];formantBandwidthLpc[1];FormantAmplitudeByMaxHarmonicLogRelF0[1];formantFreqLpc[2];FormantAmplitudeByMaxHarmonicLogRelF0[2];formantFreqLpc[3];FormantAmplitudeByMaxHarmonicLogRelF0[3] 115 | newNames = jitterLocal;shimmerLocaldB;HNRdBACF;logRelF0-H1-H2;logRelF0-H1-A3;F1frequency;F1bandwidth;F1amplitudeLogRelF0;F2frequency;F2amplitudeLogRelF0;F3frequency;F3amplitudeLogRelF0 116 | 117 | 118 | [egemapsv01a_lldSetSelectorNoF0LoudnZ:cDataSelector] 119 | ; gemapsv01a_logSpectral 120 | reader.dmLevel = egemapsv01a_logSpectral_flux;egemapsv01a_mfcc 121 | writer.dmLevel = egemapsv01a_lldSetNoF0AndLoudnessZ 122 | \{\cm[bufferModeRbConf]} 123 | selected = pcm_fftMag_spectralFlux;mfcc[1];mfcc[2];mfcc[3];mfcc[4] 124 | newNames = spectralFlux;mfcc1;mfcc2;mfcc3;mfcc4 125 | 126 | [egemapsv01a_lldSetSelectorNoF0LoudnNz:cDataSelector] 127 | reader.dmLevel = gemapsv01a_jitterShimmer;gemapsv01a_harmonics;gemapsv01a_formantsNz 128 | writer.dmLevel = egemapsv01a_lldSetNoF0AndLoudnessNz 129 | \{\cm[bufferModeRbConf]} 130 | selected = jitterLocal;shimmerLocalDB;HarmonicsToNoiseRatioACFLogdB;HarmonicDifferenceLogRelH1-H2;HarmonicDifferenceLogRelH1-A3;formantFreqLpc[1];formantBandwidthLpc[1];FormantAmplitudeByMaxHarmonicLogRelF0[1];formantFreqLpc[2];formantBandwidthLpc[2];FormantAmplitudeByMaxHarmonicLogRelF0[2];formantFreqLpc[3];formantBandwidthLpc[3];FormantAmplitudeByMaxHarmonicLogRelF0[3] 131 | newNames = jitterLocal;shimmerLocaldB;HNRdBACF;logRelF0-H1-H2;logRelF0-H1-A3;F1frequency;F1bandwidth;F1amplitudeLogRelF0;F2frequency;F2bandwidth;F2amplitudeLogRelF0;F3frequency;F3bandwidth;F3amplitudeLogRelF0 132 | 133 | // select logspectral and mfcc for voiced sounds 134 | [egemapsv01a_logSpectralVoiced:cValbasedSelector] 135 | reader.dmLevel = gemapsv01a_lld_single_logF0;gemapsv01a_logSpectral;egemapsv01a_logSpectral_flux;egemapsv01a_mfcc 136 | writer.dmLevel = egemapsv01a_logSpectralVoiced 137 | \{\cm[bufferModeRbLagConf]} 138 | idx=0 139 | threshold=0.000001 140 | removeIdx=1 141 | zeroVec=1 142 | outputVal=0.0 143 | 144 | // select logspectral and mfcc for voiced sounds 145 | [egemapsv01a_logSpectralUnvoiced:cValbasedSelector] 146 | reader.dmLevel = gemapsv01a_lld_single_logF0;gemapsv01a_logSpectral;egemapsv01a_logSpectral_flux 147 | writer.dmLevel = egemapsv01a_logSpectralUnvoiced 148 | \{\cm[bufferModeRbLagConf]} 149 | idx=0 150 | invert = 1 151 | threshold = 0.000001 152 | removeIdx=1 153 | zeroVec=1 154 | outputVal=0.0 155 | 156 | [egemapsv01a_lldSetSelectorSpectralNz:cDataSelector] 157 | reader.dmLevel = egemapsv01a_logSpectralVoiced 158 | writer.dmLevel = egemapsv01a_lldSetSpectralNz 159 | \{\cm[bufferModeRbConf]} 160 | selected = pcm_fftMag_alphaRatioDB;pcm_fftMag_hammarbergIndexDB;pcm_fftMag_logSpectralSlopeOfBand0-500;pcm_fftMag_logSpectralSlopeOfBand500-1500;pcm_fftMag_spectralFlux;mfcc[1];mfcc[2];mfcc[3];mfcc[4] 161 | newNames = alphaRatioV;hammarbergIndexV;slopeV0-500;slopeV500-1500;spectralFluxV;mfcc1V;mfcc2V;mfcc3V;mfcc4V 162 | 163 | [egemapsv01a_lldSetSelectorSpectralZ:cDataSelector] 164 | reader.dmLevel = egemapsv01a_logSpectralUnvoiced 165 | writer.dmLevel = egemapsv01a_lldSetSpectralZ 166 | \{\cm[bufferModeRbConf]} 167 | selected = pcm_fftMag_alphaRatioDB;pcm_fftMag_hammarbergIndexDB;pcm_fftMag_logSpectralSlopeOfBand0-500;pcm_fftMag_logSpectralSlopeOfBand500-1500;pcm_fftMag_spectralFlux 168 | newNames = alphaRatioUV;hammarbergIndexUV;slopeUV0-500;slopeUV500-1500;spectralFluxUV 169 | 170 | 171 | ;;;;;;;;;;;;;;;; smoothing ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 172 | [componentInstances:cComponentManager] 173 | instance[egemapsv01a_smoE].type=cContourSmoother 174 | instance[egemapsv01a_smoNoFLZ].type=cContourSmoother 175 | instance[egemapsv01a_smoNoF0andLoudnNz].type=cContourSmoother 176 | instance[egemapsv01a_smoSpectralZ].type=cContourSmoother 177 | instance[egemapsv01a_smoSpectralNz].type=cContourSmoother 178 | 179 | [egemapsv01a_smoE:cContourSmoother] 180 | reader.dmLevel = egemapsv01a_lldsetE 181 | writer.dmLevel = egemapsv01a_lldsetE_smo 182 | nameAppend = sma3 183 | copyInputName = 1 184 | noPostEOIprocessing = 0 185 | smaWin = 3 186 | noZeroSma = 0 187 | 188 | [egemapsv01a_smoNoFLZ:cContourSmoother] 189 | reader.dmLevel = egemapsv01a_lldSetNoF0AndLoudnessZ 190 | writer.dmLevel = egemapsv01a_lldSetNoF0AndLoudnessZ_smo 191 | \{\cm[bufferModeConf]} 192 | nameAppend = sma3 193 | copyInputName = 1 194 | noPostEOIprocessing = 0 195 | smaWin = 3 196 | noZeroSma = 0 197 | 198 | [egemapsv01a_smoNoF0andLoudnNz:cContourSmoother] 199 | reader.dmLevel = egemapsv01a_lldSetNoF0AndLoudnessNz 200 | writer.dmLevel = egemapsv01a_lldSetNoF0AndLoudnessNz_smo 201 | \{\cm[bufferModeConf]} 202 | nameAppend = sma3nz 203 | copyInputName = 1 204 | noPostEOIprocessing = 0 205 | smaWin = 3 206 | noZeroSma = 1 207 | 208 | [egemapsv01a_smoSpectralZ:cContourSmoother] 209 | reader.dmLevel = egemapsv01a_lldSetSpectralZ 210 | writer.dmLevel = egemapsv01a_lldSetSpectralZ_smo 211 | \{\cm[bufferModeConf]} 212 | nameAppend = sma3nz 213 | copyInputName = 1 214 | noPostEOIprocessing = 0 215 | smaWin = 3 216 | ; non-zero SMA is ok here, as it is inverted with 0's for the voiced parts 217 | noZeroSma = 1 218 | 219 | [egemapsv01a_smoSpectralNz:cContourSmoother] 220 | reader.dmLevel = egemapsv01a_lldSetSpectralNz 221 | writer.dmLevel = egemapsv01a_lldSetSpectralNz_smo 222 | \{\cm[bufferModeConf]} 223 | nameAppend = sma3nz 224 | copyInputName = 1 225 | noPostEOIprocessing = 0 226 | smaWin = 3 227 | noZeroSma = 1 228 | -------------------------------------------------------------------------------- /opensmile/core/config/egemaps/v01b/eGeMAPSv01b.conf: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file, Geneva feature set < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014, 2020 by audEERING ////////////////// 5 | ///////// All rights reserved. See file COPYING for details. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | ;;;;;;; component list ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 9 | 10 | [componentInstances:cComponentManager] 11 | instance[dataMemory].type=cDataMemory 12 | printLevelStats=0 13 | 14 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;; main section ;;;;;;;;;;;;;;;;;;;;;;;;;;; 15 | 16 | \{\cm[source{?}:include external source]} 17 | \{../../gemaps/v01b/GeMAPSv01b_core.lld.conf.inc} 18 | \{eGeMAPSv01b_core.lld.conf.inc} 19 | \{../../gemaps/v01b/GeMAPSv01b_core.func.conf.inc} 20 | \{eGeMAPSv01b_core.func.conf.inc} 21 | 22 | [componentInstances:cComponentManager] 23 | instance[lldconcat].type=cVectorConcat 24 | instance[funcconcat].type=cVectorConcat 25 | 26 | [lldconcat:cVectorConcat] 27 | reader.dmLevel = egemapsv01b_lldsetE_smo;gemapsv01b_lldsetF_smo 28 | writer.dmLevel = lld 29 | includeSingleElementFields = 1 30 | 31 | [funcconcat:cVectorConcat] 32 | reader.dmLevel = gemapsv01b_functionalsF0;gemapsv01b_functionalsLoudness;egemapsv01b_functionalsMeanStddevZ;egemapsv01b_functionalsMeanStddevVoiced;egemapsv01b_functionalsMeanUnvoiced;gemapsv01b_temporalSet;egemapsv01b_leq 33 | writer.dmLevel = func 34 | includeSingleElementFields = 1 35 | 36 | \{\cm[sink{?}:include external sink]} 37 | -------------------------------------------------------------------------------- /opensmile/core/config/egemaps/v01b/eGeMAPSv01b_core.func.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file, Geneva feature set < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014, 2020 by audEERING ////////////////// 5 | ///////// All rights reserved. See file COPYING for details. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | 9 | [componentInstances:cComponentManager] 10 | instance[egemapsv01b_leqLin].type= cFunctionals 11 | instance[egemapsv01b_leq].type = cVectorOperation 12 | 13 | ;; LEq 14 | [egemapsv01b_leqLin:cFunctionals] 15 | reader.dmLevel = egemapsv01b_energyRMS 16 | writer.dmLevel = egemapsv01b_leqLin 17 | // nameAppend = 18 | preserveFields = 1 19 | \{\cm[bufferModeRbConf]} 20 | copyInputName = 1 21 | \{\cm[frameModeFunctionalsConf]} 22 | noPostEOIprocessing = 0 23 | functionalsEnabled = Means 24 | Means.amean = 1 25 | Means.posamean = 0 26 | Means.absmean = 0 27 | Means.qmean = 0 28 | Means.nzamean = 0 29 | Means.nzabsmean = 0 30 | Means.nzqmean = 0 31 | Means.nzgmean = 0 32 | Means.nnz = 0 33 | 34 | [egemapsv01b_leq:cVectorOperation] 35 | reader.dmLevel = egemapsv01b_leqLin 36 | writer.dmLevel = egemapsv01b_leq 37 | nameBase = equivalentSoundLevel 38 | copyInputName = 1 39 | processArrayFields = 0 40 | operation = dBp 41 | appendOperationToName = 1 42 | 43 | 44 | 45 | ;;;;;;;;;;;;;;;;;;;;; functionals / summaries ;;;;;;;;;;;;;;; 46 | 47 | [componentInstances:cComponentManager] 48 | instance[egemapsv01b_functionalsMVR].type=cFunctionals 49 | instance[egemapsv01b_functionalsMeanUV].type=cFunctionals 50 | instance[egemapsv01b_functionalsMVRVoiced].type = cFunctionals 51 | 52 | [egemapsv01b_functionalsMVR:cFunctionals] 53 | reader.dmLevel = egemapsv01b_lldSetNoF0AndLoudnessZ_smo 54 | writer.dmLevel = egemapsv01b_functionalsMeanStddevZ 55 | \{\cm[bufferModeRbConf]} 56 | copyInputName = 1 57 | \{\cm[frameModeFunctionalsConf]} 58 | functionalsEnabled = Moments 59 | Moments.variance = 0 60 | Moments.stddev = 0 61 | Moments.stddevNorm = 2 62 | Moments.skewness = 0 63 | Moments.kurtosis = 0 64 | Moments.amean = 1 65 | nonZeroFuncts = 0 66 | masterTimeNorm = segment 67 | 68 | [egemapsv01b_functionalsMeanUV:cFunctionals] 69 | reader.dmLevel = egemapsv01b_lldSetSpectralZ_smo 70 | writer.dmLevel = egemapsv01b_functionalsMeanUnvoiced 71 | \{\cm[bufferModeRbConf]} 72 | copyInputName = 1 73 | \{\cm[frameModeFunctionalsConf]} 74 | functionalsEnabled = Moments 75 | Moments.variance = 0 76 | Moments.stddev = 0 77 | Moments.stddevNorm = 0 78 | Moments.skewness = 0 79 | Moments.kurtosis = 0 80 | Moments.amean = 1 81 | nonZeroFuncts = 1 82 | masterTimeNorm = segment 83 | 84 | [egemapsv01b_functionalsMVRVoiced:cFunctionals] 85 | reader.dmLevel = egemapsv01b_lldSetNoF0AndLoudnessNz_smo;egemapsv01b_lldSetSpectralNz_smo 86 | writer.dmLevel = egemapsv01b_functionalsMeanStddevVoiced 87 | \{\cm[bufferModeRbConf]} 88 | copyInputName = 1 89 | \{\cm[frameModeFunctionalsConf]} 90 | functionalsEnabled = Moments 91 | Moments.variance = 0 92 | Moments.stddev = 0 93 | Moments.stddevNorm = 2 94 | Moments.skewness = 0 95 | Moments.kurtosis = 0 96 | Moments.amean = 1 97 | nonZeroFuncts = 1 98 | masterTimeNorm = segment 99 | -------------------------------------------------------------------------------- /opensmile/core/config/egemaps/v01b/eGeMAPSv01b_core.lld.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file, Geneva feature set < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014, 2020 by audEERING ////////////////// 5 | ///////// All rights reserved. See file COPYING for details. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | ;; for LEq 9 | [componentInstances:cComponentManager] 10 | instance[egemapsv01b_energyRMS].type=cEnergy 11 | 12 | [egemapsv01b_energyRMS:cEnergy] 13 | reader.dmLevel = gemapsv01b_frame25 14 | writer.dmLevel = egemapsv01b_energyRMS 15 | \{\cm[bufferModeConf]} 16 | htkcompatible = 0 17 | rms = 0 18 | energy2 = 1 19 | log = 0 20 | 21 | 22 | ;;;;;;;;;;;;;;; spectral 23 | [componentInstances:cComponentManager] 24 | instance[egemapsv01b_logSpectral_flux].type=cSpectral 25 | 26 | [egemapsv01b_logSpectral_flux:cSpectral] 27 | reader.dmLevel=gemapsv01b_fftmagH25 28 | writer.dmLevel=egemapsv01b_logSpectral_flux 29 | \{\cm[bufferModeRbLagConf]} 30 | flux = 1 31 | centroid = 0 32 | maxPos=0 33 | minPos=0 34 | entropy = 0 35 | flatness = 0 36 | harmonicity = 0 37 | sharpness = 0 38 | variance=0 39 | skewness=0 40 | kurtosis=0 41 | alphaRatio = 0 42 | hammarbergIndex = 0 43 | slope = 0 44 | normBandEnergies = 1 45 | squareInput = 1 46 | useLogSpectrum = 1 47 | freqRange = 0-5000 48 | oldSlopeScale = 0 49 | 50 | ;;;;;;;;;; cepstral ;;;;;;;;;;;;;;;;;;; 51 | [componentInstances:cComponentManager] 52 | instance[egemapsv01b_melspecMfcc].type=cMelspec 53 | instance[egemapsv01b_mfcc].type=cMfcc 54 | 55 | [egemapsv01b_melspecMfcc:cMelspec] 56 | reader.dmLevel=gemapsv01b_fftmagH25 57 | writer.dmLevel=egemapsv01b_melspecMfcc 58 | copyInputName = 1 59 | processArrayFields = 1 60 | ; htk compatible sample value scaling 61 | htkcompatible = 1 62 | nBands = 26 63 | ; use power spectrum instead of magnitude spectrum 64 | usePower = 1 65 | lofreq = 20 66 | hifreq = 8000 67 | specScale = mel 68 | inverse = 0 69 | 70 | [egemapsv01b_mfcc:cMfcc] 71 | reader.dmLevel=egemapsv01b_melspecMfcc 72 | writer.dmLevel=egemapsv01b_mfcc 73 | \{\cm[bufferModeRbLagConf]} 74 | copyInputName = 0 75 | processArrayFields = 1 76 | firstMfcc = 1 77 | lastMfcc = 4 78 | cepLifter = 22.0 79 | htkcompatible = 1 80 | 81 | 82 | ;;;;;;;;;;;; collecting, filtering, and renaming ;;;;;;;;;;;;;;;;, 83 | 84 | /* 85 | logSpectral Hammarberg, AlphaRatio, spectralSlope 0-500, 500-1500 86 | harmonics H1-H2, H1-A3, HNRlog 87 | logPitch F0finalLog 88 | jitterShimmer jitterLocal, shimmerLocal 89 | loudness 90 | formants F1-3 freq, F1 bandw (check!) 91 | harmonics F1-3 level relative 92 | */ 93 | 94 | [componentInstances:cComponentManager] 95 | instance[egemapsv01b_lldSetSelectorE].type=cDataSelector 96 | instance[egemapsv01b_lldSetSelectorNoF0LoudnZ].type=cDataSelector 97 | instance[egemapsv01b_lldSetSelectorNoF0LoudnNz].type = cDataSelector 98 | instance[egemapsv01b_logSpectralVoiced].type = cValbasedSelector 99 | instance[egemapsv01b_logSpectralUnvoiced].type = cValbasedSelector 100 | instance[egemapsv01b_lldSetSelectorSpectralNz].type=cDataSelector 101 | instance[egemapsv01b_lldSetSelectorSpectralZ].type=cDataSelector 102 | 103 | [egemapsv01b_lldSetSelectorE:cDataSelector] 104 | reader.dmLevel = gemapsv01b_loudness;gemapsv01b_logSpectral;egemapsv01b_logSpectral_flux;egemapsv01b_mfcc 105 | writer.dmLevel = egemapsv01b_lldsetE 106 | \{\cm[bufferModeRbConf]} 107 | selected = loudness;pcm_fftMag_alphaRatioDB;pcm_fftMag_hammarbergIndexDB;pcm_fftMag_logSpectralSlopeOfBand0-500;pcm_fftMag_logSpectralSlopeOfBand500-1500;pcm_fftMag_spectralFlux;mfcc[1];mfcc[2];mfcc[3];mfcc[4] 108 | newNames = Loudness;alphaRatio;hammarbergIndex;slope0-500;slope500-1500;spectralFlux;mfcc1;mfcc2;mfcc3;mfcc4 109 | 110 | [gemapsv01b_lldSetSelectorNoF0LoudnNz:cDataSelector] 111 | reader.dmLevel = gemapsv01b_jitterShimmer;gemapsv01b_harmonics;gemapsv01b_formantsNz 112 | writer.dmLevel = gemapsv01b_lldSetNoF0AndLoudnessNz 113 | \{\cm[bufferModeRbConf]} 114 | selected = jitterLocal;shimmerLocalDB;HarmonicsToNoiseRatioACFLogdB;HarmonicDifferenceLogRelH1-H2;HarmonicDifferenceLogRelH1-A3;formantFreqLpc[1];formantBandwidthLpc[1];FormantAmplitudeByMaxHarmonicLogRelF0[1];formantFreqLpc[2];FormantAmplitudeByMaxHarmonicLogRelF0[2];formantFreqLpc[3];FormantAmplitudeByMaxHarmonicLogRelF0[3] 115 | newNames = jitterLocal;shimmerLocaldB;HNRdBACF;logRelF0-H1-H2;logRelF0-H1-A3;F1frequency;F1bandwidth;F1amplitudeLogRelF0;F2frequency;F2amplitudeLogRelF0;F3frequency;F3amplitudeLogRelF0 116 | 117 | 118 | [egemapsv01b_lldSetSelectorNoF0LoudnZ:cDataSelector] 119 | ; gemapsv01b_logSpectral 120 | reader.dmLevel = egemapsv01b_logSpectral_flux;egemapsv01b_mfcc 121 | writer.dmLevel = egemapsv01b_lldSetNoF0AndLoudnessZ 122 | \{\cm[bufferModeRbConf]} 123 | selected = pcm_fftMag_spectralFlux;mfcc[1];mfcc[2];mfcc[3];mfcc[4] 124 | newNames = spectralFlux;mfcc1;mfcc2;mfcc3;mfcc4 125 | 126 | [egemapsv01b_lldSetSelectorNoF0LoudnNz:cDataSelector] 127 | reader.dmLevel = gemapsv01b_jitterShimmer;gemapsv01b_harmonics;gemapsv01b_formantsNz 128 | writer.dmLevel = egemapsv01b_lldSetNoF0AndLoudnessNz 129 | \{\cm[bufferModeRbConf]} 130 | selected = jitterLocal;shimmerLocalDB;HarmonicsToNoiseRatioACFLogdB;HarmonicDifferenceLogRelH1-H2;HarmonicDifferenceLogRelH1-A3;formantFreqLpc[1];formantBandwidthLpc[1];FormantAmplitudeByMaxHarmonicLogRelF0[1];formantFreqLpc[2];formantBandwidthLpc[2];FormantAmplitudeByMaxHarmonicLogRelF0[2];formantFreqLpc[3];formantBandwidthLpc[3];FormantAmplitudeByMaxHarmonicLogRelF0[3] 131 | newNames = jitterLocal;shimmerLocaldB;HNRdBACF;logRelF0-H1-H2;logRelF0-H1-A3;F1frequency;F1bandwidth;F1amplitudeLogRelF0;F2frequency;F2bandwidth;F2amplitudeLogRelF0;F3frequency;F3bandwidth;F3amplitudeLogRelF0 132 | 133 | // select logspectral and mfcc for voiced sounds 134 | [egemapsv01b_logSpectralVoiced:cValbasedSelector] 135 | reader.dmLevel = gemapsv01b_lld_single_logF0;gemapsv01b_logSpectral;egemapsv01b_logSpectral_flux;egemapsv01b_mfcc 136 | writer.dmLevel = egemapsv01b_logSpectralVoiced 137 | \{\cm[bufferModeRbLagConf]} 138 | idx=0 139 | threshold=0.000001 140 | removeIdx=1 141 | zeroVec=1 142 | outputVal=0.0 143 | 144 | // select logspectral and mfcc for voiced sounds 145 | [egemapsv01b_logSpectralUnvoiced:cValbasedSelector] 146 | reader.dmLevel = gemapsv01b_lld_single_logF0;gemapsv01b_logSpectral;egemapsv01b_logSpectral_flux 147 | writer.dmLevel = egemapsv01b_logSpectralUnvoiced 148 | \{\cm[bufferModeRbLagConf]} 149 | idx=0 150 | invert = 1 151 | threshold = 0.000001 152 | removeIdx=1 153 | zeroVec=1 154 | outputVal=0.0 155 | 156 | [egemapsv01b_lldSetSelectorSpectralNz:cDataSelector] 157 | reader.dmLevel = egemapsv01b_logSpectralVoiced 158 | writer.dmLevel = egemapsv01b_lldSetSpectralNz 159 | \{\cm[bufferModeRbConf]} 160 | selected = pcm_fftMag_alphaRatioDB;pcm_fftMag_hammarbergIndexDB;pcm_fftMag_logSpectralSlopeOfBand0-500;pcm_fftMag_logSpectralSlopeOfBand500-1500;pcm_fftMag_spectralFlux;mfcc[1];mfcc[2];mfcc[3];mfcc[4] 161 | newNames = alphaRatioV;hammarbergIndexV;slopeV0-500;slopeV500-1500;spectralFluxV;mfcc1V;mfcc2V;mfcc3V;mfcc4V 162 | 163 | [egemapsv01b_lldSetSelectorSpectralZ:cDataSelector] 164 | reader.dmLevel = egemapsv01b_logSpectralUnvoiced 165 | writer.dmLevel = egemapsv01b_lldSetSpectralZ 166 | \{\cm[bufferModeRbConf]} 167 | selected = pcm_fftMag_alphaRatioDB;pcm_fftMag_hammarbergIndexDB;pcm_fftMag_logSpectralSlopeOfBand0-500;pcm_fftMag_logSpectralSlopeOfBand500-1500;pcm_fftMag_spectralFlux 168 | newNames = alphaRatioUV;hammarbergIndexUV;slopeUV0-500;slopeUV500-1500;spectralFluxUV 169 | 170 | 171 | ;;;;;;;;;;;;;;;; smoothing ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 172 | [componentInstances:cComponentManager] 173 | instance[egemapsv01b_smoE].type=cContourSmoother 174 | instance[egemapsv01b_smoNoFLZ].type=cContourSmoother 175 | instance[egemapsv01b_smoNoF0andLoudnNz].type=cContourSmoother 176 | instance[egemapsv01b_smoSpectralZ].type=cContourSmoother 177 | instance[egemapsv01b_smoSpectralNz].type=cContourSmoother 178 | 179 | [egemapsv01b_smoE:cContourSmoother] 180 | reader.dmLevel = egemapsv01b_lldsetE 181 | writer.dmLevel = egemapsv01b_lldsetE_smo 182 | nameAppend = sma3 183 | copyInputName = 1 184 | noPostEOIprocessing = 0 185 | smaWin = 3 186 | noZeroSma = 0 187 | 188 | [egemapsv01b_smoNoFLZ:cContourSmoother] 189 | reader.dmLevel = egemapsv01b_lldSetNoF0AndLoudnessZ 190 | writer.dmLevel = egemapsv01b_lldSetNoF0AndLoudnessZ_smo 191 | \{\cm[bufferModeConf]} 192 | nameAppend = sma3 193 | copyInputName = 1 194 | noPostEOIprocessing = 0 195 | smaWin = 3 196 | noZeroSma = 0 197 | 198 | [egemapsv01b_smoNoF0andLoudnNz:cContourSmoother] 199 | reader.dmLevel = egemapsv01b_lldSetNoF0AndLoudnessNz 200 | writer.dmLevel = egemapsv01b_lldSetNoF0AndLoudnessNz_smo 201 | \{\cm[bufferModeConf]} 202 | nameAppend = sma3nz 203 | copyInputName = 1 204 | noPostEOIprocessing = 0 205 | smaWin = 3 206 | noZeroSma = 1 207 | 208 | [egemapsv01b_smoSpectralZ:cContourSmoother] 209 | reader.dmLevel = egemapsv01b_lldSetSpectralZ 210 | writer.dmLevel = egemapsv01b_lldSetSpectralZ_smo 211 | \{\cm[bufferModeConf]} 212 | nameAppend = sma3nz 213 | copyInputName = 1 214 | noPostEOIprocessing = 0 215 | smaWin = 3 216 | ; non-zero SMA is ok here, as it is inverted with 0's for the voiced parts 217 | noZeroSma = 1 218 | 219 | [egemapsv01b_smoSpectralNz:cContourSmoother] 220 | reader.dmLevel = egemapsv01b_lldSetSpectralNz 221 | writer.dmLevel = egemapsv01b_lldSetSpectralNz_smo 222 | \{\cm[bufferModeConf]} 223 | nameAppend = sma3nz 224 | copyInputName = 1 225 | noPostEOIprocessing = 0 226 | smaWin = 3 227 | noZeroSma = 1 228 | -------------------------------------------------------------------------------- /opensmile/core/config/egemaps/v02/eGeMAPSv02.conf: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file, Geneva feature set < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014, 2020 by audEERING ////////////////// 5 | ///////// All rights reserved. See file COPYING for details. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | ;;;;;;; component list ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 9 | 10 | [componentInstances:cComponentManager] 11 | instance[dataMemory].type=cDataMemory 12 | printLevelStats=0 13 | 14 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;; main section ;;;;;;;;;;;;;;;;;;;;;;;;;;; 15 | 16 | \{\cm[source{?}:include external source]} 17 | \{../../gemaps/v01b/GeMAPSv01b_core.lld.conf.inc} 18 | \{eGeMAPSv02_core.lld.conf.inc} 19 | \{../../gemaps/v01b/GeMAPSv01b_core.func.conf.inc} 20 | \{eGeMAPSv02_core.func.conf.inc} 21 | 22 | [componentInstances:cComponentManager] 23 | instance[lldconcat].type=cVectorConcat 24 | instance[funcconcat].type=cVectorConcat 25 | 26 | [lldconcat:cVectorConcat] 27 | reader.dmLevel = egemapsv02_lldsetE_smo;egemapsv02_lldsetF_smo 28 | writer.dmLevel = lld 29 | includeSingleElementFields = 1 30 | 31 | [funcconcat:cVectorConcat] 32 | reader.dmLevel = gemapsv01b_functionalsF0;gemapsv01b_functionalsLoudness;egemapsv02_functionalsMeanStddevZ;egemapsv02_functionalsMeanStddevVoiced;egemapsv02_functionalsMeanUnvoiced;gemapsv01b_temporalSet;egemapsv02_leq 33 | writer.dmLevel = func 34 | includeSingleElementFields = 1 35 | 36 | \{\cm[sink{?}:include external sink]} 37 | -------------------------------------------------------------------------------- /opensmile/core/config/egemaps/v02/eGeMAPSv02_core.func.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file, Geneva feature set < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014, 2020 by audEERING ////////////////// 5 | ///////// All rights reserved. See file COPYING for details. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | 9 | [componentInstances:cComponentManager] 10 | instance[egemapsv02_leqLin].type= cFunctionals 11 | instance[egemapsv02_leq].type = cVectorOperation 12 | 13 | ;; LEq 14 | [egemapsv02_leqLin:cFunctionals] 15 | reader.dmLevel = egemapsv02_energyRMS 16 | writer.dmLevel = egemapsv02_leqLin 17 | // nameAppend = 18 | preserveFields = 1 19 | \{\cm[bufferModeRbConf]} 20 | copyInputName = 1 21 | \{\cm[frameModeFunctionalsConf]} 22 | noPostEOIprocessing = 0 23 | functionalsEnabled = Means 24 | Means.amean = 1 25 | Means.posamean = 0 26 | Means.absmean = 0 27 | Means.qmean = 0 28 | Means.nzamean = 0 29 | Means.nzabsmean = 0 30 | Means.nzqmean = 0 31 | Means.nzgmean = 0 32 | Means.nnz = 0 33 | 34 | [egemapsv02_leq:cVectorOperation] 35 | reader.dmLevel = egemapsv02_leqLin 36 | writer.dmLevel = egemapsv02_leq 37 | nameBase = equivalentSoundLevel 38 | copyInputName = 1 39 | processArrayFields = 0 40 | operation = dBp 41 | appendOperationToName = 1 42 | 43 | 44 | 45 | ;;;;;;;;;;;;;;;;;;;;; functionals / summaries ;;;;;;;;;;;;;;; 46 | 47 | [componentInstances:cComponentManager] 48 | instance[egemapsv02_functionalsMVR].type=cFunctionals 49 | instance[egemapsv02_functionalsMeanUV].type=cFunctionals 50 | instance[egemapsv02_functionalsMVRVoiced].type = cFunctionals 51 | 52 | [egemapsv02_functionalsMVR:cFunctionals] 53 | reader.dmLevel = egemapsv02_lldSetNoF0AndLoudnessZ_smo 54 | writer.dmLevel = egemapsv02_functionalsMeanStddevZ 55 | \{\cm[bufferModeRbConf]} 56 | copyInputName = 1 57 | \{\cm[frameModeFunctionalsConf]} 58 | functionalsEnabled = Moments 59 | Moments.variance = 0 60 | Moments.stddev = 0 61 | Moments.stddevNorm = 2 62 | Moments.skewness = 0 63 | Moments.kurtosis = 0 64 | Moments.amean = 1 65 | nonZeroFuncts = 0 66 | masterTimeNorm = segment 67 | 68 | [egemapsv02_functionalsMeanUV:cFunctionals] 69 | reader.dmLevel = egemapsv02_lldSetSpectralZ_smo 70 | writer.dmLevel = egemapsv02_functionalsMeanUnvoiced 71 | \{\cm[bufferModeRbConf]} 72 | copyInputName = 1 73 | \{\cm[frameModeFunctionalsConf]} 74 | functionalsEnabled = Moments 75 | Moments.variance = 0 76 | Moments.stddev = 0 77 | Moments.stddevNorm = 0 78 | Moments.skewness = 0 79 | Moments.kurtosis = 0 80 | Moments.amean = 1 81 | nonZeroFuncts = 1 82 | masterTimeNorm = segment 83 | 84 | [egemapsv02_functionalsMVRVoiced:cFunctionals] 85 | reader.dmLevel = egemapsv02_lldSetNoF0AndLoudnessNz_smo;egemapsv02_lldSetSpectralNz_smo 86 | writer.dmLevel = egemapsv02_functionalsMeanStddevVoiced 87 | \{\cm[bufferModeRbConf]} 88 | copyInputName = 1 89 | \{\cm[frameModeFunctionalsConf]} 90 | functionalsEnabled = Moments 91 | Moments.variance = 0 92 | Moments.stddev = 0 93 | Moments.stddevNorm = 2 94 | Moments.skewness = 0 95 | Moments.kurtosis = 0 96 | Moments.amean = 1 97 | nonZeroFuncts = 1 98 | masterTimeNorm = segment 99 | 100 | 101 | -------------------------------------------------------------------------------- /opensmile/core/config/egemaps/v02/eGeMAPSv02_core.lld.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file, Geneva feature set < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014, 2020 by audEERING ////////////////// 5 | ///////// All rights reserved. See file COPYING for details. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | ;; for LEq 9 | [componentInstances:cComponentManager] 10 | instance[egemapsv02_energyRMS].type=cEnergy 11 | 12 | [egemapsv02_energyRMS:cEnergy] 13 | reader.dmLevel = gemapsv01b_frame25 14 | writer.dmLevel = egemapsv02_energyRMS 15 | \{\cm[bufferModeConf]} 16 | htkcompatible = 0 17 | rms = 0 18 | energy2 = 1 19 | log = 0 20 | 21 | 22 | ;;;;;;;;;;;;;;; spectral 23 | [componentInstances:cComponentManager] 24 | instance[egemapsv02_logSpectral_flux].type=cSpectral 25 | 26 | [egemapsv02_logSpectral_flux:cSpectral] 27 | reader.dmLevel=gemapsv01b_fftmagH25 28 | writer.dmLevel=egemapsv02_logSpectral_flux 29 | \{\cm[bufferModeRbLagConf]} 30 | flux = 1 31 | centroid = 0 32 | maxPos=0 33 | minPos=0 34 | entropy = 0 35 | flatness = 0 36 | harmonicity = 0 37 | sharpness = 0 38 | variance=0 39 | skewness=0 40 | kurtosis=0 41 | alphaRatio = 0 42 | hammarbergIndex = 0 43 | slope = 0 44 | normBandEnergies = 1 45 | squareInput = 1 46 | useLogSpectrum = 1 47 | freqRange = 0-5000 48 | oldSlopeScale = 0 49 | 50 | ;;;;;;;;;; cepstral ;;;;;;;;;;;;;;;;;;; 51 | [componentInstances:cComponentManager] 52 | instance[egemapsv02_melspecMfcc].type=cMelspec 53 | instance[egemapsv02_mfcc].type=cMfcc 54 | 55 | [egemapsv02_melspecMfcc:cMelspec] 56 | reader.dmLevel=gemapsv01b_fftmagH25 57 | writer.dmLevel=egemapsv02_melspecMfcc 58 | copyInputName = 1 59 | processArrayFields = 1 60 | ; htk compatible sample value scaling 61 | htkcompatible = 1 62 | nBands = 26 63 | ; use power spectrum instead of magnitude spectrum 64 | usePower = 1 65 | lofreq = 20 66 | hifreq = 8000 67 | specScale = mel 68 | inverse = 0 69 | 70 | [egemapsv02_mfcc:cMfcc] 71 | reader.dmLevel=egemapsv02_melspecMfcc 72 | writer.dmLevel=egemapsv02_mfcc 73 | \{\cm[bufferModeRbLagConf]} 74 | copyInputName = 0 75 | processArrayFields = 1 76 | firstMfcc = 1 77 | lastMfcc = 4 78 | cepLifter = 22.0 79 | htkcompatible = 1 80 | 81 | 82 | ;;;;;;;;;;;; collecting, filtering, and renaming ;;;;;;;;;;;;;;;;, 83 | 84 | /* 85 | logSpectral Hammarberg, AlphaRatio, spectralSlope 0-500, 500-1500 86 | harmonics H1-H2, H1-A3, HNRlog 87 | logPitch F0finalLog 88 | jitterShimmer jitterLocal, shimmerLocal 89 | loudness 90 | formants F1-3 freq, F1 bandw (check!) 91 | harmonics F1-3 level relative 92 | */ 93 | 94 | [componentInstances:cComponentManager] 95 | instance[egemapsv02_lldSetSelectorE].type=cDataSelector 96 | instance[egemapsv02_lldSetSelectorF].type=cDataSelector 97 | instance[egemapsv02_lldSetSelectorNoF0LoudnZ].type=cDataSelector 98 | instance[egemapsv02_lldSetSelectorNoF0LoudnNz].type = cDataSelector 99 | instance[egemapsv02_logSpectralVoiced].type = cValbasedSelector 100 | instance[egemapsv02_logSpectralUnvoiced].type = cValbasedSelector 101 | instance[egemapsv02_lldSetSelectorSpectralNz].type=cDataSelector 102 | instance[egemapsv02_lldSetSelectorSpectralZ].type=cDataSelector 103 | 104 | [egemapsv02_lldSetSelectorE:cDataSelector] 105 | reader.dmLevel = gemapsv01b_loudness;gemapsv01b_logSpectral;egemapsv02_logSpectral_flux;egemapsv02_mfcc 106 | writer.dmLevel = egemapsv02_lldsetE 107 | \{\cm[bufferModeRbConf]} 108 | selected = loudness;pcm_fftMag_alphaRatioDB;pcm_fftMag_hammarbergIndexDB;pcm_fftMag_logSpectralSlopeOfBand0-500;pcm_fftMag_logSpectralSlopeOfBand500-1500;pcm_fftMag_spectralFlux;mfcc[1];mfcc[2];mfcc[3];mfcc[4] 109 | newNames = Loudness;alphaRatio;hammarbergIndex;slope0-500;slope500-1500;spectralFlux;mfcc1;mfcc2;mfcc3;mfcc4 110 | 111 | [egemapsv02_lldSetSelectorF:cDataSelector] 112 | reader.dmLevel = gemapsv01b_logPitch;gemapsv01b_jitterShimmer;gemapsv01b_harmonics;gemapsv01b_formants 113 | writer.dmLevel = egemapsv02_lldsetF 114 | \{\cm[bufferModeRbConf]} 115 | selected = F0finalLog;jitterLocal;shimmerLocalDB;HarmonicsToNoiseRatioACFLogdB;HarmonicDifferenceLogRelH1-H2;HarmonicDifferenceLogRelH1-A3;formantFreqLpc[1];formantBandwidthLpc[1];FormantAmplitudeByMaxHarmonicLogRelF0[1];formantFreqLpc[2];formantBandwidthLpc[2];FormantAmplitudeByMaxHarmonicLogRelF0[2];formantFreqLpc[3];formantBandwidthLpc[3];FormantAmplitudeByMaxHarmonicLogRelF0[3] 116 | newNames = F0semitoneFrom27.5Hz;jitterLocal;shimmerLocaldB;HNRdBACF;logRelF0-H1-H2;logRelF0-H1-A3;F1frequency;F1bandwidth;F1amplitudeLogRelF0;F2frequency;F2bandwidth;F2amplitudeLogRelF0;F3frequency;F3bandwidth;F3amplitudeLogRelF0 117 | 118 | [egemapsv02_lldSetSelectorNoF0LoudnZ:cDataSelector] 119 | ; gemapsv01b_logSpectral 120 | reader.dmLevel = egemapsv02_logSpectral_flux;egemapsv02_mfcc 121 | writer.dmLevel = egemapsv02_lldSetNoF0AndLoudnessZ 122 | \{\cm[bufferModeRbConf]} 123 | selected = pcm_fftMag_spectralFlux;mfcc[1];mfcc[2];mfcc[3];mfcc[4] 124 | newNames = spectralFlux;mfcc1;mfcc2;mfcc3;mfcc4 125 | 126 | [egemapsv02_lldSetSelectorNoF0LoudnNz:cDataSelector] 127 | reader.dmLevel = gemapsv01b_jitterShimmer;gemapsv01b_harmonics;gemapsv01b_formantsNz 128 | writer.dmLevel = egemapsv02_lldSetNoF0AndLoudnessNz 129 | \{\cm[bufferModeRbConf]} 130 | selected = jitterLocal;shimmerLocalDB;HarmonicsToNoiseRatioACFLogdB;HarmonicDifferenceLogRelH1-H2;HarmonicDifferenceLogRelH1-A3;formantFreqLpc[1];formantBandwidthLpc[1];FormantAmplitudeByMaxHarmonicLogRelF0[1];formantFreqLpc[2];formantBandwidthLpc[2];FormantAmplitudeByMaxHarmonicLogRelF0[2];formantFreqLpc[3];formantBandwidthLpc[3];FormantAmplitudeByMaxHarmonicLogRelF0[3] 131 | newNames = jitterLocal;shimmerLocaldB;HNRdBACF;logRelF0-H1-H2;logRelF0-H1-A3;F1frequency;F1bandwidth;F1amplitudeLogRelF0;F2frequency;F2bandwidth;F2amplitudeLogRelF0;F3frequency;F3bandwidth;F3amplitudeLogRelF0 132 | 133 | // select logspectral and mfcc for voiced sounds 134 | [egemapsv02_logSpectralVoiced:cValbasedSelector] 135 | reader.dmLevel = gemapsv01b_lld_single_logF0;gemapsv01b_logSpectral;egemapsv02_logSpectral_flux;egemapsv02_mfcc 136 | writer.dmLevel = egemapsv02_logSpectralVoiced 137 | \{\cm[bufferModeRbLagConf]} 138 | idx=0 139 | threshold=0.000001 140 | removeIdx=1 141 | zeroVec=1 142 | outputVal=0.0 143 | 144 | // select logspectral and mfcc for voiced sounds 145 | [egemapsv02_logSpectralUnvoiced:cValbasedSelector] 146 | reader.dmLevel = gemapsv01b_lld_single_logF0;gemapsv01b_logSpectral;egemapsv02_logSpectral_flux 147 | writer.dmLevel = egemapsv02_logSpectralUnvoiced 148 | \{\cm[bufferModeRbLagConf]} 149 | idx=0 150 | invert = 1 151 | threshold = 0.000001 152 | removeIdx=1 153 | zeroVec=1 154 | outputVal=0.0 155 | 156 | [egemapsv02_lldSetSelectorSpectralNz:cDataSelector] 157 | reader.dmLevel = egemapsv02_logSpectralVoiced 158 | writer.dmLevel = egemapsv02_lldSetSpectralNz 159 | \{\cm[bufferModeRbConf]} 160 | selected = pcm_fftMag_alphaRatioDB;pcm_fftMag_hammarbergIndexDB;pcm_fftMag_logSpectralSlopeOfBand0-500;pcm_fftMag_logSpectralSlopeOfBand500-1500;pcm_fftMag_spectralFlux;mfcc[1];mfcc[2];mfcc[3];mfcc[4] 161 | newNames = alphaRatioV;hammarbergIndexV;slopeV0-500;slopeV500-1500;spectralFluxV;mfcc1V;mfcc2V;mfcc3V;mfcc4V 162 | 163 | [egemapsv02_lldSetSelectorSpectralZ:cDataSelector] 164 | reader.dmLevel = egemapsv02_logSpectralUnvoiced 165 | writer.dmLevel = egemapsv02_lldSetSpectralZ 166 | \{\cm[bufferModeRbConf]} 167 | selected = pcm_fftMag_alphaRatioDB;pcm_fftMag_hammarbergIndexDB;pcm_fftMag_logSpectralSlopeOfBand0-500;pcm_fftMag_logSpectralSlopeOfBand500-1500;pcm_fftMag_spectralFlux 168 | newNames = alphaRatioUV;hammarbergIndexUV;slopeUV0-500;slopeUV500-1500;spectralFluxUV 169 | 170 | 171 | ;;;;;;;;;;;;;;;; smoothing ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 172 | [componentInstances:cComponentManager] 173 | instance[egemapsv02_smoFnz].type=cContourSmoother 174 | instance[egemapsv02_smoE].type=cContourSmoother 175 | instance[egemapsv02_smoNoFLZ].type=cContourSmoother 176 | instance[egemapsv02_smoNoF0andLoudnNz].type=cContourSmoother 177 | instance[egemapsv02_smoSpectralZ].type=cContourSmoother 178 | instance[egemapsv02_smoSpectralNz].type=cContourSmoother 179 | 180 | [egemapsv02_smoFnz:cContourSmoother] 181 | reader.dmLevel = egemapsv02_lldsetF 182 | writer.dmLevel = egemapsv02_lldsetF_smo 183 | nameAppend = sma3nz 184 | copyInputName = 1 185 | noPostEOIprocessing = 0 186 | smaWin = 3 187 | noZeroSma = 1 188 | 189 | [egemapsv02_smoE:cContourSmoother] 190 | reader.dmLevel = egemapsv02_lldsetE 191 | writer.dmLevel = egemapsv02_lldsetE_smo 192 | nameAppend = sma3 193 | copyInputName = 1 194 | noPostEOIprocessing = 0 195 | smaWin = 3 196 | noZeroSma = 0 197 | 198 | [egemapsv02_smoNoFLZ:cContourSmoother] 199 | reader.dmLevel = egemapsv02_lldSetNoF0AndLoudnessZ 200 | writer.dmLevel = egemapsv02_lldSetNoF0AndLoudnessZ_smo 201 | \{\cm[bufferModeConf]} 202 | nameAppend = sma3 203 | copyInputName = 1 204 | noPostEOIprocessing = 0 205 | smaWin = 3 206 | noZeroSma = 0 207 | 208 | [egemapsv02_smoNoF0andLoudnNz:cContourSmoother] 209 | reader.dmLevel = egemapsv02_lldSetNoF0AndLoudnessNz 210 | writer.dmLevel = egemapsv02_lldSetNoF0AndLoudnessNz_smo 211 | \{\cm[bufferModeConf]} 212 | nameAppend = sma3nz 213 | copyInputName = 1 214 | noPostEOIprocessing = 0 215 | smaWin = 3 216 | noZeroSma = 1 217 | 218 | [egemapsv02_smoSpectralZ:cContourSmoother] 219 | reader.dmLevel = egemapsv02_lldSetSpectralZ 220 | writer.dmLevel = egemapsv02_lldSetSpectralZ_smo 221 | \{\cm[bufferModeConf]} 222 | nameAppend = sma3nz 223 | copyInputName = 1 224 | noPostEOIprocessing = 0 225 | smaWin = 3 226 | ; non-zero SMA is ok here, as it is inverted with 0's for the voiced parts 227 | noZeroSma = 1 228 | 229 | [egemapsv02_smoSpectralNz:cContourSmoother] 230 | reader.dmLevel = egemapsv02_lldSetSpectralNz 231 | writer.dmLevel = egemapsv02_lldSetSpectralNz_smo 232 | \{\cm[bufferModeConf]} 233 | nameAppend = sma3nz 234 | copyInputName = 1 235 | noPostEOIprocessing = 0 236 | smaWin = 3 237 | noZeroSma = 1 238 | -------------------------------------------------------------------------------- /opensmile/core/config/emobase/emobase.conf: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file for live emotion recognition < /////////////// 3 | ///////// base set of 988 features, 1st level functionals ////////////////// 4 | ///////// of low-level descriptors such as MFCC, Pitch, LSP, ... ////////////////// 5 | ///////// ////////////////// 6 | ///////// * written 2009 by Florian Eyben * ////////////////// 7 | ///////// ////////////////// 8 | ///////// (c) 2014 audEERING UG (haftungsbeschr�nkt), ////////////////// 9 | ///////// All rights reserved. ////////////////// 10 | /////////////////////////////////////////////////////////////////////////////////////// 11 | 12 | // Modified version: 13 | // - compatibility of newest 2.1 openSMILE code with openEAR 0.1.0 models 14 | 15 | 16 | /////////////////////////////////////////////////////////////////////////////////////// 17 | ; 18 | ; This section is always required in openSMILE configuration files 19 | ; it configures the componentManager and gives a list of all components which are to be loaded 20 | ; The order in which the components are listed should match 21 | ; the order of the data flow for most efficient processing 22 | ; 23 | /////////////////////////////////////////////////////////////////////////////////////// 24 | [componentInstances:cComponentManager] 25 | ;this line configures the default data memory: 26 | instance[dataMemory].type=cDataMemory 27 | ; instance[waveIn].type=cWaveSource 28 | instance[fr25].type=cFramer 29 | ;;; 40 ms frames features: 30 | instance[fr40].type=cFramer 31 | instance[w40].type=cWindower 32 | instance[fft40].type=cTransformFFT 33 | instance[fftmagphase40].type=cFFTmagphase 34 | instance[acf40].type=cAcf 35 | instance[cepstrum40].type=cAcf 36 | ; Pitch... 37 | instance[pitchACF].type=cPitchACF 38 | ;;; 25 ms frames features: 39 | instance[pe].type=cVectorPreemphasis 40 | instance[win].type=cWindower 41 | instance[fft].type=cTransformFFT 42 | instance[fftmagphase].type=cFFTmagphase 43 | instance[mspec].type=cMelspec 44 | ; MFCC 45 | instance[mfcc].type=cMfcc 46 | instance[lpc].type=cLpc 47 | ; Line Spectral Frequencies 48 | instance[lsp].type=cLsp 49 | ; Zero-Crossings 50 | instance[mzcr].type=cMZcr 51 | ; Intensity and Loudness (narrow-band approximation) 52 | instance[intens].type=cIntensity 53 | ;;; all LLD concattenated and smoothed using a moving average filter 54 | instance[lld].type=cContourSmoother 55 | ; delta coefficients of LLD 56 | instance[delta1].type=cDeltaRegression 57 | ;;; functionals over FULL input (e.g. turns) 58 | instance[functL1].type=cFunctionals 59 | ;;; live classification of emotion (comment out lines to disable them): 60 | ;; run single threaded (nThreads=1) 61 | ; NOTE: a single thread is more efficient for processing small files, since multi-threaded processing involves more 62 | ; overhead during startup, which will make the system slower in the end 63 | nThreads=1 64 | ;; do not show any internal dataMemory level settings 65 | ; (if you want to see them set the value to 1, 2, 3, or 4, depending on the amount of detail you wish) 66 | printLevelStats=0 67 | 68 | 69 | ///////////////////////////////////////////////////////////////////////////////////////////// 70 | ///////////////////////// component configuration //////////////////////////////////////// 71 | ///////////////////////////////////////////////////////////////////////////////////////////// 72 | ; the following sections configure the components listed above 73 | ; a help on configuration parameters can be obtained with 74 | ; SMILExtract -H 75 | ; or 76 | ; SMILExtract -H configTypeName (= componentTypeName) 77 | ///////////////////////////////////////////////////////////////////////////////////////////// 78 | 79 | \{\cm[source{?}:include external sources]} 80 | 81 | [fr40:cFramer] 82 | reader.dmLevel=wave 83 | writer.dmLevel=frames40 84 | frameSize = 0.040 85 | frameStep = 0.010 86 | frameMode = fixed 87 | frameCenterSpecial = left 88 | 89 | [w40:cWindower] 90 | reader.dmLevel=frames40 91 | writer.dmLevel=win40frame 92 | copyInputName = 1 93 | processArrayFields = 1 94 | winFunc = ham 95 | gain = 1.0 96 | offset = 0 97 | 98 | [fft40:cTransformFFT] 99 | reader.dmLevel=win40frame 100 | writer.dmLevel=fftc40 101 | copyInputName = 1 102 | processArrayFields = 1 103 | inverse = 0 104 | ; for compatibility with 2.2.0 and older versions 105 | zeroPadSymmetric = 0 106 | 107 | [fftmagphase40:cFFTmagphase] 108 | reader.dmLevel=fftc40 109 | writer.dmLevel=fftmag40 110 | copyInputName = 1 111 | processArrayFields = 1 112 | inverse = 0 113 | magnitude = 1 114 | phase = 0 115 | 116 | [acf40:cAcf] 117 | reader.dmLevel=fftmag40 118 | writer.dmLevel=acf40 119 | nameAppend = acf 120 | copyInputName = 1 121 | processArrayFields = 1 122 | usePower = 1 123 | cepstrum = 0 124 | acfCepsNormOutput = 0 125 | 126 | [cepstrum40:cAcf] 127 | reader.dmLevel=fftmag40 128 | writer.dmLevel=cepstrum40 129 | nameAppend = acf 130 | copyInputName = 1 131 | processArrayFields = 1 132 | usePower = 1 133 | cepstrum = 1 134 | acfCepsNormOutput = 0 135 | oldCompatCepstrum = 1 136 | absCepstrum = 1 137 | 138 | [pitchACF:cPitchACF] 139 | ; the pitchACF component must ALWAYS read from acf AND cepstrum in the given order! 140 | reader.dmLevel=acf40;cepstrum40 141 | writer.dmLevel=pitch 142 | processArrayFields=0 143 | maxPitch = 500 144 | voiceProb = 1 145 | voiceQual = 0 146 | HNR = 0 147 | F0 = 1 148 | F0raw = 0 149 | F0env = 1 150 | voicingCutoff = 0.550000 151 | 152 | [fr25:cFramer] 153 | reader.dmLevel=wave 154 | writer.dmLevel=frames 155 | frameSize = 0.025 156 | frameStep = 0.010 157 | frameMode = fixed 158 | frameCenterSpecial = left 159 | 160 | 161 | [pe:cVectorPreemphasis] 162 | reader.dmLevel=frames 163 | writer.dmLevel=framespe 164 | copyInputName = 1 165 | processArrayFields = 1 166 | k=0.97 167 | 168 | [win:cWindower] 169 | reader.dmLevel=framespe 170 | writer.dmLevel=winframe 171 | copyInputName = 1 172 | processArrayFields = 1 173 | winFunc = ham 174 | gain = 1.0 175 | offset = 0 176 | 177 | [fft:cTransformFFT] 178 | reader.dmLevel=winframe 179 | writer.dmLevel=fftc 180 | copyInputName = 1 181 | processArrayFields = 1 182 | inverse = 0 183 | ; for compatibility with 2.2.0 and older versions 184 | zeroPadSymmetric = 0 185 | 186 | [fftmagphase:cFFTmagphase] 187 | reader.dmLevel=fftc 188 | writer.dmLevel=fftmag 189 | copyInputName = 1 190 | processArrayFields = 1 191 | inverse = 0 192 | magnitude = 1 193 | phase = 0 194 | 195 | [mspec:cMelspec] 196 | reader.dmLevel=fftmag 197 | writer.dmLevel=mspec1 198 | copyInputName = 1 199 | processArrayFields = 1 200 | htkcompatible = 1 201 | nBands = 26 202 | lofreq = 0 203 | hifreq = 8000 204 | usePower = 1 205 | inverse = 0 206 | specScale = mel 207 | 208 | [mfcc:cMfcc] 209 | reader.dmLevel=mspec1 210 | writer.dmLevel=mfcc1 211 | copyInputName = 0 212 | processArrayFields = 1 213 | firstMfcc = 1 214 | lastMfcc = 12 215 | cepLifter = 22.0 216 | htkcompatible = 1 217 | 218 | [lpc:cLpc] 219 | reader.dmLevel=framespe 220 | writer.dmLevel=lpc 221 | copyInputName = 1 222 | processArrayFields = 1 223 | method = acf 224 | p = 8 225 | saveLPCoeff = 1 226 | lpGain = 0 227 | saveRefCoeff = 0 228 | residual = 0 229 | forwardFilter = 0 230 | lpSpectrum = 0 231 | 232 | [lsp:cLsp] 233 | reader.dmLevel=lpc 234 | writer.dmLevel=lsp 235 | copyInputName = 1 236 | processArrayFields = 0 237 | 238 | [intens:cIntensity] 239 | reader.dmLevel=frames 240 | writer.dmLevel=intens 241 | copyInputName = 1 242 | processArrayFields = 1 243 | intensity=1 244 | loudness =1 245 | 246 | [mzcr:cMZcr] 247 | reader.dmLevel=frames 248 | writer.dmLevel=mzcr 249 | copyInputName = 1 250 | processArrayFields = 1 251 | zcr = 1 252 | amax = 0 253 | mcr = 0 254 | maxmin = 0 255 | dc = 0 256 | 257 | [lld:cContourSmoother] 258 | reader.dmLevel=intens;mfcc1;lsp;mzcr;pitch 259 | writer.dmLevel=lld 260 | writer.levelconf.nT = 2500 261 | writer.levelconf.isRb=0 262 | writer.levelconf.growDyn=1 263 | nameAppend = sma 264 | copyInputName = 1 265 | noPostEOIprocessing = 0 266 | smaWin = 3 267 | 268 | 269 | // ---- delta regression of LLD ---- 270 | [delta1:cDeltaRegression] 271 | reader.dmLevel=lld 272 | writer.dmLevel=lld_de 273 | blocksize=1 274 | writer.levelconf.nT = 2500 275 | writer.levelconf.isRb=0 276 | writer.levelconf.growDyn=1 277 | nameAppend = de 278 | copyInputName = 1 279 | noPostEOIprocessing = 0 280 | deltawin=2 281 | 282 | 283 | // statistical functionals 284 | [functL1:cFunctionals] 285 | reader.dmLevel=lld;lld_de 286 | writer.dmLevel=func 287 | copyInputName = 1 288 | ; frameMode = var will enable the functionals component to listen for messages from the turn detector 289 | frameMode = full 290 | frameCenterSpecial = left 291 | functionalsEnabled=Extremes;Regression;Moments;Percentiles 292 | Extremes.max = 1 293 | Extremes.min = 1 294 | Extremes.range = 1 295 | Extremes.maxpos = 1 296 | Extremes.minpos = 1 297 | Extremes.amean = 1 298 | Extremes.maxameandist = 0 299 | Extremes.minameandist = 0 300 | ; Note: the much better way to normalise the times of maxpos and minpos 301 | ; is 'turn', however for compatibility with old files the default 'frame' 302 | ; is kept here: 303 | Extremes.norm = frame 304 | Regression.linregc1 = 1 305 | Regression.linregc2 = 1 306 | Regression.linregerrA = 1 307 | Regression.linregerrQ = 1 308 | Regression.qregc1 = 0 309 | Regression.qregc2 = 0 310 | Regression.qregc3 = 0 311 | Regression.qregerrA = 0 312 | Regression.qregerrQ = 0 313 | Regression.centroid = 0 314 | Regression.doRatioLimit = 0 315 | Regression.centroidRatioLimit = 0 316 | 317 | Moments.doRatioLimit = 0 318 | Moments.variance = 0 319 | Moments.stddev = 1 320 | Moments.skewness = 1 321 | Moments.kurtosis = 1 322 | Moments.amean = 0 323 | Percentiles.quartiles = 1 324 | Percentiles.iqr = 1 325 | 326 | ////////////////////////////////////////////////////////////////////// 327 | /////////////////// data output configuration ////////////////////// 328 | ////////////////////////////////////////////////////////////////////// 329 | 330 | \{\cm[sink{?}:include external sink]} 331 | 332 | //////---------------------- END -------------------------/////// 333 | -------------------------------------------------------------------------------- /opensmile/core/config/gemaps/v01a/GeMAPSv01a.conf: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file, Geneva feature set < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014 by audEERING ////////////////// 5 | ///////// All rights reserved. See file COPYING for details. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | ;;;;;;; component list ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 9 | 10 | [componentInstances:cComponentManager] 11 | instance[dataMemory].type=cDataMemory 12 | printLevelStats=0 13 | 14 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;; main section ;;;;;;;;;;;;;;;;;;;;;;;;;;; 15 | 16 | \{\cm[source{?}:include external source]} 17 | \{GeMAPSv01a_core.lld.conf.inc} 18 | \{GeMAPSv01a_core.func.conf.inc} 19 | 20 | ;;;;;;;; prepare for standard data output ;;;;;;;;;;;;;;;;;;;;; 21 | 22 | [componentInstances:cComponentManager] 23 | instance[lldconcat].type=cVectorConcat 24 | instance[funcconcat].type=cVectorConcat 25 | 26 | [lldconcat:cVectorConcat] 27 | reader.dmLevel = gemapsv01a_lldsetE_smo;gemapsv01a_lldsetF_smo 28 | writer.dmLevel = lld 29 | includeSingleElementFields = 1 30 | 31 | [funcconcat:cVectorConcat] 32 | reader.dmLevel = gemapsv01a_functionalsF0;gemapsv01a_functionalsLoudness;gemapsv01a_functionalsMeanStddevVoiced;gemapsv01a_functionalsMeanSpectralUnvoiced;gemapsv01a_temporalSet 33 | writer.dmLevel = func 34 | includeSingleElementFields = 1 35 | 36 | \{\cm[sink{?}:include external sink]} 37 | -------------------------------------------------------------------------------- /opensmile/core/config/gemaps/v01a/GeMAPSv01a_core.func.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file, Geneva feature set < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014 by audEERING ////////////////// 5 | ///////// All rights reserved. See file COPYING for details. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | ;;;;;;;;;;;;;;;; temporal statistics: ;;;;;;;;;;;;;;;;;;;;;; 9 | 10 | [componentInstances:cComponentManager] 11 | instance[gemapsv01a_smoF0].type=cContourSmoother 12 | instance[gemapsv01a_smoLoudness].type=cContourSmoother 13 | instance[gemapsv01a_temporalF0].type=cFunctionals 14 | instance[gemapsv01a_temporalF0p].type=cFunctionals 15 | instance[gemapsv01a_temporalLoudness].type=cFunctionals 16 | instance[gemapsv01a_temporalSetNames].type=cDataSelector 17 | 18 | ;;smoothing ;; 19 | [gemapsv01a_smoF0:cContourSmoother] 20 | reader.dmLevel = gemapsv01a_lld_single_logF0 21 | writer.dmLevel = gemapsv01a_lld_single_logF0_smo 22 | \{\cm[bufferModeConf]} 23 | copyInputName = 1 24 | nameAppend = sma3nz 25 | noPostEOIprocessing = 0 26 | smaWin = 3 27 | noZeroSma = 1 28 | 29 | [gemapsv01a_smoLoudness:cContourSmoother] 30 | reader.dmLevel = gemapsv01a_loudness 31 | writer.dmLevel = gemapsv01a_loudness_smo 32 | \{\cm[bufferModeConf]} 33 | nameAppend = sma3 34 | copyInputName = 1 35 | noPostEOIprocessing = 0 36 | smaWin = 3 37 | noZeroSma = 0 38 | 39 | ; functionals for pitch onsets/offsets 40 | [gemapsv01a_temporalF0:cFunctionals] 41 | reader.dmLevel = gemapsv01a_lld_single_logF0_smo 42 | writer.dmLevel = gemapsv01a_temporalF0 43 | \{\cm[bufferModeRbConf]} 44 | //nameAppend = ff0 45 | copyInputName = 1 46 | \{\cm[frameModeFunctionalsConf{../../shared/FrameModeFunctionals.conf.inc}:path to included config to set frame mode for all functionals]} 47 | functionalsEnabled = Segments 48 | Segments.maxNumSeg = 1000 49 | Segments.segmentationAlgorithm = nonX 50 | Segments.X = 0.0 51 | Segments.numSegments = 1 52 | Segments.meanSegLen = 1 53 | Segments.maxSegLen = 0 54 | Segments.minSegLen = 0 55 | Segments.segLenStddev = 1 56 | Segments.norm = second 57 | nonZeroFuncts = 0 58 | masterTimeNorm = second 59 | 60 | // TODO: this is only unvoiced segments, combine with energy / loudness for true pauses! 61 | ; functionals for pitch onsets/offsets 62 | [gemapsv01a_temporalF0p:cFunctionals] 63 | reader.dmLevel = gemapsv01a_lld_single_logF0_smo 64 | writer.dmLevel = gemapsv01a_temporalF0pause 65 | \{\cm[bufferModeRbConf]} 66 | copyInputName = 0 67 | functNameAppend = f0pause 68 | \{\cm[frameModeFunctionalsConf]} 69 | functionalsEnabled = Segments 70 | Segments.maxNumSeg = 1000 71 | Segments.segmentationAlgorithm = eqX 72 | Segments.X = 0.0 73 | Segments.numSegments = 0 74 | Segments.meanSegLen = 1 75 | Segments.maxSegLen = 0 76 | Segments.minSegLen = 0 77 | Segments.segLenStddev = 1 78 | Segments.norm = second 79 | nonZeroFuncts = 0 80 | masterTimeNorm = second 81 | 82 | ; functionals for pitch onsets/offsets 83 | [gemapsv01a_temporalLoudness:cFunctionals] 84 | reader.dmLevel = gemapsv01a_loudness_smo 85 | writer.dmLevel = gemapsv01a_temporalLoudness 86 | \{\cm[bufferModeRbConf]} 87 | //nameAppend = ff0 88 | copyInputName = 1 89 | \{\cm[frameModeFunctionalsConf]} 90 | functionalsEnabled = Peaks2 91 | Peaks2.numPeaks = 1 92 | Peaks2.meanPeakDist = 0 93 | Peaks2.meanPeakDistDelta = 0 94 | Peaks2.peakDistStddev = 0 95 | Peaks2.peakRangeAbs = 0 96 | Peaks2.peakRangeRel = 0 97 | Peaks2.peakMeanAbs = 0 98 | Peaks2.peakMeanMeanDist = 0 99 | Peaks2.peakMeanRel = 0 100 | Peaks2.ptpAmpMeanAbs = 0 101 | Peaks2.ptpAmpMeanRel = 0 102 | Peaks2.ptpAmpStddevAbs = 0 103 | Peaks2.ptpAmpStddevRel = 0 104 | Peaks2.minRangeAbs = 0 105 | Peaks2.minRangeRel = 0 106 | Peaks2.minMeanAbs = 0 107 | Peaks2.minMeanMeanDist = 0 108 | Peaks2.minMeanRel = 0 109 | Peaks2.mtmAmpMeanAbs = 0 110 | Peaks2.mtmAmpMeanRel = 0 111 | Peaks2.mtmAmpStddevAbs = 0 112 | Peaks2.mtmAmpStddevRel = 0 113 | Peaks2.meanRisingSlope = 0 114 | Peaks2.maxRisingSlope = 0 115 | Peaks2.minRisingSlope = 0 116 | Peaks2.stddevRisingSlope = 0 117 | Peaks2.meanFallingSlope = 0 118 | Peaks2.maxFallingSlope = 0 119 | Peaks2.minFallingSlope = 0 120 | Peaks2.stddevFallingSlope = 0 121 | Peaks2.norm = seconds 122 | Peaks2.relThresh = 0.100000 123 | Peaks2.dynRelThresh = 0 124 | ;Peaks2.posDbgOutp = minmax.txt 125 | Peaks2.posDbgAppend = 0 126 | Peaks2.consoleDbg = 0 127 | nonZeroFuncts = 0 128 | masterTimeNorm = second 129 | 130 | ;;;;;;;;;;;;;;;;;; filtering and renaming of names ;;;;;;;;;;; 131 | 132 | [gemapsv01a_temporalSetNames:cDataSelector] 133 | reader.dmLevel = gemapsv01a_temporalLoudness;gemapsv01a_temporalF0;gemapsv01a_temporalF0pause 134 | writer.dmLevel = gemapsv01a_temporalSet 135 | \{\cm[bufferModeRbConf]} 136 | selected = loudness_sma3_numPeaks;F0semitoneFrom27.5Hz_sma3nz_numSegments;F0semitoneFrom27.5Hz_sma3nz_meanSegLen;F0semitoneFrom27.5Hz_sma3nz_segLenStddev;F0semitoneFrom27.5Hz_sma3nz__f0pause_meanSegLen;F0semitoneFrom27.5Hz_sma3nz__f0pause_segLenStddev 137 | newNames = loudnessPeaksPerSec;VoicedSegmentsPerSec;MeanVoicedSegmentLengthSec;StddevVoicedSegmentLengthSec;MeanUnvoicedSegmentLength;StddevUnvoicedSegmentLength 138 | 139 | ;;;;;;;;;;;;;;;;;;;;; functionals / summaries ;;;;;;;;;;;;;;; 140 | 141 | [componentInstances:cComponentManager] 142 | instance[gemapsv01a_functionalsF0].type=cFunctionals 143 | instance[gemapsv01a_functionalsLoudness].type=cFunctionals 144 | instance[gemapsv01a_functionalsMeanSpectralUV].type=cFunctionals 145 | instance[gemapsv01a_functionalsMVRVoiced].type=cFunctionals 146 | 147 | [gemapsv01a_functionalsF0:cFunctionals] 148 | reader.dmLevel = gemapsv01a_lld_single_logF0_smo 149 | writer.dmLevel = gemapsv01a_functionalsF0 150 | \{\cm[bufferModeRbConf]} 151 | copyInputName = 1 152 | \{\cm[frameModeFunctionalsConf]} 153 | functionalsEnabled = Moments ; Percentiles ; Peaks2 154 | Moments.variance = 0 155 | Moments.stddev = 0 156 | Moments.stddevNorm = 2 157 | Moments.skewness = 0 158 | Moments.kurtosis = 0 159 | Moments.amean = 1 160 | Moments.doRatioLimit = 0 161 | Percentiles.quartiles = 0 162 | Percentiles.iqr = 0 163 | Percentiles.percentile[0] = 0.20 164 | Percentiles.percentile[1] = 0.50 165 | Percentiles.percentile[2] = 0.80 166 | Percentiles.pctlrange[0] = 0-2 167 | Percentiles.interp = 1 168 | Peaks2.doRatioLimit = 0 169 | Peaks2.numPeaks = 0 170 | Peaks2.meanPeakDist = 0 171 | Peaks2.meanPeakDistDelta = 0 172 | Peaks2.peakDistStddev = 0 173 | Peaks2.peakRangeAbs = 0 174 | Peaks2.peakRangeRel = 0 175 | Peaks2.peakMeanAbs = 0 176 | Peaks2.peakMeanMeanDist = 0 177 | Peaks2.peakMeanRel = 0 178 | Peaks2.ptpAmpMeanAbs = 0 179 | Peaks2.ptpAmpMeanRel = 0 180 | Peaks2.ptpAmpStddevAbs = 0 181 | Peaks2.ptpAmpStddevRel = 0 182 | Peaks2.minRangeAbs = 0 183 | Peaks2.minRangeRel = 0 184 | Peaks2.minMeanAbs = 0 185 | Peaks2.minMeanMeanDist = 0 186 | Peaks2.minMeanRel = 0 187 | Peaks2.mtmAmpMeanAbs = 0 188 | Peaks2.mtmAmpMeanRel = 0 189 | Peaks2.mtmAmpStddevAbs = 0 190 | Peaks2.mtmAmpStddevRel = 0 191 | Peaks2.meanRisingSlope = 1 192 | Peaks2.maxRisingSlope = 0 193 | Peaks2.minRisingSlope = 0 194 | Peaks2.stddevRisingSlope = 1 195 | Peaks2.meanFallingSlope = 1 196 | Peaks2.maxFallingSlope = 0 197 | Peaks2.minFallingSlope = 0 198 | Peaks2.stddevFallingSlope = 1 199 | Peaks2.norm = seconds 200 | Peaks2.relThresh = 0.100000 201 | Peaks2.dynRelThresh = 0 202 | ;Peaks2.posDbgOutp = minmax.txt 203 | Peaks2.posDbgAppend = 0 204 | Peaks2.consoleDbg = 0 205 | nonZeroFuncts = 1 206 | masterTimeNorm = segment 207 | 208 | [gemapsv01a_functionalsLoudness:cFunctionals] 209 | reader.dmLevel = gemapsv01a_loudness_smo 210 | writer.dmLevel = gemapsv01a_functionalsLoudness 211 | \{\cm[bufferModeRbConf]} 212 | copyInputName = 1 213 | \{\cm[frameModeFunctionalsConf]} 214 | functionalsEnabled = Moments ; Percentiles ; Peaks2 215 | Moments.variance = 0 216 | Moments.stddev = 0 217 | Moments.stddevNorm = 2 218 | Moments.skewness = 0 219 | Moments.kurtosis = 0 220 | Moments.amean = 1 221 | Moments.doRatioLimit = 0 222 | Percentiles.quartiles = 0 223 | Percentiles.iqr = 0 224 | Percentiles.percentile[0] = 0.20 225 | Percentiles.percentile[1] = 0.50 226 | Percentiles.percentile[2] = 0.80 227 | Percentiles.pctlrange[0] = 0-2 228 | Percentiles.interp = 1 229 | Peaks2.doRatioLimit = 0 230 | Peaks2.numPeaks = 0 231 | Peaks2.meanPeakDist = 0 232 | Peaks2.meanPeakDistDelta = 0 233 | Peaks2.peakDistStddev = 0 234 | Peaks2.peakRangeAbs = 0 235 | Peaks2.peakRangeRel = 0 236 | Peaks2.peakMeanAbs = 0 237 | Peaks2.peakMeanMeanDist = 0 238 | Peaks2.peakMeanRel = 0 239 | Peaks2.ptpAmpMeanAbs = 0 240 | Peaks2.ptpAmpMeanRel = 0 241 | Peaks2.ptpAmpStddevAbs = 0 242 | Peaks2.ptpAmpStddevRel = 0 243 | Peaks2.minRangeAbs = 0 244 | Peaks2.minRangeRel = 0 245 | Peaks2.minMeanAbs = 0 246 | Peaks2.minMeanMeanDist = 0 247 | Peaks2.minMeanRel = 0 248 | Peaks2.mtmAmpMeanAbs = 0 249 | Peaks2.mtmAmpMeanRel = 0 250 | Peaks2.mtmAmpStddevAbs = 0 251 | Peaks2.mtmAmpStddevRel = 0 252 | Peaks2.meanRisingSlope = 1 253 | Peaks2.maxRisingSlope = 0 254 | Peaks2.minRisingSlope = 0 255 | Peaks2.stddevRisingSlope = 1 256 | Peaks2.meanFallingSlope = 1 257 | Peaks2.maxFallingSlope = 0 258 | Peaks2.minFallingSlope = 0 259 | Peaks2.stddevFallingSlope = 1 260 | Peaks2.norm = seconds 261 | Peaks2.relThresh = 0.100000 262 | Peaks2.dynRelThresh = 0 263 | ;Peaks2.posDbgOutp = minmax.txt 264 | Peaks2.posDbgAppend = 0 265 | Peaks2.consoleDbg = 0 266 | nonZeroFuncts = 0 267 | masterTimeNorm = segment 268 | 269 | [gemapsv01a_functionalsMeanSpectralUV:cFunctionals] 270 | reader.dmLevel = gemapsv01a_lldSetSpectralZ_smo 271 | writer.dmLevel = gemapsv01a_functionalsMeanSpectralUnvoiced 272 | \{\cm[bufferModeRbConf]} 273 | copyInputName = 1 274 | \{\cm[frameModeFunctionalsConf]} 275 | functionalsEnabled = Moments 276 | Moments.variance = 0 277 | Moments.stddev = 0 278 | Moments.stddevNorm = 0 279 | Moments.skewness = 0 280 | Moments.kurtosis = 0 281 | Moments.amean = 1 282 | Moments.doRatioLimit = 0 283 | nonZeroFuncts = 1 284 | masterTimeNorm = segment 285 | 286 | [gemapsv01a_functionalsMVRVoiced:cFunctionals] 287 | reader.dmLevel = gemapsv01a_lldSetNoF0AndLoudnessNz_smo;gemapsv01a_lldSetSpectralNz_smo; 288 | writer.dmLevel = gemapsv01a_functionalsMeanStddevVoiced 289 | \{\cm[bufferModeRbConf]} 290 | copyInputName = 1 291 | \{\cm[frameModeFunctionalsConf]} 292 | functionalsEnabled = Moments 293 | Moments.variance = 0 294 | Moments.stddev = 0 295 | Moments.stddevNorm = 2 296 | Moments.skewness = 0 297 | Moments.kurtosis = 0 298 | Moments.amean = 1 299 | Moments.doRatioLimit = 0 300 | nonZeroFuncts = 1 301 | masterTimeNorm = segment 302 | 303 | 304 | 305 | -------------------------------------------------------------------------------- /opensmile/core/config/gemaps/v01b/GeMAPSv01b.conf: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file, Geneva feature set < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014, 2020 by audEERING ////////////////// 5 | ///////// All rights reserved. See file COPYING for details. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | ;;;;;;; component list ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 9 | 10 | [componentInstances:cComponentManager] 11 | instance[dataMemory].type=cDataMemory 12 | printLevelStats=0 13 | 14 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;; main section ;;;;;;;;;;;;;;;;;;;;;;;;;;; 15 | 16 | \{\cm[source{?}:include external source]} 17 | \{GeMAPSv01b_core.lld.conf.inc} 18 | \{GeMAPSv01b_core.func.conf.inc} 19 | 20 | ;;;;;;;; prepare for standard data output ;;;;;;;;;;;;;;;;;;;;; 21 | 22 | [componentInstances:cComponentManager] 23 | instance[lldconcat].type=cVectorConcat 24 | instance[funcconcat].type=cVectorConcat 25 | 26 | [lldconcat:cVectorConcat] 27 | reader.dmLevel = gemapsv01b_lldsetE_smo;gemapsv01b_lldsetF_smo 28 | writer.dmLevel = lld 29 | includeSingleElementFields = 1 30 | 31 | [funcconcat:cVectorConcat] 32 | reader.dmLevel = gemapsv01b_functionalsF0;gemapsv01b_functionalsLoudness;gemapsv01b_functionalsMeanStddevVoiced;gemapsv01b_functionalsMeanSpectralUnvoiced;gemapsv01b_temporalSet 33 | writer.dmLevel = func 34 | includeSingleElementFields = 1 35 | 36 | \{\cm[sink{?}:include external sink]} 37 | -------------------------------------------------------------------------------- /opensmile/core/config/gemaps/v01b/GeMAPSv01b_core.func.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file, Geneva feature set < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014, 2020 by audEERING ////////////////// 5 | ///////// All rights reserved. See file COPYING for details. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | ;;;;;;;;;;;;;;;; temporal statistics: ;;;;;;;;;;;;;;;;;;;;;; 9 | 10 | [componentInstances:cComponentManager] 11 | instance[gemapsv01b_smoF0].type=cContourSmoother 12 | instance[gemapsv01b_smoLoudness].type=cContourSmoother 13 | instance[gemapsv01b_temporalF0].type=cFunctionals 14 | instance[gemapsv01b_temporalF0p].type=cFunctionals 15 | instance[gemapsv01b_temporalLoudness].type=cFunctionals 16 | instance[gemapsv01b_temporalSetNames].type=cDataSelector 17 | 18 | ;;smoothing ;; 19 | [gemapsv01b_smoF0:cContourSmoother] 20 | reader.dmLevel = gemapsv01b_lld_single_logF0 21 | writer.dmLevel = gemapsv01b_lld_single_logF0_smo 22 | \{\cm[bufferModeConf]} 23 | copyInputName = 1 24 | nameAppend = sma3nz 25 | noPostEOIprocessing = 0 26 | smaWin = 3 27 | noZeroSma = 1 28 | 29 | [gemapsv01b_smoLoudness:cContourSmoother] 30 | reader.dmLevel = gemapsv01b_loudness 31 | writer.dmLevel = gemapsv01b_loudness_smo 32 | \{\cm[bufferModeConf]} 33 | nameAppend = sma3 34 | copyInputName = 1 35 | noPostEOIprocessing = 0 36 | smaWin = 3 37 | noZeroSma = 0 38 | 39 | ; functionals for pitch onsets/offsets 40 | [gemapsv01b_temporalF0:cFunctionals] 41 | reader.dmLevel = gemapsv01b_lld_single_logF0_smo 42 | writer.dmLevel = gemapsv01b_temporalF0 43 | \{\cm[bufferModeRbConf]} 44 | //nameAppend = ff0 45 | copyInputName = 1 46 | \{\cm[frameModeFunctionalsConf{../../shared/FrameModeFunctionals.conf.inc}:path to included config to set frame mode for all functionals]} 47 | functionalsEnabled = Segments 48 | Segments.maxNumSeg = 1000 49 | Segments.segmentationAlgorithm = nonX 50 | Segments.X = 0.0 51 | Segments.numSegments = 1 52 | Segments.meanSegLen = 1 53 | Segments.maxSegLen = 0 54 | Segments.minSegLen = 0 55 | Segments.segLenStddev = 1 56 | Segments.norm = second 57 | nonZeroFuncts = 0 58 | masterTimeNorm = second 59 | 60 | // TODO: this is only unvoiced segments, combine with energy / loudness for true pauses! 61 | ; functionals for pitch onsets/offsets 62 | [gemapsv01b_temporalF0p:cFunctionals] 63 | reader.dmLevel = gemapsv01b_lld_single_logF0_smo 64 | writer.dmLevel = gemapsv01b_temporalF0pause 65 | \{\cm[bufferModeRbConf]} 66 | copyInputName = 0 67 | functNameAppend = f0pause 68 | \{\cm[frameModeFunctionalsConf]} 69 | functionalsEnabled = Segments 70 | Segments.maxNumSeg = 1000 71 | Segments.segmentationAlgorithm = eqX 72 | Segments.X = 0.0 73 | Segments.numSegments = 0 74 | Segments.meanSegLen = 1 75 | Segments.maxSegLen = 0 76 | Segments.minSegLen = 0 77 | Segments.segLenStddev = 1 78 | Segments.norm = second 79 | nonZeroFuncts = 0 80 | masterTimeNorm = second 81 | 82 | ; functionals for pitch onsets/offsets 83 | [gemapsv01b_temporalLoudness:cFunctionals] 84 | reader.dmLevel = gemapsv01b_loudness_smo 85 | writer.dmLevel = gemapsv01b_temporalLoudness 86 | \{\cm[bufferModeRbConf]} 87 | //nameAppend = ff0 88 | copyInputName = 1 89 | \{\cm[frameModeFunctionalsConf]} 90 | functionalsEnabled = Peaks2 91 | Peaks2.numPeaks = 1 92 | Peaks2.meanPeakDist = 0 93 | Peaks2.meanPeakDistDelta = 0 94 | Peaks2.peakDistStddev = 0 95 | Peaks2.peakRangeAbs = 0 96 | Peaks2.peakRangeRel = 0 97 | Peaks2.peakMeanAbs = 0 98 | Peaks2.peakMeanMeanDist = 0 99 | Peaks2.peakMeanRel = 0 100 | Peaks2.ptpAmpMeanAbs = 0 101 | Peaks2.ptpAmpMeanRel = 0 102 | Peaks2.ptpAmpStddevAbs = 0 103 | Peaks2.ptpAmpStddevRel = 0 104 | Peaks2.minRangeAbs = 0 105 | Peaks2.minRangeRel = 0 106 | Peaks2.minMeanAbs = 0 107 | Peaks2.minMeanMeanDist = 0 108 | Peaks2.minMeanRel = 0 109 | Peaks2.mtmAmpMeanAbs = 0 110 | Peaks2.mtmAmpMeanRel = 0 111 | Peaks2.mtmAmpStddevAbs = 0 112 | Peaks2.mtmAmpStddevRel = 0 113 | Peaks2.meanRisingSlope = 0 114 | Peaks2.maxRisingSlope = 0 115 | Peaks2.minRisingSlope = 0 116 | Peaks2.stddevRisingSlope = 0 117 | Peaks2.meanFallingSlope = 0 118 | Peaks2.maxFallingSlope = 0 119 | Peaks2.minFallingSlope = 0 120 | Peaks2.stddevFallingSlope = 0 121 | Peaks2.norm = seconds 122 | Peaks2.relThresh = 0.100000 123 | Peaks2.dynRelThresh = 0 124 | ;Peaks2.posDbgOutp = minmax.txt 125 | Peaks2.posDbgAppend = 0 126 | Peaks2.consoleDbg = 0 127 | nonZeroFuncts = 0 128 | masterTimeNorm = second 129 | 130 | ;;;;;;;;;;;;;;;;;; filtering and renaming of names ;;;;;;;;;;; 131 | 132 | [gemapsv01b_temporalSetNames:cDataSelector] 133 | reader.dmLevel = gemapsv01b_temporalLoudness;gemapsv01b_temporalF0;gemapsv01b_temporalF0pause 134 | writer.dmLevel = gemapsv01b_temporalSet 135 | \{\cm[bufferModeRbConf]} 136 | selected = loudness_sma3_numPeaks;F0semitoneFrom27.5Hz_sma3nz_numSegments;F0semitoneFrom27.5Hz_sma3nz_meanSegLen;F0semitoneFrom27.5Hz_sma3nz_segLenStddev;F0semitoneFrom27.5Hz_sma3nz__f0pause_meanSegLen;F0semitoneFrom27.5Hz_sma3nz__f0pause_segLenStddev 137 | newNames = loudnessPeaksPerSec;VoicedSegmentsPerSec;MeanVoicedSegmentLengthSec;StddevVoicedSegmentLengthSec;MeanUnvoicedSegmentLength;StddevUnvoicedSegmentLength 138 | 139 | ;;;;;;;;;;;;;;;;;;;;; functionals / summaries ;;;;;;;;;;;;;;; 140 | 141 | [componentInstances:cComponentManager] 142 | instance[gemapsv01b_functionalsF0].type=cFunctionals 143 | instance[gemapsv01b_functionalsLoudness].type=cFunctionals 144 | instance[gemapsv01b_functionalsMeanSpectralUV].type=cFunctionals 145 | instance[gemapsv01b_functionalsMVRVoiced].type=cFunctionals 146 | 147 | [gemapsv01b_functionalsF0:cFunctionals] 148 | reader.dmLevel = gemapsv01b_lld_single_logF0_smo 149 | writer.dmLevel = gemapsv01b_functionalsF0 150 | \{\cm[bufferModeRbConf]} 151 | copyInputName = 1 152 | \{\cm[frameModeFunctionalsConf]} 153 | functionalsEnabled = Moments ; Percentiles ; Peaks2 154 | Moments.variance = 0 155 | Moments.stddev = 0 156 | Moments.stddevNorm = 2 157 | Moments.skewness = 0 158 | Moments.kurtosis = 0 159 | Moments.amean = 1 160 | Moments.doRatioLimit = 0 161 | Percentiles.quartiles = 0 162 | Percentiles.iqr = 0 163 | Percentiles.percentile[0] = 0.20 164 | Percentiles.percentile[1] = 0.50 165 | Percentiles.percentile[2] = 0.80 166 | Percentiles.pctlrange[0] = 0-2 167 | Percentiles.interp = 1 168 | Peaks2.doRatioLimit = 0 169 | Peaks2.numPeaks = 0 170 | Peaks2.meanPeakDist = 0 171 | Peaks2.meanPeakDistDelta = 0 172 | Peaks2.peakDistStddev = 0 173 | Peaks2.peakRangeAbs = 0 174 | Peaks2.peakRangeRel = 0 175 | Peaks2.peakMeanAbs = 0 176 | Peaks2.peakMeanMeanDist = 0 177 | Peaks2.peakMeanRel = 0 178 | Peaks2.ptpAmpMeanAbs = 0 179 | Peaks2.ptpAmpMeanRel = 0 180 | Peaks2.ptpAmpStddevAbs = 0 181 | Peaks2.ptpAmpStddevRel = 0 182 | Peaks2.minRangeAbs = 0 183 | Peaks2.minRangeRel = 0 184 | Peaks2.minMeanAbs = 0 185 | Peaks2.minMeanMeanDist = 0 186 | Peaks2.minMeanRel = 0 187 | Peaks2.mtmAmpMeanAbs = 0 188 | Peaks2.mtmAmpMeanRel = 0 189 | Peaks2.mtmAmpStddevAbs = 0 190 | Peaks2.mtmAmpStddevRel = 0 191 | Peaks2.meanRisingSlope = 1 192 | Peaks2.maxRisingSlope = 0 193 | Peaks2.minRisingSlope = 0 194 | Peaks2.stddevRisingSlope = 1 195 | Peaks2.meanFallingSlope = 1 196 | Peaks2.maxFallingSlope = 0 197 | Peaks2.minFallingSlope = 0 198 | Peaks2.stddevFallingSlope = 1 199 | Peaks2.norm = seconds 200 | Peaks2.relThresh = 0.100000 201 | Peaks2.dynRelThresh = 0 202 | ;Peaks2.posDbgOutp = minmax.txt 203 | Peaks2.posDbgAppend = 0 204 | Peaks2.consoleDbg = 0 205 | nonZeroFuncts = 1 206 | masterTimeNorm = segment 207 | 208 | [gemapsv01b_functionalsLoudness:cFunctionals] 209 | reader.dmLevel = gemapsv01b_loudness_smo 210 | writer.dmLevel = gemapsv01b_functionalsLoudness 211 | \{\cm[bufferModeRbConf]} 212 | copyInputName = 1 213 | \{\cm[frameModeFunctionalsConf]} 214 | functionalsEnabled = Moments ; Percentiles ; Peaks2 215 | Moments.variance = 0 216 | Moments.stddev = 0 217 | Moments.stddevNorm = 2 218 | Moments.skewness = 0 219 | Moments.kurtosis = 0 220 | Moments.amean = 1 221 | Moments.doRatioLimit = 0 222 | Percentiles.quartiles = 0 223 | Percentiles.iqr = 0 224 | Percentiles.percentile[0] = 0.20 225 | Percentiles.percentile[1] = 0.50 226 | Percentiles.percentile[2] = 0.80 227 | Percentiles.pctlrange[0] = 0-2 228 | Percentiles.interp = 1 229 | Peaks2.doRatioLimit = 0 230 | Peaks2.numPeaks = 0 231 | Peaks2.meanPeakDist = 0 232 | Peaks2.meanPeakDistDelta = 0 233 | Peaks2.peakDistStddev = 0 234 | Peaks2.peakRangeAbs = 0 235 | Peaks2.peakRangeRel = 0 236 | Peaks2.peakMeanAbs = 0 237 | Peaks2.peakMeanMeanDist = 0 238 | Peaks2.peakMeanRel = 0 239 | Peaks2.ptpAmpMeanAbs = 0 240 | Peaks2.ptpAmpMeanRel = 0 241 | Peaks2.ptpAmpStddevAbs = 0 242 | Peaks2.ptpAmpStddevRel = 0 243 | Peaks2.minRangeAbs = 0 244 | Peaks2.minRangeRel = 0 245 | Peaks2.minMeanAbs = 0 246 | Peaks2.minMeanMeanDist = 0 247 | Peaks2.minMeanRel = 0 248 | Peaks2.mtmAmpMeanAbs = 0 249 | Peaks2.mtmAmpMeanRel = 0 250 | Peaks2.mtmAmpStddevAbs = 0 251 | Peaks2.mtmAmpStddevRel = 0 252 | Peaks2.meanRisingSlope = 1 253 | Peaks2.maxRisingSlope = 0 254 | Peaks2.minRisingSlope = 0 255 | Peaks2.stddevRisingSlope = 1 256 | Peaks2.meanFallingSlope = 1 257 | Peaks2.maxFallingSlope = 0 258 | Peaks2.minFallingSlope = 0 259 | Peaks2.stddevFallingSlope = 1 260 | Peaks2.norm = seconds 261 | Peaks2.relThresh = 0.100000 262 | Peaks2.dynRelThresh = 0 263 | ;Peaks2.posDbgOutp = minmax.txt 264 | Peaks2.posDbgAppend = 0 265 | Peaks2.consoleDbg = 0 266 | nonZeroFuncts = 0 267 | masterTimeNorm = segment 268 | 269 | [gemapsv01b_functionalsMeanSpectralUV:cFunctionals] 270 | reader.dmLevel = gemapsv01b_lldSetSpectralZ_smo 271 | writer.dmLevel = gemapsv01b_functionalsMeanSpectralUnvoiced 272 | \{\cm[bufferModeRbConf]} 273 | copyInputName = 1 274 | \{\cm[frameModeFunctionalsConf]} 275 | functionalsEnabled = Moments 276 | Moments.variance = 0 277 | Moments.stddev = 0 278 | Moments.stddevNorm = 0 279 | Moments.skewness = 0 280 | Moments.kurtosis = 0 281 | Moments.amean = 1 282 | Moments.doRatioLimit = 0 283 | nonZeroFuncts = 1 284 | masterTimeNorm = segment 285 | 286 | [gemapsv01b_functionalsMVRVoiced:cFunctionals] 287 | reader.dmLevel = gemapsv01b_lldSetNoF0AndLoudnessNz_smo;gemapsv01b_lldSetSpectralNz_smo; 288 | writer.dmLevel = gemapsv01b_functionalsMeanStddevVoiced 289 | \{\cm[bufferModeRbConf]} 290 | copyInputName = 1 291 | \{\cm[frameModeFunctionalsConf]} 292 | functionalsEnabled = Moments 293 | Moments.variance = 0 294 | Moments.stddev = 0 295 | Moments.stddevNorm = 2 296 | Moments.skewness = 0 297 | Moments.kurtosis = 0 298 | Moments.amean = 1 299 | Moments.doRatioLimit = 0 300 | nonZeroFuncts = 1 301 | masterTimeNorm = segment 302 | 303 | 304 | 305 | -------------------------------------------------------------------------------- /opensmile/core/config/gemaps/v01b/GeMAPSv01b_core.lld.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file, Geneva feature set < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014, 2020 by audEERING ////////////////// 5 | ///////// All rights reserved. See file COPYING for details. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | ;;;;;;;;;;;;;;;;;;;;;; 9 | 10 | [componentInstances:cComponentManager] 11 | instance[gemapsv01b_frame60].type=cFramer 12 | instance[gemapsv01b_win60].type=cWindower 13 | instance[gemapsv01b_fft60].type=cTransformFFT 14 | instance[gemapsv01b_fftmp60].type=cFFTmagphase 15 | 16 | [gemapsv01b_frame60:cFramer] 17 | reader.dmLevel=wave 18 | writer.dmLevel=gemapsv01b_frame60 19 | \{\cm[bufferModeRbConf{../../shared/BufferModeRb.conf.inc}:path to included config to set the buffer mode for the standard ringbuffer levels]} 20 | frameSize = 0.060 21 | frameStep = 0.010 22 | frameCenterSpecial = left 23 | 24 | [gemapsv01b_win60:cWindower] 25 | reader.dmLevel=gemapsv01b_frame60 26 | writer.dmLevel=gemapsv01b_winG60 27 | winFunc=gauss 28 | gain=1.0 29 | sigma=0.4 30 | 31 | [gemapsv01b_fft60:cTransformFFT] 32 | reader.dmLevel=gemapsv01b_winG60 33 | writer.dmLevel=gemapsv01b_fftcG60 34 | 35 | [gemapsv01b_fftmp60:cFFTmagphase] 36 | reader.dmLevel=gemapsv01b_fftcG60 37 | writer.dmLevel=gemapsv01b_fftmagG60 38 | \{\cm[bufferModeRbLagConf{../../shared/BufferModeRbLag.conf.inc}:path to included config to set the buffer mode for levels which will be joint with Viterbi smoothed -lagged- F0]} 39 | 40 | 41 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 42 | 43 | [componentInstances:cComponentManager] 44 | instance[gemapsv01b_frame25].type=cFramer 45 | instance[gemapsv01b_win25].type=cWindower 46 | instance[gemapsv01b_fft25].type=cTransformFFT 47 | instance[gemapsv01b_fftmp25].type=cFFTmagphase 48 | 49 | [gemapsv01b_frame25:cFramer] 50 | reader.dmLevel=wave 51 | writer.dmLevel=gemapsv01b_frame25 52 | \{\cm[bufferModeRbConf]} 53 | frameSize = 0.020 54 | frameStep = 0.010 55 | frameCenterSpecial = left 56 | 57 | [gemapsv01b_win25:cWindower] 58 | reader.dmLevel=gemapsv01b_frame25 59 | writer.dmLevel=gemapsv01b_winH25 60 | winFunc=hamming 61 | 62 | [gemapsv01b_fft25:cTransformFFT] 63 | reader.dmLevel=gemapsv01b_winH25 64 | writer.dmLevel=gemapsv01b_fftcH25 65 | 66 | [gemapsv01b_fftmp25:cFFTmagphase] 67 | reader.dmLevel=gemapsv01b_fftcH25 68 | writer.dmLevel=gemapsv01b_fftmagH25 69 | ;;; CHECK!!!!!!! 70 | ;writer.levelconf.growDyn = 1 71 | ;writer.levelconf.isRb = 0 72 | 73 | 74 | ;;;;;;;;;;;;;;;;;;;; HPS pitch 75 | 76 | [componentInstances:cComponentManager] 77 | instance[gemapsv01b_scale].type=cSpecScale 78 | instance[gemapsv01b_shs].type=cPitchShs 79 | 80 | [gemapsv01b_scale:cSpecScale] 81 | reader.dmLevel=gemapsv01b_fftmagG60 82 | writer.dmLevel=gemapsv01b_hpsG60 83 | \{\cm[bufferModeRbConf]} 84 | copyInputName = 1 85 | processArrayFields = 0 86 | scale=octave 87 | sourceScale = lin 88 | interpMethod = spline 89 | minF = 25 90 | maxF = -1 91 | nPointsTarget = 0 92 | specSmooth = 1 93 | specEnhance = 1 94 | auditoryWeighting = 1 95 | 96 | [gemapsv01b_shs:cPitchShs] 97 | reader.dmLevel=gemapsv01b_hpsG60 98 | writer.dmLevel=gemapsv01b_pitchShsG60 99 | \{\cm[bufferModeRbLagConf]} 100 | copyInputName = 1 101 | processArrayFields = 0 102 | maxPitch = 1000 103 | minPitch = 55 104 | nCandidates = 6 105 | scores = 1 106 | voicing = 1 107 | F0C1 = 0 108 | voicingC1 = 0 109 | F0raw = 1 110 | voicingClip = 1 111 | voicingCutoff = 0.700000 112 | inputFieldSearch = Mag_octScale 113 | octaveCorrection = 0 114 | nHarmonics = 15 115 | compressionFactor = 0.850000 116 | greedyPeakAlgo = 1 117 | 118 | ;;;;; Pitch with Viterbi smoother 119 | [componentInstances:cComponentManager] 120 | instance[gemapsv01b_energy60].type=cEnergy 121 | 122 | [gemapsv01b_energy60:cEnergy] 123 | reader.dmLevel=gemapsv01b_winG60 124 | writer.dmLevel=gemapsv01b_e60 125 | ; This must be > than buffersize of viterbi smoother 126 | ; writer.levelconf.nT=100 127 | \{\cm[bufferModeRbLagConf]} 128 | rms=1 129 | log=0 130 | 131 | [componentInstances:cComponentManager] 132 | instance[gemapsv01b_pitchSmoothViterbi].type=cPitchSmootherViterbi 133 | 134 | [gemapsv01b_pitchSmoothViterbi:cPitchSmootherViterbi] 135 | reader.dmLevel=gemapsv01b_pitchShsG60 136 | reader2.dmLevel=gemapsv01b_pitchShsG60 137 | writer.dmLevel=gemapsv01b_logPitchRaw 138 | copyInputName = 1 139 | bufferLength=40 140 | F0final = 1 141 | F0finalLog = 1 142 | F0finalEnv = 0 143 | voicingFinalClipped = 0 144 | voicingFinalUnclipped = 1 145 | F0raw = 0 146 | voicingC1 = 0 147 | voicingClip = 0 148 | wTvv =10.0 149 | wTvvd= 5.0 150 | wTvuv=10.0 151 | wThr = 4.0 152 | wTuu = 0.0 153 | wLocal=2.0 154 | wRange=1.0 155 | 156 | [componentInstances:cComponentManager] 157 | instance[gemapsv01b_volmerge].type = cValbasedSelector 158 | 159 | [gemapsv01b_volmerge:cValbasedSelector] 160 | reader.dmLevel = gemapsv01b_e60;gemapsv01b_logPitchRaw 161 | writer.dmLevel = gemapsv01b_logPitch 162 | \{\cm[bufferModeRbLagConf]} 163 | idx=0 164 | threshold=0.001 165 | removeIdx=1 166 | zeroVec=1 167 | outputVal=0.0 168 | 169 | ;;;;;;;;;;;;;;;;;;; Voice Quality (VQ) 170 | 171 | [componentInstances:cComponentManager] 172 | instance[gemapsv01b_pitchJitter].type=cPitchJitter 173 | 174 | [gemapsv01b_pitchJitter:cPitchJitter] 175 | reader.dmLevel = wave 176 | writer.dmLevel = gemapsv01b_jitterShimmer 177 | \{\cm[bufferModeRbLagConf]} 178 | copyInputName = 1 179 | F0reader.dmLevel = gemapsv01b_logPitch 180 | F0field = F0final 181 | searchRangeRel = 0.100000 182 | jitterLocal = 1 183 | jitterDDP = 0 184 | jitterLocalEnv = 0 185 | jitterDDPEnv = 0 186 | shimmerLocal = 0 187 | shimmerLocalDB = 1 188 | shimmerLocalEnv = 0 189 | onlyVoiced = 0 190 | logHNR = 0 191 | ; This must be larger than the viterbi pitch smoother lag 192 | inputMaxDelaySec = 2.5 193 | minNumPeriods = 2 194 | minCC = 0.5 195 | useBrokenJitterThresh = 0 196 | 197 | ;;;;;;;;;;;;;;;;;;;;; Energy / loudness 198 | 199 | 200 | [componentInstances:cComponentManager] 201 | instance[gemapsv01b_melspec1].type=cMelspec 202 | instance[gemapsv01b_audspec].type=cPlp 203 | instance[gemapsv01b_audspecSum].type=cVectorOperation 204 | 205 | [gemapsv01b_melspec1:cMelspec] 206 | reader.dmLevel=gemapsv01b_fftmagH25 207 | writer.dmLevel=gemapsv01b_melspec1 208 | ; htk compatible sample value scaling 209 | htkcompatible = 0 210 | nBands = 26 211 | ; use power spectrum instead of magnitude spectrum 212 | usePower = 1 213 | lofreq = 20 214 | hifreq = 8000 215 | specScale = mel 216 | showFbank = 0 217 | 218 | ; perform auditory weighting of spectrum 219 | [gemapsv01b_audspec:cPlp] 220 | reader.dmLevel=gemapsv01b_melspec1 221 | writer.dmLevel=gemapsv01b_audspec 222 | firstCC = 0 223 | lpOrder = 5 224 | cepLifter = 22 225 | compression = 0.33 226 | htkcompatible = 0 227 | doIDFT = 0 228 | doLpToCeps = 0 229 | doLP = 0 230 | doInvLog = 0 231 | doAud = 1 232 | doLog = 0 233 | newRASTA=0 234 | RASTA=0 235 | 236 | [gemapsv01b_audspecSum:cVectorOperation] 237 | reader.dmLevel = gemapsv01b_audspec 238 | writer.dmLevel = gemapsv01b_loudness 239 | ; This must be larger than the F0 viterbi buffer length 240 | ; since audspecSum and F0 envelope are joint later! 241 | \{\cm[bufferModeRbLagConf]} 242 | nameAppend = loudness 243 | copyInputName = 0 244 | processArrayFields = 0 245 | operation = ll1 246 | nameBase = loudness 247 | 248 | ;;;;;;;;;;;;;; Formants ;;;;;;;;;;;;;;;;;;;;;; 249 | [componentInstances:cComponentManager] 250 | instance[gemapsv01b_resampLpc].type=cSpecResample 251 | instance[gemapsv01b_lpc].type=cLpc 252 | instance[gemapsv01b_formantLpc].type=cFormantLpc 253 | 254 | [gemapsv01b_resampLpc:cSpecResample] 255 | // use fftcG60 ? H25 has faster resampling 256 | reader.dmLevel=gemapsv01b_fftcH25 257 | writer.dmLevel=gemapsv01b_outpR 258 | targetFs = 11000 259 | 260 | [gemapsv01b_lpc:cLpc] 261 | reader.dmLevel=gemapsv01b_outpR 262 | writer.dmLevel=gemapsv01b_lpc 263 | p=11 264 | method=acf 265 | lpGain=0 266 | saveLPCoeff=1 267 | residual=0 268 | forwardFilter=0 269 | lpSpectrum=0 270 | 271 | [gemapsv01b_formantLpc:cFormantLpc] 272 | reader.dmLevel=gemapsv01b_lpc 273 | writer.dmLevel=gemapsv01b_formants 274 | \{\cm[bufferModeRbLagConf]} 275 | saveIntensity=0 276 | saveBandwidths=1 277 | maxF=5450.0 278 | minF=50.0 279 | nFormants=5 280 | useLpSpec=0 281 | medianFilter=0 282 | octaveCorrection=0 283 | 284 | ;;;;;;;;;;;;; Harmonics ;;;;;;;;;;;;;;;;;;;; 285 | [componentInstances:cComponentManager] 286 | instance[gemapsv01b_harmonics].type = cHarmonics 287 | 288 | ;;;; default (template) configuration section for component 'cHarmonics' ;;;; 289 | [gemapsv01b_harmonics:cHarmonics] 290 | reader.dmLevel = gemapsv01b_logPitch;gemapsv01b_formants;gemapsv01b_fftmagG60 291 | writer.dmLevel = gemapsv01b_harmonics 292 | \{\cm[bufferModeRbLagConf]} 293 | copyInputName = 0 294 | processArrayFields = 0 295 | includeSingleElementFields = 1 296 | preserveFieldNames = 0 297 | formantFrequencyFieldName = formantFreqLpc 298 | formantFrequencyFieldNameIsFull = 1 299 | formantBandwidthFieldName = formantBandwidthLpc 300 | formantBandwidthFieldNameIsFull = 1 301 | f0ElementName = F0final 302 | f0ElementNameIsFull = 1 303 | magSpecFieldName = pcm_fftMag 304 | magSpecFieldNameIsFull = 1 305 | nHarmonics = 100 306 | harmonicDifferences = H1-H2;H1-A3 307 | harmonicDifferencesLog = 1 308 | nHarmonicMagnitudes = 0 309 | firstHarmonicMagnitude = 1 310 | outputLogRelMagnitudes = 1 311 | formantAmplitudes=1 312 | formantAmplitudesLogRel = 1 313 | formantAmplitudesStart = 1 314 | formantAmplitudesEnd = 3 315 | computeAcfHnrLogdB = 1 316 | 317 | ;;;;;;;;;;;;;;; spectral 318 | [componentInstances:cComponentManager] 319 | instance[gemapsv01b_logSpectral].type=cSpectral 320 | 321 | [gemapsv01b_logSpectral:cSpectral] 322 | reader.dmLevel=gemapsv01b_fftmagH25 323 | writer.dmLevel=gemapsv01b_logSpectral 324 | \{\cm[bufferModeRbLagConf]} 325 | flux = 0 326 | centroid = 0 327 | maxPos=0 328 | minPos=0 329 | entropy = 0 330 | flatness = 0 331 | harmonicity = 0 332 | sharpness = 0 333 | variance=0 334 | skewness=0 335 | kurtosis=0 336 | alphaRatio = 1 337 | hammarbergIndex = 1 338 | slope = 0 339 | slopes[0] = 0-500 340 | slopes[1] = 500-1500 341 | ; NOTE: added this to sync with eGeMAPS set, should have no effect. 342 | normBandEnergies = 1 343 | squareInput = 1 344 | useLogSpectrum = 1 345 | freqRange = 0-5000 346 | oldSlopeScale = 0 347 | 348 | ;;;;;;;;;;;; collecting, filtering, and renaming ;;;;;;;;;;;;;;;;, 349 | 350 | /* 351 | logSpectral Hammarberg, AlphaRatio, spectralSlope 0-500, 500-1500 352 | harmonics H1-H2, H1-A3, HNRlog 353 | logPitch F0finalLog 354 | jitterShimmer jitterLocal, shimmerLocal 355 | loudness 356 | formants F1-3 freq, F1 bandw (check!) 357 | harmonics F1-3 level relative 358 | */ 359 | 360 | [componentInstances:cComponentManager] 361 | instance[gemapsv01b_lldSetSelectorE].type=cDataSelector 362 | instance[gemapsv01b_lldSetSelectorF].type=cDataSelector 363 | instance[gemapsv01b_lldSetSelectorLogF0].type=cDataSelector 364 | instance[gemapsv01b_formantVoiced].type = cValbasedSelector 365 | instance[gemapsv01b_lldSetSelectorNoF0LoudnNz].type = cDataSelector 366 | instance[gemapsv01b_logSpectralVoiced].type = cValbasedSelector 367 | instance[gemapsv01b_logSpectralUnvoiced].type = cValbasedSelector 368 | instance[gemapsv01b_lldSetSelectorSpectralNz].type=cDataSelector 369 | instance[gemapsv01b_lldSetSelectorSpectralZ].type=cDataSelector 370 | 371 | [gemapsv01b_lldSetSelectorE:cDataSelector] 372 | reader.dmLevel = gemapsv01b_loudness;gemapsv01b_logSpectral 373 | writer.dmLevel = gemapsv01b_lldsetE 374 | \{\cm[bufferModeRbConf]} 375 | selected = loudness;pcm_fftMag_alphaRatioDB;pcm_fftMag_hammarbergIndexDB;pcm_fftMag_logSpectralSlopeOfBand0-500;pcm_fftMag_logSpectralSlopeOfBand500-1500 376 | newNames = Loudness;alphaRatio;hammarbergIndex;slope0-500;slope500-1500 377 | 378 | [gemapsv01b_lldSetSelectorF:cDataSelector] 379 | reader.dmLevel = gemapsv01b_logPitch;gemapsv01b_jitterShimmer;gemapsv01b_harmonics;gemapsv01b_formants 380 | writer.dmLevel = gemapsv01b_lldsetF 381 | \{\cm[bufferModeRbConf]} 382 | selected = F0finalLog;jitterLocal;shimmerLocalDB;HarmonicsToNoiseRatioACFLogdB;HarmonicDifferenceLogRelH1-H2;HarmonicDifferenceLogRelH1-A3;formantFreqLpc[1];formantBandwidthLpc[1];FormantAmplitudeByMaxHarmonicLogRelF0[1];formantFreqLpc[2];FormantAmplitudeByMaxHarmonicLogRelF0[2];formantFreqLpc[3];FormantAmplitudeByMaxHarmonicLogRelF0[3] 383 | newNames = F0semitoneFrom27.5Hz;jitterLocal;shimmerLocaldB;HNRdBACF;logRelF0-H1-H2;logRelF0-H1-A3;F1frequency;F1bandwidth;F1amplitudeLogRelF0;F2frequency;F2amplitudeLogRelF0;F3frequency;F3amplitudeLogRelF0 384 | 385 | [gemapsv01b_lldSetSelectorLogF0:cDataSelector] 386 | reader.dmLevel = gemapsv01b_logPitch 387 | writer.dmLevel = gemapsv01b_lld_single_logF0 388 | \{\cm[bufferModeRbLagConf]} 389 | selected = F0finalLog 390 | newNames = F0semitoneFrom27.5Hz 391 | 392 | // select only formants where F0 > 0 for functionals 393 | // (in LLD csv we output all of them..!) 394 | [gemapsv01b_formantVoiced:cValbasedSelector] 395 | reader.dmLevel = gemapsv01b_lld_single_logF0;gemapsv01b_formants 396 | writer.dmLevel = gemapsv01b_formantsNz 397 | \{\cm[bufferModeRbLagConf]} 398 | idx=0 399 | threshold=0.000001 400 | removeIdx=1 401 | zeroVec=1 402 | outputVal=0.0 403 | 404 | [gemapsv01b_lldSetSelectorNoF0LoudnNz:cDataSelector] 405 | reader.dmLevel = gemapsv01b_jitterShimmer;gemapsv01b_harmonics;gemapsv01b_formantsNz 406 | writer.dmLevel = gemapsv01b_lldSetNoF0AndLoudnessNz 407 | \{\cm[bufferModeRbConf]} 408 | selected = jitterLocal;shimmerLocalDB;HarmonicsToNoiseRatioACFLogdB;HarmonicDifferenceLogRelH1-H2;HarmonicDifferenceLogRelH1-A3;formantFreqLpc[1];formantBandwidthLpc[1];FormantAmplitudeByMaxHarmonicLogRelF0[1];formantFreqLpc[2];FormantAmplitudeByMaxHarmonicLogRelF0[2];formantFreqLpc[3];FormantAmplitudeByMaxHarmonicLogRelF0[3] 409 | newNames = jitterLocal;shimmerLocaldB;HNRdBACF;logRelF0-H1-H2;logRelF0-H1-A3;F1frequency;F1bandwidth;F1amplitudeLogRelF0;F2frequency;F2amplitudeLogRelF0;F3frequency;F3amplitudeLogRelF0 410 | 411 | // select logspectral for voiced sounds 412 | [gemapsv01b_logSpectralVoiced:cValbasedSelector] 413 | reader.dmLevel = gemapsv01b_lld_single_logF0;gemapsv01b_logSpectral 414 | writer.dmLevel = gemapsv01b_logSpectralVoiced 415 | \{\cm[bufferModeRbLagConf]} 416 | idx=0 417 | threshold=0.000001 418 | removeIdx=1 419 | zeroVec=1 420 | outputVal=0.0 421 | 422 | // select logspectral for voiced sounds 423 | [gemapsv01b_logSpectralUnvoiced:cValbasedSelector] 424 | reader.dmLevel = gemapsv01b_lld_single_logF0;gemapsv01b_logSpectral 425 | writer.dmLevel = gemapsv01b_logSpectralUnvoiced 426 | \{\cm[bufferModeRbLagConf]} 427 | idx=0 428 | invert = 1 429 | threshold = 0.000001 430 | removeIdx=1 431 | zeroVec=1 432 | outputVal=0.0 433 | 434 | [gemapsv01b_lldSetSelectorSpectralNz:cDataSelector] 435 | reader.dmLevel = gemapsv01b_logSpectralVoiced 436 | writer.dmLevel = gemapsv01b_lldSetSpectralNz 437 | \{\cm[bufferModeRbConf]} 438 | selected = pcm_fftMag_alphaRatioDB;pcm_fftMag_hammarbergIndexDB;pcm_fftMag_logSpectralSlopeOfBand0-500;pcm_fftMag_logSpectralSlopeOfBand500-1500 439 | newNames = alphaRatioV;hammarbergIndexV;slopeV0-500;slopeV500-1500 440 | 441 | [gemapsv01b_lldSetSelectorSpectralZ:cDataSelector] 442 | reader.dmLevel = gemapsv01b_logSpectralUnvoiced 443 | writer.dmLevel = gemapsv01b_lldSetSpectralZ 444 | \{\cm[bufferModeRbConf]} 445 | selected = pcm_fftMag_alphaRatioDB;pcm_fftMag_hammarbergIndexDB;pcm_fftMag_logSpectralSlopeOfBand0-500;pcm_fftMag_logSpectralSlopeOfBand500-1500 446 | newNames = alphaRatioUV;hammarbergIndexUV;slopeUV0-500;slopeUV500-1500 447 | 448 | 449 | ;;;;;;;;;;;;;;;; smoothing ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 450 | [componentInstances:cComponentManager] 451 | instance[gemapsv01b_smoFnz].type=cContourSmoother 452 | instance[gemapsv01b_smoE].type=cContourSmoother 453 | instance[gemapsv01b_smoNoF0andLoudnNz].type=cContourSmoother 454 | instance[gemapsv01b_smoSpectralZ].type=cContourSmoother 455 | instance[gemapsv01b_smoSpectralNz].type=cContourSmoother 456 | 457 | [gemapsv01b_smoFnz:cContourSmoother] 458 | reader.dmLevel = gemapsv01b_lldsetF 459 | writer.dmLevel = gemapsv01b_lldsetF_smo 460 | nameAppend = sma3nz 461 | copyInputName = 1 462 | noPostEOIprocessing = 0 463 | smaWin = 3 464 | noZeroSma = 1 465 | 466 | [gemapsv01b_smoE:cContourSmoother] 467 | reader.dmLevel = gemapsv01b_lldsetE 468 | writer.dmLevel = gemapsv01b_lldsetE_smo 469 | nameAppend = sma3 470 | copyInputName = 1 471 | noPostEOIprocessing = 0 472 | smaWin = 3 473 | noZeroSma = 0 474 | 475 | [gemapsv01b_smoNoF0andLoudnNz:cContourSmoother] 476 | reader.dmLevel = gemapsv01b_lldSetNoF0AndLoudnessNz 477 | writer.dmLevel = gemapsv01b_lldSetNoF0AndLoudnessNz_smo 478 | \{\cm[bufferModeConf{../../shared/BufferMode.conf.inc}:path to included config to set the buffer mode for the levels before the functionals]} 479 | nameAppend = sma3nz 480 | copyInputName = 1 481 | noPostEOIprocessing = 0 482 | smaWin = 3 483 | noZeroSma = 1 484 | 485 | [gemapsv01b_smoSpectralZ:cContourSmoother] 486 | reader.dmLevel = gemapsv01b_lldSetSpectralZ 487 | writer.dmLevel = gemapsv01b_lldSetSpectralZ_smo 488 | \{\cm[bufferModeConf]} 489 | nameAppend = sma3nz 490 | copyInputName = 1 491 | noPostEOIprocessing = 0 492 | smaWin = 3 493 | ; non-zero SMA is ok here, as it is inverted with 0's for the voiced parts 494 | noZeroSma = 1 495 | 496 | [gemapsv01b_smoSpectralNz:cContourSmoother] 497 | reader.dmLevel = gemapsv01b_lldSetSpectralNz 498 | writer.dmLevel = gemapsv01b_lldSetSpectralNz_smo 499 | \{\cm[bufferModeConf]} 500 | nameAppend = sma3nz 501 | copyInputName = 1 502 | noPostEOIprocessing = 0 503 | smaWin = 3 504 | noZeroSma = 1 505 | 506 | 507 | 508 | 509 | 510 | 511 | -------------------------------------------------------------------------------- /opensmile/core/config/shared/BufferMode.conf.inc: -------------------------------------------------------------------------------- 1 | writer.levelconf.growDyn = 1 2 | writer.levelconf.isRb = 0 3 | writer.levelconf.nT = 1000 4 | -------------------------------------------------------------------------------- /opensmile/core/config/shared/BufferModeRb.conf.inc: -------------------------------------------------------------------------------- 1 | writer.levelconf.growDyn = 0 2 | writer.levelconf.isRb = 1 3 | writer.levelconf.nT = 5 4 | ; writer.levelconf.nT = 3 5 | 6 | -------------------------------------------------------------------------------- /opensmile/core/config/shared/BufferModeRbLag.conf.inc: -------------------------------------------------------------------------------- 1 | writer.levelconf.growDyn = 0 2 | writer.levelconf.isRb = 1 3 | ; This must be > than buffersize of viterbi smoother 4 | writer.levelconf.nT = 150 5 | 6 | 7 | -------------------------------------------------------------------------------- /opensmile/core/config/shared/BufferModeRbMulti.conf.inc: -------------------------------------------------------------------------------- 1 | writer.levelconf.growDyn = 0 2 | writer.levelconf.isRb = 1 3 | ;; must be > turndetector maxlength + grace 4 | writer.levelconf.nT = 1500 5 | writer.levelconf.noHang = 2 6 | -------------------------------------------------------------------------------- /opensmile/core/config/shared/FrameModeFunctionals.conf.inc: -------------------------------------------------------------------------------- 1 | 2 | ;; set this to override the previously included BufferModeRb.conf.inc (in GeMAPS sets only) for the functionals 3 | ;; or (in all other sets), define the RbConf here to save memory on the functionals levels: 4 | ;writer.levelconf.growDyn = 0 5 | ;writer.levelconf.isRb = 1 6 | ;writer.levelconf.nT = 5 7 | 8 | frameMode = full 9 | frameSize = 0 10 | frameStep = 0 11 | frameCenterSpecial = left 12 | 13 | -------------------------------------------------------------------------------- /opensmile/core/config/shared/FrameModeFunctionalsMulti.conf.inc: -------------------------------------------------------------------------------- 1 | 2 | ;; set this to override the previously included BufferModeRb.conf.inc (in GeMAPS sets only) for the functionals 3 | ;; or (in all other sets), define the RbConf here to save memory on the functionals levels: 4 | ;writer.levelconf.growDyn = 0 5 | ;writer.levelconf.isRb = 1 6 | ;writer.levelconf.nT = 5 7 | 8 | frameMode = list 9 | frameList = \cm[frameList(F){0.0s-0.0s}:list with frame end and stop times separated by comma, e.g. 1.0s-1.5s,2.0s-2.5s] 10 | frameSize = 0 11 | frameStep = 0 12 | frameCenterSpecial = left 13 | -------------------------------------------------------------------------------- /opensmile/core/config/shared/standard_data_output.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file for data output < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014-2016 audEERING, ////////////////// 5 | ///////// All rights reserved. See file COPYING for details ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | 9 | /* 10 | This file can be included as data output file for standard feature 11 | extraction configuration files. It provides commandline options 12 | for the batch extraction GUI, and supports LLD and Functionals (summaries) 13 | saving. 14 | 15 | It requires the main extractor configuration file to provide the following 16 | data memory levels: lld, lld_de, and func 17 | */ 18 | 19 | ;;;;;;;;; output LLD features to CSV ;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 20 | 21 | [componentInstances:cComponentManager] 22 | instance[lld_csv_sink].type=cCsvSink 23 | instance[lld_de_csv_sink].type=cCsvSink 24 | instance[func_csv_sink].type=cCsvSink 25 | 26 | [lld_csv_sink:cCsvSink] 27 | reader.dmLevel = lld 28 | filename=\cm[lld_csv_output{?}:output csv file for LLD, disabled by default ?, only written if filename given] 29 | append = \cm[lld_csv_append{0}:set to 1 to append to the LLD output csv file, default is not to append] 30 | timestamp = \cm[lld_csv_timestamp{1}:set to 0 to suppress timestamp column, default is 1, i.e. to show timestamp in second column] 31 | number = 0 32 | printHeader = \cm[lld_csv_header{1}:set to 0 to suppress header line with feature names, default is 1, i.e. to show header line] 33 | errorOnNoOutput = 1 34 | 35 | [lld_de_csv_sink:cCsvSink] 36 | reader.dmLevel = lld_de 37 | filename=\cm[lld_de_csv_output{?}:output csv file for LLD, disabled by default ?, only written if filename given] 38 | append = \cm[lld_de_csv_append{0}:set to 1 to append to the LLD output csv file, default is not to append] 39 | timestamp = \cm[lld_de_csv_timestamp{1}:set to 0 to suppress timestamp column, default is 1, i.e. to show timestamp in second column] 40 | number = 0 41 | printHeader = \cm[lld_de_csv_header{1}:set to 0 to suppress header line with feature names, default is 1, i.e. to show header line] 42 | errorOnNoOutput = 1 43 | 44 | [func_csv_sink:cCsvSink] 45 | reader.dmLevel = func 46 | filename=\cm[func_csv_output{?}:output CSV file for summarised parameters, set to a valid filename to enable this output sink, data is appended if file exists] 47 | append=\cm[func_csv_append{0}:set to 0 to disable appending to an existing csv parameter summary file, given by the csvoutput option] 48 | frameIndex=0 49 | frameTime=\cm[func_csv_timestamp{1}:set to 0 to suppress timestamp column, default is 1, i.e. to show timestamp in second column] 50 | errorOnNoOutput = 1 51 | printHeader = \cm[func_csv_header{1}:set to 0 to suppress header line with feature names, default is 1, i.e. to show header line] 52 | 53 | -------------------------------------------------------------------------------- /opensmile/core/config/shared/standard_data_output_no_lld_de.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file for data output < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) 2014-2016 audEERING, ////////////////// 5 | ///////// All rights reserved. See file COPYING for details ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | 9 | /* 10 | This file can be included as data output file for standard feature 11 | extraction configuration files. It provides commandline options 12 | for the batch extraction GUI, and supports LLD and Functionals (summaries) 13 | saving. 14 | 15 | It requires the main extractor configuration file to provide the following 16 | data memory levels: lld and func 17 | */ 18 | 19 | ;;;;;;;;; output LLD features to CSV ;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 20 | 21 | [componentInstances:cComponentManager] 22 | instance[lld_csv_sink].type=cCsvSink 23 | instance[func_csv_sink].type=cCsvSink 24 | 25 | [lld_csv_sink:cCsvSink] 26 | reader.dmLevel = lld 27 | filename=\cm[lld_csv_output{?}:output csv file for LLD, disabled by default ?, only written if filename given] 28 | append = \cm[lld_csv_append{0}:set to 1 to append to the LLD output csv file, default is not to append] 29 | timestamp = \cm[lld_csv_timestamp{1}:set to 0 to suppress timestamp column, default is 1, i.e. to show timestamp in second column] 30 | number = 0 31 | printHeader = \cm[lld_csv_header{1}:set to 0 to suppress header line with feature names, default is 1, i.e. to show header line] 32 | errorOnNoOutput = 1 33 | 34 | [func_csv_sink:cCsvSink] 35 | reader.dmLevel = func 36 | filename=\cm[func_csv_output{?}:output CSV file for summarised parameters, set to a valid filename to enable this output sink, data is appended if file exists] 37 | append=\cm[func_csv_append{0}:set to 0 to disable appending to an existing csv parameter summary file, given by the csvoutput option] 38 | frameIndex=0 39 | frameTime=\cm[func_csv_timestamp{1}:set to 0 to suppress timestamp column, default is 1, i.e. to show timestamp in second column] 40 | errorOnNoOutput = 1 41 | printHeader = \cm[func_csv_header{1}:set to 0 to suppress header line with feature names, default is 1, i.e. to show header line] 42 | 43 | -------------------------------------------------------------------------------- /opensmile/core/config/shared/standard_external_data_output_multi.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file for wave input < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) audEERING GmbH, ////////////////// 5 | ///////// All rights reserved. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | [componentInstances:cComponentManager] 9 | instance[extsinklld].type=cExternalSink 10 | instance[extsinkfunc].type=cExternalSink 11 | 12 | ;;;;;;; sink ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 13 | 14 | [extsinklld:cExternalSink] 15 | reader.dmLevel = \cm[sinkLevelLLD{lld}:sink level] 16 | blocksize = \cm[blockSize{1}:block size] 17 | 18 | [extsinkfunc:cExternalSink] 19 | reader.dmLevel = \cm[sinkLevelFunc{func}:sink level] 20 | blocksize = \cm[blockSize{1}:block size] 21 | -------------------------------------------------------------------------------- /opensmile/core/config/shared/standard_external_data_output_single.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file for wave input < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) audEERING GmbH, ////////////////// 5 | ///////// All rights reserved. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | [componentInstances:cComponentManager] 9 | instance[extsink].type=cExternalSink 10 | 11 | ;;;;;;; sink ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; 12 | 13 | [extsink:cExternalSink] 14 | reader.dmLevel = \cm[sinkLevel{func}:sink level] 15 | blocksize = \cm[blockSize{1}:block size] 16 | -------------------------------------------------------------------------------- /opensmile/core/config/shared/standard_external_wave_input.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file for wave input < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) audEERING GmbH, ////////////////// 5 | ///////// All rights reserved. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | [componentInstances:cComponentManager] 9 | instance[extsource].type=cExternalAudioSource 10 | 11 | [extsource:cExternalAudioSource] 12 | writer.dmLevel=wave 13 | writer.levelconf.growDyn=1 14 | writer.levelconf.isRb=0 15 | sampleRate=\cm[sampleRate{16000}:sample rate] 16 | nBits=\cm[nBits{16}:sample bits] 17 | channels=\cm[channels{1}:channel size] 18 | -------------------------------------------------------------------------------- /opensmile/core/config/shared/standard_wave_input.conf.inc: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file for wave input < ////////////////// 3 | ///////// ////////////////// 4 | ///////// (c) audEERING GmbH, ////////////////// 5 | ///////// All rights reserved. ////////////////// 6 | /////////////////////////////////////////////////////////////////////////////////////// 7 | 8 | [componentInstances:cComponentManager] 9 | instance[waveIn].type=cWaveSource 10 | 11 | [waveIn:cWaveSource] 12 | writer.dmLevel=wave 13 | buffersize_sec = 5.0 14 | filename=\cm[filename(I){?}:name of input file] 15 | start=\cm[start{0}:audio start position in seconds] 16 | end=\cm[end{-1}:audio end position in seconds, -1 for end of file] 17 | monoMixdown=1 18 | outFieldName = pcm 19 | 20 | -------------------------------------------------------------------------------- /opensmile/core/define.py: -------------------------------------------------------------------------------- 1 | from __future__ import annotations 2 | 3 | import enum 4 | 5 | import audobject 6 | 7 | 8 | class FeatureSet(enum.Enum): 9 | r"""Enumeration of standard feature sets. 10 | 11 | The following feature sets are available: 12 | 13 | * :attr:`ComParE_2016` 14 | * :attr:`GeMAPS`, deprecated alias for :attr:`GeMAPSv01a` 15 | * :attr:`GeMAPSv01a` 16 | * :attr:`GeMAPSv01b` 17 | * :attr:`eGeMAPS`, deprecated alias for :attr:`eGeMAPSv01a` 18 | * :attr:`eGeMAPSv01a` 19 | * :attr:`eGeMAPSv01b` 20 | * :attr:`eGeMAPSv02` 21 | * :attr:`emobase` 22 | 23 | For references, see the papers on: 24 | 25 | * `ComParE 2016`_ 26 | * GeMAPS_ 27 | * eGeMAPS_ 28 | * emobase 29 | 30 | .. _ComParE 2016: 31 | http://www.tangsoo.de/documents/Publications/Schuller16-TI2.pdf 32 | .. _GeMAPS: 33 | https://sail.usc.edu/publications/files/eyben-preprinttaffc-2015.pdf 34 | .. _eGeMAPS: 35 | https://sail.usc.edu/publications/files/eyben-preprinttaffc-2015.pdf 36 | 37 | """ 38 | 39 | ComParE_2016 = "compare/ComParE_2016" 40 | GeMAPS = "gemaps/v01a/GeMAPSv01a" # legacy 41 | GeMAPSv01a = "gemaps/v01a/GeMAPSv01a" 42 | GeMAPSv01b = "gemaps/v01b/GeMAPSv01b" 43 | eGeMAPS = "egemaps/v01a/eGeMAPSv01a" # legacy 44 | eGeMAPSv01a = "egemaps/v01a/eGeMAPSv01a" 45 | eGeMAPSv01b = "egemaps/v01b/eGeMAPSv01b" 46 | eGeMAPSv02 = "egemaps/v02/eGeMAPSv02" 47 | emobase = "emobase/emobase" 48 | 49 | 50 | class FeatureSetResolver(audobject.resolver.Base): 51 | r"""Custom value resolver for :class:`opensmile.FeatureSet`.""" 52 | 53 | def decode(self, value: str) -> str | FeatureSet: 54 | if value in FeatureSet.__members__: 55 | value = FeatureSet[value] 56 | return value 57 | 58 | def encode(self, value: str | FeatureSet) -> str: 59 | if isinstance(value, FeatureSet): 60 | value = str(value).split(".")[-1] 61 | return value 62 | 63 | def encode_type(self): 64 | return str 65 | 66 | 67 | class FeatureLevel(enum.Enum): 68 | r"""Enumeration of standard feature levels. 69 | 70 | * :attr:`LowLevelDescriptors` - low-level descriptors (LLD) calculated 71 | over a sliding window 72 | * :attr:`LowLevelDescriptors_Deltas` - Delta regression of LLDs 73 | * :attr:`Functionals` - statistical functionals mapping variable series of 74 | LLDs to static values 75 | 76 | For more information see https://mediatum.ub.tum.de/doc/1082431/1082431.pdf 77 | 78 | """ 79 | 80 | LowLevelDescriptors = "lld" 81 | LowLevelDescriptors_Deltas = "lld_de" 82 | Functionals = "func" 83 | 84 | 85 | class FeatureLevelResolver(audobject.resolver.Base): 86 | r"""Custom value resolver for :class:`opensmile.FeatureLevel`.""" 87 | 88 | def decode(self, value: str) -> str | FeatureLevel: 89 | if value in FeatureLevel.__members__: 90 | value = FeatureLevel[value] 91 | return value 92 | 93 | def encode(self, value: str | FeatureLevel) -> str: 94 | if isinstance(value, FeatureLevel): 95 | value = str(value).split(".")[-1] 96 | return value 97 | 98 | def encode_type(self): 99 | return str 100 | -------------------------------------------------------------------------------- /pyproject.toml: -------------------------------------------------------------------------------- 1 | # ===== PROJECT =========================================================== 2 | # 3 | [project] 4 | name = 'opensmile' 5 | authors = [ 6 | {name = 'Christop Hausner'}, 7 | {name = 'Johannes Wagner', email= 'jwagner@audeering.com'}, 8 | {name = 'Hagen Wierstorf', email = 'hwierstorf@audeering.com'}, 9 | ] 10 | description = 'Python wrapper for common openSMILE feature sets' 11 | readme = 'README.rst' 12 | license = {file = 'LICENSE'} 13 | keywords = [ 14 | 'audio', 15 | 'tools', 16 | 'feature', 17 | 'opensmile', 18 | 'audeering', 19 | ] 20 | classifiers = [ 21 | 'Development Status :: 5 - Production/Stable', 22 | 'Intended Audience :: Science/Research', 23 | 'Intended Audience :: Developers', 24 | 'License :: OSI Approved :: MIT License', 25 | 'Operating System :: OS Independent', 26 | 'Programming Language :: Python', 27 | 'Programming Language :: Python :: 3', 28 | 'Programming Language :: Python :: 3.9', 29 | 'Programming Language :: Python :: 3.10', 30 | 'Programming Language :: Python :: 3.11', 31 | 'Programming Language :: Python :: 3.12', 32 | 'Programming Language :: Python :: 3.13', 33 | 'Topic :: Scientific/Engineering', 34 | ] 35 | requires-python = '>=3.9' 36 | dependencies = [ 37 | 'audobject >=0.6.1', 38 | 'audinterface >=0.7.0', 39 | ] 40 | # Get version dynamically from git 41 | # (needs setuptools_scm tools config below) 42 | dynamic = ['version'] 43 | 44 | [project.urls] 45 | repository = 'https://github.com/audeering/opensmile-python/' 46 | documentation = 'https://audeering.github.io/opensmile-python/' 47 | 48 | 49 | # ===== BUILD-SYSTEM ====================================================== 50 | # 51 | # Requirements for building the Python package 52 | [build-system] 53 | requires = ['setuptools>=45', 'setuptools_scm[toml]>=6.2'] 54 | build-backend = 'setuptools.build_meta' 55 | 56 | 57 | # ===== TOOL ============================================================== 58 | # 59 | 60 | # ----- codespell --------------------------------------------------------- 61 | [tool.codespell] 62 | builtin = 'clear,rare,informal,usage,names' 63 | skip = './opensmile.egg-info,./build,./docs/api,./docs/_templates,./docs/examples' 64 | 65 | 66 | # ----- pytest ------------------------------------------------------------ 67 | # 68 | [tool.pytest.ini_options] 69 | cache_dir = '.cache/pytest' 70 | xfail_strict = true 71 | addopts = ''' 72 | --doctest-plus 73 | --cov=opensmile 74 | --cov-fail-under=100 75 | --cov-report term-missing 76 | --cov-report xml 77 | ''' 78 | 79 | 80 | # ----- ruff -------------------------------------------------------------- 81 | # 82 | [tool.ruff] 83 | cache-dir = '.cache/ruff' 84 | 85 | [tool.ruff.format] 86 | docstring-code-format = true 87 | 88 | [tool.ruff.lint] 89 | select = [ 90 | 'D', # pydocstyle 91 | 'E', # pycodestyle errors 92 | 'F', # Pyflakes 93 | 'I', # isort 94 | 'N', # pep8-naming 95 | 'W', # pycodestyle warnings 96 | ] 97 | 98 | extend-ignore = [ 99 | 'D100', # Missing docstring in public module 100 | 'D103', # Missing docstring in public function 101 | 'D104', # Missing docstring in public package 102 | 'D107', # Missing docstring in `__init__` 103 | ] 104 | 105 | 106 | [tool.ruff.lint.per-file-ignores] 107 | '__init__.py' = [ 108 | 'F401', # * imported but unused 109 | ] 110 | 'define.py' = [ 111 | 'N815', # e.g. Variable `eGeMAPS` in class scope should not be mixedCase 112 | 'D102', # Missing docstring in public method 113 | ] 114 | 'lib.py' = [ 115 | 'D101', # Missing docstring in public class 116 | 'D102', # Missing docstring in public method 117 | 'D105', # Missing docstring in magic method 118 | 'N818', # Exception name `OpenSmileException` should be named with an Error suffix 119 | ] 120 | 121 | 122 | # ----- I: isort ----- 123 | # 124 | # Check correct order/syntax of import statements 125 | # 126 | [tool.ruff.lint.isort] 127 | 128 | # All from imports have their own line, e.g. 129 | # 130 | # from .utils import util_a 131 | # from .utils import util_b 132 | # 133 | force-single-line = true 134 | 135 | # Sort by module names 136 | # and not import before from, e.g. 137 | # 138 | # from datetime import date 139 | # import os 140 | # 141 | force-sort-within-sections = true 142 | 143 | # Ensure we have two empty lines 144 | # after last import 145 | lines-after-imports = 2 146 | 147 | # Group all audEERING packages into a separate section, e.g. 148 | # 149 | # import os 150 | # 151 | # import numpy as np 152 | # 153 | # import audb 154 | # 155 | section-order = [ 156 | 'future', 157 | 'standard-library', 158 | 'third-party', 159 | 'audeering', 160 | 'first-party', 161 | 'local-folder', 162 | ] 163 | [tool.ruff.lint.isort.sections] 164 | 'audeering' = [ 165 | 'audb', 166 | 'audbackend', 167 | 'audeer', 168 | 'audfactory', 169 | 'audformat', 170 | 'audiofile', 171 | 'audinterface', 172 | 'audmath', 173 | 'audmetric', 174 | 'audobject', 175 | 'audonnx', 176 | 'audplot', 177 | 'audresample', 178 | 'audsp', 179 | 'audtorch', 180 | 'sphinx-audeering-theme', 181 | ] 182 | 183 | 184 | # ----- N: pep8-naming ----- 185 | # 186 | # Check variable/class names follow PEP8 naming convention 187 | # 188 | [tool.ruff.lint.pep8-naming] 189 | ignore-names = [ 190 | 'config', # allow lowercase class name 191 | 'test_*', # allow uppercase name when testing a class 192 | ] 193 | 194 | 195 | # ----- W: pycodestyle ----- 196 | # 197 | # Check docstrings follow selected convention 198 | # 199 | [tool.ruff.lint.pydocstyle] 200 | convention = 'google' 201 | 202 | 203 | # ----- setuptools -------------------------------------------------------- 204 | # 205 | # Disable package data to only select the matching binary in setup.py 206 | [tool.setuptools] 207 | include-package-data = false 208 | # Find all (sub-)modules of the Python package 209 | [tool.setuptools.packages.find] 210 | 211 | 212 | # ----- setuptools_scm ---------------------------------------------------- 213 | # 214 | # Use setuptools_scm to get version from git 215 | [tool.setuptools_scm] 216 | -------------------------------------------------------------------------------- /requirements.txt: -------------------------------------------------------------------------------- 1 | -e . 2 | -------------------------------------------------------------------------------- /setup.py: -------------------------------------------------------------------------------- 1 | import os 2 | import platform 3 | 4 | import setuptools 5 | 6 | 7 | # Include only the platform specific pre-compiled binary. 8 | # For sources see https://github.com/audeering/opensmile 9 | 10 | 11 | def platform_name(): 12 | r"""Platform name used in pip tag. 13 | 14 | Expected outcomes are: 15 | 16 | ==================== ====================== 17 | Linux, 64-bit manylinux_2_17_x86_64 18 | Raspberry Pi, 32-bit manylinux_2_17_armv7l 19 | Raspberry Pi, 64-bit manylinux_2_17_aarch64 20 | Windows win_amd64 21 | MacOS Intel macosx_10_4_x86_64 22 | MacOS M1 macosx_11_0_arm64 23 | ==================== ====================== 24 | 25 | Under Linux the manylinux version 26 | can be extracted 27 | by inspecting the wheel 28 | with ``auditwheel``. 29 | 30 | Too see all supported tags on your system run: 31 | 32 | .. code-block:: bash 33 | 34 | $ pip debug --verbose 35 | 36 | """ 37 | system = platform.system() 38 | machine = platform.machine().lower() 39 | 40 | if system == "Linux": # pragma: no cover 41 | system = "manylinux_2_17" 42 | elif system == "Windows": # pragma: no cover 43 | system = "win" 44 | elif system == "Darwin": # pragma: no cover 45 | if machine == "x86_64": 46 | system = "macosx_10_4" 47 | else: 48 | system = "macosx_11_0" 49 | else: # pragma: no cover 50 | raise RuntimeError(f"Unsupported platform {system}") 51 | 52 | return f"{system}_{machine}" 53 | 54 | 55 | # Look for enrionment variable PLAT_NAME 56 | # to be able to enforce 57 | # different platform names 58 | # in CI on the same runner 59 | plat_name = os.environ.get("PLAT_NAME", platform_name()) 60 | 61 | if "linux" in plat_name: 62 | library = "*.so" 63 | elif "macos" in plat_name: 64 | library = "*.dylib" 65 | elif "win" in plat_name: 66 | library = "*.dll" 67 | 68 | setuptools.setup( 69 | package_data={ 70 | "opensmile.core": [ 71 | f"bin/{plat_name}/{library}", 72 | "config/compare/*", 73 | "config/egemaps/v01a/*", 74 | "config/egemaps/v01b/*", 75 | "config/egemaps/v02/*", 76 | "config/emobase/*", 77 | "config/gemaps/v01a/*", 78 | "config/gemaps/v01b/*", 79 | "config/shared/*", 80 | ], 81 | }, 82 | # python -m build --wheel 83 | # does no longer accept the --plat-name option, 84 | # but we can set the desired platform as an option 85 | # (https://stackoverflow.com/a/75010995) 86 | options={ 87 | "bdist_wheel": {"plat_name": plat_name}, 88 | }, 89 | ) 90 | -------------------------------------------------------------------------------- /tests/conftest.py: -------------------------------------------------------------------------------- 1 | import glob 2 | import os 3 | 4 | import pandas as pd 5 | import pytest 6 | 7 | import audeer 8 | import audiofile as af 9 | 10 | from opensmile.core.lib import platform_name 11 | 12 | 13 | pytest.ROOT = os.path.dirname(os.path.realpath(__file__)) 14 | pytest.WAV_FILE = os.path.join(pytest.ROOT, "test.wav") 15 | pytest.WAV_ARRAY, pytest.WAV_SR = af.read(pytest.WAV_FILE, always_2d=True) 16 | pytest.FRAME_LIST_STARTS = pd.to_timedelta(["1.0s", "3.0s", "4.0s"]) 17 | pytest.FRAME_LIST_ENDS = pd.to_timedelta(["1.5s", "3.5s", "5.0s"]) 18 | pytest.CONFIG_FILE = os.path.join(pytest.ROOT, "test.conf") 19 | 20 | plat_name = platform_name() 21 | if "linux" in plat_name: 22 | library = "libSMILEapi.so" 23 | elif "macos" in plat_name: 24 | library = "libSMILEapi.dylib" 25 | elif "win" in plat_name: 26 | library = "SMILEapi.dll" 27 | 28 | pytest.SMILEXTRACT = audeer.path( 29 | pytest.ROOT, 30 | "..", 31 | "opensmile", 32 | "core", 33 | "bin", 34 | plat_name, 35 | "SMILExtract", 36 | ) 37 | 38 | 39 | @pytest.fixture(scope="session", autouse=True) 40 | def fixture_clean_session(): 41 | def clean(): 42 | path = os.path.join(pytest.ROOT, "..", ".coverage.*") 43 | for file in glob.glob(path): 44 | os.remove(file) 45 | 46 | clean() 47 | yield 48 | clean() 49 | -------------------------------------------------------------------------------- /tests/requirements.txt: -------------------------------------------------------------------------------- 1 | pytest 2 | pytest-doctestplus 3 | pytest-cov 4 | -------------------------------------------------------------------------------- /tests/test.conf: -------------------------------------------------------------------------------- 1 | /////////////////////////////////////////////////////////////////////////////////////// 2 | ///////// > openSMILE configuration file for ComParE < ////////////////// 3 | ///////// updated version of ComParE 2013 set, numerical fixes ////////////////// 4 | ///////// ////////////////// 5 | ///////// (c) 2014-2016 by audEERING, ////////////////// 6 | ///////// All rights reserved. See file COPYING for details. ////////////////// 7 | /////////////////////////////////////////////////////////////////////////////////////// 8 | 9 | [componentInstances:cComponentManager] 10 | instance[dataMemory].type=cDataMemory 11 | 12 | ;;; source 13 | 14 | \{\cm[source{?}:include external source]} 15 | 16 | ;;; main section 17 | 18 | [componentInstances:cComponentManager] 19 | instance[framer].type = cFramer 20 | instance[lld].type = cEnergy 21 | instance[func].type=cFunctionals 22 | 23 | [framer:cFramer] 24 | reader.dmLevel = wave 25 | writer.dmLevel = frames 26 | copyInputName = 1 27 | frameMode = fixed 28 | frameSize = 0.025000 29 | frameStep = 0.010000 30 | frameCenterSpecial = left 31 | noPostEOIprocessing = 1 32 | 33 | [lld:cEnergy] 34 | reader.dmLevel = frames 35 | writer.dmLevel = lld 36 | \{\cm[bufferModeRbConf{?}:path to included config to set the buffer mode for the standard ringbuffer levels]} 37 | nameAppend = energy 38 | copyInputName = 1 39 | rms = 1 40 | log = 1 41 | 42 | [func:cFunctionals] 43 | reader.dmLevel=lld 44 | writer.dmLevel=func 45 | copyInputName = 1 46 | \{\cm[bufferModeRbConf]} 47 | \{\cm[frameModeFunctionalsConf{?}:path to included config to set frame mode for all functionals]} 48 | functionalsEnabled=Moments 49 | Moments.variance = 0 50 | Moments.stddev = 1 51 | Moments.skewness = 0 52 | Moments.kurtosis = 0 53 | Moments.amean = 1 54 | Moments.doRatioLimit = 0 55 | 56 | ;;; sink 57 | 58 | \{\cm[sink{?}:include external sink]} 59 | -------------------------------------------------------------------------------- /tests/test.wav: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/audeering/opensmile-python/9d7fd3da103a4e72c35c7b8f7978ce36b6f174b3/tests/test.wav -------------------------------------------------------------------------------- /tests/test_smile.py: -------------------------------------------------------------------------------- 1 | import os 2 | 3 | import numpy as np 4 | import pandas as pd 5 | import pytest 6 | 7 | import audeer 8 | import audiofile 9 | import audobject 10 | 11 | import opensmile 12 | 13 | 14 | deprecated_feature_sets = [ # deprecated 15 | opensmile.FeatureSet.GeMAPS, 16 | opensmile.FeatureSet.GeMAPSv01a, 17 | opensmile.FeatureSet.eGeMAPS, 18 | opensmile.FeatureSet.eGeMAPSv01a, 19 | opensmile.FeatureSet.eGeMAPSv01b, 20 | ] 21 | 22 | gemaps_family = [ # no deltas 23 | opensmile.FeatureSet.GeMAPS, 24 | opensmile.FeatureSet.GeMAPSv01a, 25 | opensmile.FeatureSet.GeMAPSv01b, 26 | opensmile.FeatureSet.eGeMAPS, 27 | opensmile.FeatureSet.eGeMAPSv01a, 28 | opensmile.FeatureSet.eGeMAPSv01b, 29 | opensmile.FeatureSet.eGeMAPSv02, 30 | ] 31 | 32 | 33 | @pytest.mark.parametrize( 34 | "x,sr,num_channels,feature_set,feature_level", 35 | [ 36 | ( 37 | pytest.WAV_ARRAY, 38 | pytest.WAV_SR, 39 | 3, 40 | pytest.CONFIG_FILE, 41 | opensmile.FeatureLevel.LowLevelDescriptors, 42 | ), 43 | ( 44 | pytest.WAV_ARRAY, 45 | pytest.WAV_SR, 46 | 5, 47 | pytest.CONFIG_FILE, 48 | opensmile.FeatureLevel.Functionals, 49 | ), 50 | ], 51 | ) 52 | def test_channels(x, sr, num_channels, feature_set, feature_level): 53 | x = np.repeat(x, num_channels, axis=0) 54 | 55 | # create feature extractor with mixdown 56 | 57 | fex = opensmile.Smile(feature_set, feature_level, mixdown=True) 58 | fex = audobject.from_yaml_s(fex.to_yaml_s()) 59 | assert isinstance(fex, opensmile.Smile) 60 | 61 | y_mono = fex.process_signal(x, sr) 62 | 63 | # create feature extractor for multiple channels 64 | 65 | fex = opensmile.Smile( 66 | feature_set, 67 | feature_level, 68 | channels=range(num_channels), 69 | ) 70 | fex = audobject.from_yaml_s(fex.to_yaml_s()) 71 | assert isinstance(fex, opensmile.Smile) 72 | 73 | y = fex.process_signal(x, sr) 74 | 75 | # assertions 76 | 77 | assert y_mono.shape[0] == y.shape[0] 78 | assert y_mono.shape[1] * len(fex.process.channels) == y.shape[1] 79 | for c in range(num_channels): 80 | np.testing.assert_equal( 81 | y.values[:, c * fex.num_features : (c + 1) * fex.num_features], 82 | y_mono.values, 83 | ) 84 | 85 | 86 | @pytest.mark.parametrize( 87 | "config,level", 88 | [ 89 | ( 90 | pytest.CONFIG_FILE, 91 | "lld", 92 | ), 93 | ( 94 | pytest.CONFIG_FILE, 95 | "func", 96 | ), 97 | pytest.param( 98 | "invalid.conf", 99 | "func", 100 | marks=pytest.mark.xfail(raises=FileNotFoundError), 101 | ), 102 | ], 103 | ) 104 | def test_custom(config, level): 105 | # create feature extractor 106 | 107 | fex = opensmile.Smile(config, level) 108 | fex = audobject.from_yaml_s(fex.to_yaml_s()) 109 | assert isinstance(fex, opensmile.Smile) 110 | 111 | # extract from file 112 | 113 | y_file = fex.process_file(pytest.WAV_FILE) 114 | 115 | # extract from array 116 | 117 | x, sr = audiofile.read(pytest.WAV_FILE) 118 | y_array = fex.process_signal(x, sr, file=pytest.WAV_FILE) 119 | 120 | # assertions 121 | 122 | assert fex.config_name == audeer.basename_wo_ext(config) 123 | assert fex.config_path == audeer.safe_path(config) 124 | assert fex.num_features == len(fex.feature_names) 125 | assert fex.feature_names == y_file.columns.to_list() 126 | pd.testing.assert_frame_equal(y_file, y_array) 127 | 128 | 129 | @pytest.mark.parametrize("feature_set", [x for x in opensmile.FeatureSet]) 130 | @pytest.mark.parametrize("feature_level", [x for x in opensmile.FeatureLevel]) 131 | def test_default(tmpdir, feature_set, feature_level): 132 | deltas = feature_level == opensmile.FeatureLevel.LowLevelDescriptors_Deltas 133 | 134 | if (feature_set in gemaps_family) and deltas: 135 | # deltas not available 136 | 137 | with pytest.raises(ValueError): 138 | opensmile.Smile(feature_set, feature_level) 139 | 140 | else: 141 | # create feature extractor 142 | 143 | if feature_set in deprecated_feature_sets: 144 | with pytest.warns(UserWarning): 145 | fex = opensmile.Smile(feature_set, feature_level) 146 | fex = audobject.from_yaml_s(fex.to_yaml_s()) 147 | assert isinstance(fex, opensmile.Smile) 148 | else: 149 | fex = opensmile.Smile(feature_set, feature_level) 150 | fex = audobject.from_yaml_s(fex.to_yaml_s()) 151 | assert isinstance(fex, opensmile.Smile) 152 | 153 | # extract features from file 154 | 155 | y = fex.process_file(pytest.WAV_FILE) 156 | 157 | # run SMILExtract from same file 158 | 159 | source_config_file = os.path.join( 160 | fex.default_config_root, 161 | opensmile.config.FILE_INPUT_CONFIG, 162 | ) 163 | if feature_set in gemaps_family: 164 | sink_config_file = os.path.join( 165 | fex.default_config_root, 166 | opensmile.config.FILE_OUTPUT_CONFIG_NO_LLD_DE, 167 | ) 168 | else: 169 | sink_config_file = os.path.join( 170 | fex.default_config_root, 171 | opensmile.config.FILE_OUTPUT_CONFIG, 172 | ) 173 | output_file = os.path.join(tmpdir, f"{feature_level.value}.csv") 174 | command = ( 175 | f"{pytest.SMILEXTRACT} " 176 | f"-C {fex.config_path} " 177 | f"-source {source_config_file} " 178 | f"-I {pytest.WAV_FILE} " 179 | f"-sink {sink_config_file} " 180 | f"-{feature_level.value}_csv_output {output_file}" 181 | ) 182 | os.system(command) 183 | 184 | # read output of SMILExtract and compare 185 | 186 | df = pd.read_csv(output_file, sep=";") 187 | np.testing.assert_allclose(df.values[:, 1:], y.values, rtol=1e-6, atol=0) 188 | assert fex.num_features == len(df.columns) - 1 189 | assert fex.feature_names == list(df.columns[1:]) 190 | 191 | 192 | @pytest.mark.parametrize("num_files", [1, 5]) 193 | @pytest.mark.parametrize( 194 | "feature_set,feature_level", 195 | [ 196 | (pytest.CONFIG_FILE, opensmile.FeatureLevel.LowLevelDescriptors), 197 | (pytest.CONFIG_FILE, opensmile.FeatureLevel.Functionals), 198 | ], 199 | ) 200 | @pytest.mark.parametrize( 201 | "num_workers, multiprocessing", 202 | [(1, False), (5, False), (5, True), (None, False)], 203 | ) 204 | def test_files(num_files, feature_set, feature_level, num_workers, multiprocessing): 205 | # create feature extractor 206 | 207 | fex = opensmile.Smile( 208 | feature_set, 209 | feature_level, 210 | num_workers=num_workers, 211 | multiprocessing=multiprocessing, 212 | ) 213 | fex = audobject.from_yaml_s( 214 | fex.to_yaml_s(), 215 | override_args={ 216 | "num_workers": num_workers, 217 | "multiprocessing": multiprocessing, 218 | }, 219 | ) 220 | assert isinstance(fex, opensmile.Smile) 221 | 222 | # extract from single file 223 | 224 | y_file = fex.process_file(pytest.WAV_FILE) 225 | 226 | # extract from files 227 | 228 | y_files = fex.process_files([pytest.WAV_FILE] * num_files) 229 | 230 | # assertions 231 | 232 | np.testing.assert_equal(np.concatenate([y_file] * num_files), y_files.values) 233 | 234 | 235 | @pytest.mark.parametrize( 236 | "feature_set,feature_level", 237 | [ 238 | ( 239 | pytest.CONFIG_FILE, 240 | opensmile.FeatureLevel.LowLevelDescriptors, 241 | ), 242 | ( 243 | pytest.CONFIG_FILE, 244 | opensmile.FeatureLevel.Functionals, 245 | ), 246 | ], 247 | ) 248 | @pytest.mark.parametrize( 249 | "index", 250 | [ 251 | pd.MultiIndex.from_arrays( 252 | [ 253 | [pytest.WAV_FILE] * 3, 254 | pd.to_timedelta([0, 1, 2], unit="s"), 255 | pd.to_timedelta([1, 2, 3], unit="s"), 256 | ], 257 | names=["file", "start", "end"], 258 | ), 259 | ], 260 | ) 261 | @pytest.mark.parametrize( 262 | "num_workers, multiprocessing", 263 | [(1, False), (5, False), (5, True), (None, False)], 264 | ) 265 | def test_index(feature_set, feature_level, index, num_workers, multiprocessing): 266 | # create feature extractor 267 | 268 | fex = opensmile.Smile( 269 | feature_set, 270 | feature_level, 271 | num_workers=num_workers, 272 | multiprocessing=multiprocessing, 273 | ) 274 | fex = audobject.from_yaml_s( 275 | fex.to_yaml_s(), 276 | override_args={ 277 | "num_workers": num_workers, 278 | "multiprocessing": multiprocessing, 279 | }, 280 | ) 281 | assert isinstance(fex, opensmile.Smile) 282 | 283 | # extract from index 284 | 285 | y = fex.process_index(index) 286 | 287 | # extract from files 288 | 289 | files = index.get_level_values(0) 290 | starts = index.get_level_values(1) 291 | ends = index.get_level_values(2) 292 | y_files = fex.process_files(files, starts=starts, ends=ends) 293 | 294 | # assertions 295 | 296 | pd.testing.assert_frame_equal(y, y_files) 297 | 298 | 299 | @pytest.mark.parametrize( 300 | "file,feature_set,feature_level", 301 | [ 302 | ( 303 | pytest.WAV_FILE, 304 | pytest.CONFIG_FILE, 305 | opensmile.FeatureLevel.LowLevelDescriptors, 306 | ), 307 | ( 308 | pytest.WAV_FILE, 309 | pytest.CONFIG_FILE, 310 | opensmile.FeatureLevel.Functionals, 311 | ), 312 | ], 313 | ) 314 | def test_signal(file, feature_set, feature_level): 315 | # create feature extractor 316 | 317 | fex = opensmile.Smile(feature_set, feature_level) 318 | fex = audobject.from_yaml_s(fex.to_yaml_s()) 319 | assert isinstance(fex, opensmile.Smile) 320 | 321 | # extract from numpy array 322 | 323 | x, sr = audiofile.read(file, always_2d=True) 324 | y = fex.process_signal(x, sr) 325 | y_file = fex.process_file(file) 326 | y_call = fex(x, sr) 327 | with pytest.warns(UserWarning): 328 | y_empty = fex.process_signal(x[0, :10], sr) 329 | 330 | # assertions 331 | 332 | assert y_call.ndim == 3 333 | assert fex.feature_names == y.columns.to_list() 334 | np.testing.assert_equal(y.values, y_file.values) 335 | np.testing.assert_equal(y.values.squeeze(), y_call.squeeze().T) 336 | assert all(y_empty.isna()) 337 | --------------------------------------------------------------------------------