opensmile-python icon indicating copy to clipboard operation
opensmile-python copied to clipboard

Is it possible to extract frame-wise features with the parameter "options"?

Open 00001101-xt opened this issue 5 years ago • 4 comments

smile = opensmile.Smile(feature_set=opensmile.FeatureSet.eGeMAPSv01b, feature_level=opensmile.FeatureLevel.Functionals)

The above script gives me features with shape 1x88, but I want frame-wise features with shape Nx88, so I changed the above statement to:

smile = opensmile.Smile(feature_set=opensmile.FeatureSet.eGeMAPSv01b, feature_level=opensmile.FeatureLevel.Functionals, options={"frameMode": "fixed", "frameSize": 0.025, "frameStep": 0.010})

But it produces 1x88 features still, so I wonder is it possible to extract Nx88 features setting the options parameter?

Thanks in advance.

00001101-xt avatar Dec 08 '20 10:12 00001101-xt

You can use feature_level=opensmile.LowLevelDescriptors, which will extract low-level descriptors instead of functionals. For opensmile.FeatureSet.eGeMAPSv01b you will get Nx10 features.

If your goal is to extract functionals on a running window, you can use the arguments starts and ends of process_files or start and end of process_signal. However, you should use a larger window size than 0.025 in this case.

frankenjoe avatar Dec 08 '20 12:12 frankenjoe

@frankenjoe Can I exctract standalone features like MFCC etc using this script?

krishna51119 avatar Feb 08 '21 11:02 krishna51119

We have scripts that extract MFCCs only: https://github.com/audeering/opensmile/tree/master/config/mfcc

Note that you have to adapt them slightly to use with pyopensmile, see https://audeering.github.io/opensmile-python/usage.html#custom-config

frankenjoe avatar Feb 10 '21 08:02 frankenjoe