Comments (1)
Yes, but there's indeed no API reference for this, because there is no Python API, yet.
Until I add this (or someone else does; help welcome ;-) ), you can go through parselmouth.praat.call
:
>>> import parselmouth
>>> s = parselmouth.Sound("the_north_wind_and_the_sun.wav")
>>> lpc = parselmouth.praat.call(s, "To LPC (autocorrelation)", 16, 0.025, 0.005, 50.0)
>>> lpc
<parselmouth.Data object at 0x7f4f3f5d3c00>
>>> lpc.class_name
'LPC'
>>> print(lpc)
Object type: LPC
Object name: untitled
Date: Thu Nov 22 11:38:48 2018
Time domain: 0 to 1.283265306122449 (s).
Prediction order: 16
Number of frames: 247
Time step: 0.005 (s).
First frame at: 0.026632653061224473 (s).
As you can see, the Python type of lpc
is parselmouth.Data
(so it does not have a lot of methods), but the actual underlying Praat type is "LPC"
, which means you can use it in further calls to parselmouth.praat.call
until you get a more useful object or the values you're interested in. For example, you could:
>>> parselmouth.praat.call(lpc, "Get number of coefficients", 1)
16
Or to get all raw values (consult the Praat documentation to see what these actually mean!), you could:
>>> lpc_matrix = parselmouth.praat.call(lpc, "Down to Matrix (lpc)")
>>> lpc_matrix
<parselmouth.Matrix object at 0x7f4f3f5eac00>
>>> lpc_matrix.values
array([[ 0.12599566, 0.12089129, 0.1061873 , ..., -1.19781365,
-1.14358651, -1.1659433 ],
[ 0.51795006, 0.46722564, 0.51150008, ..., 1.14546318,
1.09264874, 1.14384542],
[-0.01884895, 0.02674646, 0.04591352, ..., -1.38964444,
-1.42701829, -1.50292197],
...,
[-0.01957717, -0.00318544, -0.09061003, ..., 0.46313035,
0.41949584, 0.54231048],
[-0.06745527, -0.0395186 , -0.03539812, ..., -0.2470586 ,
-0.23618874, -0.33601743],
[-0.01429427, 0.00990911, -0.02896412, ..., 0.05589769,
0.06509704, 0.10742232]])
>>> lpc_matrix.values.shape
(16, 247)
I'll have a look how much work it would be to port LPC
to the Python API, and see if I can maybe find some time within the next few months, so you can leave this issue open for now.
from parselmouth.
Related Issues (20)
- Pre-built arm64 wheels for the PyPy interpreter HOT 5
- Feature Request - Work with Audio file's download URL HOT 6
- Intensity of wavefile is not the same from praat and parselmouth HOT 4
- Python 3.12 and Parselmouth 0.5.0 HOT 4
- [Build issues] cmake not found / 'ninja' has no attribute 'BIN_DIR' HOT 1
- Failed building wheel for praat-parselmouth HOT 4
- Installation Failing when using Visual Studio 2022 and Windows 11 HOT 15
- External documentation for praat.call()? HOT 3
- Is it possible to extract pitch using Parselmouth with only mel-spectrograms provided? HOT 5
- Formant calculation not as accurate as in the Praat software HOT 3
- Ltas class in parselmouth? HOT 2
- How to extract pitch value of all syllables in a audio file ? HOT 3
- Missing import praat HOT 6
- Load Sound from memory? HOT 3
- Building wheel hangs on ppc64le HOT 10
- How to get values for timestamps for pitch strength, MFCCs? HOT 4
- Windows install should updated to "py -m pip install praat-parselmouth" HOT 1
- parselmouth.PraatError: Not an audio file. HOT 3
- "ERROR: Failed building wheel for praat-parselmouth" on Ubuntu HOT 1
- vision for Linux arm HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from parselmouth.