adamstark / gist Goto Github PK
View Code? Open in Web Editor NEWA C++ Library for Audio Analysis
Home Page: http://www.adamstark.co.uk/project/gist/
License: GNU General Public License v3.0
A C++ Library for Audio Analysis
Home Page: http://www.adamstark.co.uk/project/gist/
License: GNU General Public License v3.0
First, thank you for both AudioFile and Gist. AudioFile has been working well but I cannot make any progress with Gist. I am receiving this error:
C:\Users\nabee\AppData\Local\Temp\ccUdNSDs.o: In function Z30loadAudioFileAndProcessSamplesv': C:/Users/nabee/Senior Project/AudioFile Gist/music.cpp:73: undefined reference to
Gist::Gist(int, int, WindowType)'
C:/Users/nabee/Senior Project/AudioFile Gist/music.cpp:98: undefined reference to Gist<float>::processAudioFrame(std::vector<float, std::allocator<float> > const&)' C:/Users/nabee/Senior Project/AudioFile Gist/music.cpp:101: undefined reference to
Gist::highFrequencyContent()'
C:/Users/nabee/Senior Project/AudioFile Gist/music.cpp:73: undefined reference to Gist<float>::~Gist()' C:/Users/nabee/Senior Project/AudioFile Gist/music.cpp:73: undefined reference to
Gist::~Gist()'
collect2.exe: error: ld returned 1 exit status
I have added and have a direct path to MFCC.h but am still receiving the error. Please help.
Just a simple question, but where would I get the audio frames for the analysis? Nothing I can look up seems to be precise or just gives me items that look incompatible with the code.
Hello, I am using the Gist and AudioFile to retrieve FFT data from the input audio file, but forgive me I have no idea to set the flag. Could you explain how to set up the FFT function in Visual Studio Solution project? If I want to use KiSS_FFT, I also need to link the library into my project? Thanks so much if you can reply to me.
@adamstark Hi Adam! Thanks for sharing the code. This may be a silly question -- I don't know how to install the library. I didn't find ./configure file. Could you explain the procedure a little bit? Thanks!
Ohai!
Been enjoying the use of Gist for a bit now, but It seems that the onset detection is missing the most crucial part of Onset detection for me, which is the exact position of the estimated onset.
It seems that the functions only reports back the value when a Onset is detected, not the actual position of the sample in the provided buffer.
Am I missing something? Or is this just not implemented.
Thanks!
Bringing to make discussion #13 (comment) visible.
Hello when trying to compile I get the following error:
In file included from Gist.h:39:0,
from main.cpp:1:
mfcc/MFCC.h:95:70: error: 'size_t' does not name a type
void discreteCosineTransform (std::vector<T>& inputSignal, const size_t numElements);
^~~~~~
I use gcc and I'm on windows 10.
I tried to maually add to the MFCC.h
header and then I get this:
C:\Users\Stavros Avramidis\Desktop\audio-test>g++ main.cpp -DUSE_KISS_FFT
C:\Users\STAVRO~1\AppData\Local\Temp\ccPlreFf.o:main.cpp:(.text+0x46): undefined reference to `Gist<float>::Gist(int, int, WindowType)'
C:\Users\STAVRO~1\AppData\Local\Temp\ccPlreFf.o:main.cpp:(.text+0x6c): undefined reference to `Gist<float>::processAudioFrame(std::vector<float, std::allocator<float> > const&)'
C:\Users\STAVRO~1\AppData\Local\Temp\ccPlreFf.o:main.cpp:(.text+0x89): undefined reference to `Gist<float>::~Gist()'
C:\Users\STAVRO~1\AppData\Local\Temp\ccPlreFf.o:main.cpp:(.text+0xac): undefined reference to `Gist<float>::~Gist()'
collect2.exe: error: ld returned 1 exit status
Issue compiling using VS2017.
template <class T>
void MFCC<T>::discreteCosineTransform (std::vector<T>& inputSignal, const size_t numElements)
{
// the input signal must have the number of elements specified in the numElements variable
assert (inputSignal.size() == numElements);
T signal[numElements]; // copy to work on --> this is throwing an error
Error C2131 expression did not evaluate to a constant Project
i created a debug_gist.cpp
out of, but beside the Gist folder:
#include <iostream>
#include "Gist/src/Gist.h"
#include "Gist/libs/kiss_fft130/kiss_fft.h"
using namespace std;
int main () {
int frameSize = 512;
int sampleRate = 44100;
Gist<float> gist (frameSize, sampleRate);
return 0 ;
}
When i ran this g++ -DUSE_KISS_FFT debug_gist.cpp
, i get the undefined reference
errors:
/tmp/ccMjqnF9.o: In function `main':
debug.cpp:(.text+0x4b): undefined reference to `Gist<float>::Gist(int, int, WindowType)'
debug.cpp:(.text+0x5f): undefined reference to `Gist<float>::~Gist()'
collect2: error: ld returned 1 exit status
I tried to include all the *.cpp files within the src when i compile, (and i added in #include <cstdlib>
#include <stddef.h>
to all of them)
g++ -DUSE_KISS_FFT \
$(find Gist/src/ -name "*.cpp" ! -path "*Accelerate*") \
debug_gist.cpp
i get the following error
/tmp/ccIkVWzO.o: In function `main':
debug_gist.cpp:(.text+0x0): multiple definition of `main'
/tmp/ccGRWERk.o:debug.cpp:(.text+0x0): first defined here
/tmp/cc0v0kst.o: In function `Gist<float>::configureFFT()':
Gist.cpp:(.text._ZN4GistIfE12configureFFTEv[_ZN4GistIfE12configureFFTEv]+0xb0): undefined reference to `kiss_fft_alloc'
/tmp/cc0v0kst.o: In function `Gist<float>::performFFT()':
Gist.cpp:(.text._ZN4GistIfE10performFFTEv[_ZN4GistIfE10performFFTEv]+0xc5): undefined reference to `kiss_fft'
/tmp/cc0v0kst.o: In function `Gist<double>::configureFFT()':
Gist.cpp:(.text._ZN4GistIdE12configureFFTEv[_ZN4GistIdE12configureFFTEv]+0xb0): undefined reference to `kiss_fft_alloc'
/tmp/cc0v0kst.o: In function `Gist<double>::performFFT()':
Gist.cpp:(.text._ZN4GistIdE10performFFTEv[_ZN4GistIdE10performFFTEv]+0xc9): undefined reference to `kiss_fft'
collect2: error: ld returned 1 exit status
While the problem of undefined reference
is gone now,
there is the problem of multiple definition of main
,
as well as kiss_fft
and kiss_fft_alloc
issues.
I tried to include all the *.cpp files within the src when i compile, (and i added in #include <cstdlib>
#include <stddef.h>
to all of them)
g++ -DUSE_KISS_FFT \
$(find Gist/src/ -name "*.cpp" ! -path "*Accelerate*") \
Gist/libs/kiss_fft130/kiss_fft.c \
debug_gist.cpp
i get the following error
/tmp/ccS0Symo.o: In function `main':
debug_gist.cpp:(.text+0x0): multiple definition of `main'
/tmp/ccMFylKq.o:debug.cpp:(.text+0x0): first defined here
collect2: error: ld returned 1 exit status
While the problem of undefined reference
, kiss_fft
and kiss_fft_alloc
is gone now,
there is still the problem of multiple definition of main
.
What is the right way for me to compile this Gist properly?
Hello.
I am using Gist as part of a project and when I added Gist and some sample code to the project; I got the old LNK2019 error in Visual Studio 2017.
Just from using the constructor; I am getting:
This is true in both my project, which I am intending to use FFTW and in an isolated solution which Kiss FFT is intended.
The FFTW is working fine on its own, and I believe that this issue has to do with the flagging for the dependencies.
Here is the basic code from the isolated solution:
#include "pch.h"
#include "src\Gist.h"
#include <iostream>
int main() {
int frameSize = 512;
int sampleRate = 44100;
Gist<float> gist(frameSize, sampleRate);
}
Hi,
I am using Visual Studio on Windows.
I have copied the necessary files over to my working directory, namely
1. src/Gist.h
2. src/<all the folders>
When i ran it, i have these errors, on just the substantiation line Gist<double> gist (frameSize, sampleRate);
type name is not allowed
identifier "Gist" is undefined
identifier "gist" is undefined
Am i using your package wrongly?
So I am using Kiss_FFT, and I have the -DUSE_KISS_FFT flag up. However, when compiling, the AccelerateFFT files are still being compiled. This is causing 84 errors, all from the acceleratefft files.
the following is the log
1 running build
2 running config_cc
3 unifing config_cc, config, build_clib, build_ext, build commands --compiler options
4 running config_fc
5 unifing config_fc, config, build_clib, build_ext, build commands --fcompiler options
6 running build_src
7 build_src
8 building extension "gist" sources
9 build_src: building npy-pkg config files
10 running build_ext
11 customize UnixCCompiler
12 customize UnixCCompiler using build_ext
13 customize UnixCCompiler
14 customize UnixCCompiler using build_ext
15 building 'gist' extension
16 compiling C++ sources
17 C compiler: g++ -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -I/Users/jenweilee/anaconda3/include -arch x86_ 64 -I/Users/jenweilee/anaconda3/include -arch x86_64
18
19 compile options: '-DUSE_FFTW -I/Users/jenweilee/anaconda3/lib/python3.6/site-packages/numpy/core/include -I/Users/jenweilee/anaconda3/lib/python3. 6/site-packages/numpy/core/include -I/usr/local/include -I/Users/jenweilee/anaconda3/include/python3.6m -c'
20 g++: GistPythonModule.cpp
21 In file included from GistPythonModule.cpp:4:
22 In file included from /Users/jenweilee/anaconda3/lib/python3.6/site-packages/numpy/core/include/numpy/arrayobject.h:4:
23 In file included from /Users/jenweilee/anaconda3/lib/python3.6/site-packages/numpy/core/include/numpy/ndarrayobject.h:18:
24 In file included from /Users/jenweilee/anaconda3/lib/python3.6/site-packages/numpy/core/include/numpy/ndarraytypes.h:1818:
25 /Users/jenweilee/anaconda3/lib/python3.6/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:15:2: warning: "Using deprecated NumPy AP I, disable it by " "#defining NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-W#warnings]
26 #warning "Using deprecated NumPy API, disable it by "
27 ^
28 GistPythonModule.cpp:44:12: error: use of undeclared identifier 'PyInt_FromLong'; did you mean 'PyLong_FromLong'?
29 return PyInt_FromLong((long) gist.getAudioFrameSize());
30 ^~~~~~~~~~~~~~
31 PyLong_FromLong
32 /Users/jenweilee/anaconda3/include/python3.6m/longobject.h:18:24: note: 'PyLong_FromLong' declared here
33 PyAPI_FUNC(PyObject *) PyLong_FromLong(long);
34 ^
35 GistPythonModule.cpp:50:12: error: use of undeclared identifier 'PyInt_FromLong'; did you mean 'PyLong_FromLong'?
36 return PyInt_FromLong((long) gist.getSamplingFrequency());
37 ^~~~~~~~~~~~~~
38 PyLong_FromLong
39 /Users/jenweilee/anaconda3/include/python3.6m/longobject.h:18:24: note: 'PyLong_FromLong' declared here
40 PyAPI_FUNC(PyObject *) PyLong_FromLong(long);
41 ^
42 GistPythonModule.cpp:309:11: error: use of undeclared identifier 'Py_InitModule'
43 (void)Py_InitModule("gist", gist_methods);
44 ^
45 GistPythonModule.cpp:317:5: error: no matching function for call to 'Py_SetProgramName'
46 Py_SetProgramName(argv[0]);
47 ^~~~~~~~~~~~~~~~~
48 /Users/jenweilee/anaconda3/include/python3.6m/pylifecycle.h:10:18: note: candidate function not viable: no known conversion from 'char *' to 'wcha r_t *' for 1st argument
49 PyAPI_FUNC(void) Py_SetProgramName(wchar_t *);
50 ^
51 1 warning and 4 errors generated.
52 In file included from GistPythonModule.cpp:4:
53 In file included from /Users/jenweilee/anaconda3/lib/python3.6/site-packages/numpy/core/include/numpy/arrayobject.h:4:
54 In file included from /Users/jenweilee/anaconda3/lib/python3.6/site-packages/numpy/core/include/numpy/ndarrayobject.h:18:
55 In file included from /Users/jenweilee/anaconda3/lib/python3.6/site-packages/numpy/core/include/numpy/ndarraytypes.h:1818:
56 /Users/jenweilee/anaconda3/lib/python3.6/site-packages/numpy/core/include/numpy/npy_1_7_deprecated_api.h:15:2: warning: "Using deprecated NumPy AP I, disable it by " "#defining NPY_NO_DEPRECATED_API NPY_1_7_API_VERSION" [-W#warnings]
57 #warning "Using deprecated NumPy API, disable it by "
58 ^
59 GistPythonModule.cpp:44:12: error: use of undeclared identifier 'PyInt_FromLong'; did you mean 'PyLong_FromLong'?
60 return PyInt_FromLong((long) gist.getAudioFrameSize());
61 ^~~~~~~~~~~~~~
62 PyLong_FromLong
63 /Users/jenweilee/anaconda3/include/python3.6m/longobject.h:18:24: note: 'PyLong_FromLong' declared here
64 PyAPI_FUNC(PyObject *) PyLong_FromLong(long);
65 ^
66 GistPythonModule.cpp:50:12: error: use of undeclared identifier 'PyInt_FromLong'; did you mean 'PyLong_FromLong'?
67 return PyInt_FromLong((long) gist.getSamplingFrequency());
68 ^~~~~~~~~~~~~~
69 PyLong_FromLong
70 /Users/jenweilee/anaconda3/include/python3.6m/longobject.h:18:24: note: 'PyLong_FromLong' declared here
71 PyAPI_FUNC(PyObject *) PyLong_FromLong(long);
72 ^
73 GistPythonModule.cpp:309:11: error: use of undeclared identifier 'Py_InitModule'
74 (void)Py_InitModule("gist", gist_methods);
75 ^
76 GistPythonModule.cpp:317:5: error: no matching function for call to 'Py_SetProgramName'
77 Py_SetProgramName(argv[0]);
78 ^~~~~~~~~~~~~~~~~
79 /Users/jenweilee/anaconda3/include/python3.6m/pylifecycle.h:10:18: note: candidate function not viable: no known conversion from 'char *' to 'wcha r_t *' for 1st argument
80 PyAPI_FUNC(void) Py_SetProgramName(wchar_t *);
81 ^
82 1 warning and 4 errors generated.
hello @adamstark ,
it looks that your site is down.
could you share the plugin as a release here on GH?
regards
I install the following libraries:
And link -DUSE_FFTW or -DUSE_KISS_FFT but test not working.
When building a file that includes MFCC.h
.
size_t
requires an #include <stddef.h>
, or you can use std::size_t
instead.
Hello,author。
I would like to ask you a few questions?
1.Is it possible to get mfcc for only one frame of audio, for example, if I input audio for 10s and 100s respectively, the result is a 13-dimensional mfcc.
2.When I get the mfcc feature, the first value is large. Excuse me, is the parameter I passed incorrect? (I use KISS_FFT)
`
extern "C" MY_MFCC void _stdcall GETMFCC(float *audioFrame, int frameSize, int sampleRate) {
Gist<float> gist(frameSize, sampleRate);
gist.processAudioFrame(audioFrame , frameSize);
const std::vector<float>& mfcc = gist.getMelFrequencyCepstralCoefficients();
std::cout << "size: " << mfcc.size() << std::endl;
}
`
Thank you very much and look forward to your answer.
Hello,
I modified the CMakeLists.txt inside the src folder to the following so that I can include the header file as a library.
include_directories (${CMAKE_CURRENT_SOURCE_DIR}/src)
include_directories (${CMAKE_CURRENT_SOURCE_DIR}/../libs/kiss_fft130)
add_library (
Gist STATIC
AccelerateFFT.cpp
AccelerateFFT.h
CoreFrequencyDomainFeatures.cpp
CoreFrequencyDomainFeatures.h
CoreTimeDomainFeatures.cpp
CoreTimeDomainFeatures.h
Gist.cpp
Gist.h
MFCC.cpp
MFCC.h
OnsetDetectionFunction.cpp
OnsetDetectionFunction.h
WindowFunctions.cpp
WindowFunctions.h
Yin.cpp
Yin.h
)
target_include_directories (${PROJECT_NAME} PUBLIC ${CMAKE_CURRENT_SOURCE_DIR})
source_group (Source src)
target_compile_definitions (Gist PUBLIC -DUSE_KISS_FFT)
This is the CMakeLists.txt in the folder that contains my main function.
add_executable(plot_fourier_transform plot_fourier_transform.cpp)
target_compile_options(plot_fourier_transform PRIVATE)
target_include_directories(plot_fourier_transform
PRIVATE
"${CMAKE_CURRENT_SOURCE_DIR}/../../include"
)
target_link_libraries(plot_fourier_transform
PRIVATE
AudioFile
Gist
Python3::Python
Python3::NumPy
)
set_target_properties(plot_fourier_transform
PROPERTIES
RUNTIME_OUTPUT_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/../bin"
OUTPUT_NAME "plot_fourier_transform"
SUFFIX ".o"
)
This is the content of my code:
#include <plot_fourier_transform/plot_fourier_transform.hpp>
int main(int argc, char** argv) {
if (argc != 2) {
std::cerr << "./plot_fourier_transform.o /path/to/*.wav" << std::endl;
exit(EXIT_FAILURE);
}
AudioFile<double> audio_file;
audio_file.load(argv[1]);
audio_file.printSummary();
int frame_size = audio_file.getNumSamplesPerChannel();
int sample_rate = audio_file.getSampleRate();
Gist<double> gist(frame_size, sample_rate);
gist.processAudioFrame(audio_file.samples[0]);
const std::vector<double>& magnitude_spectrum = gist.getMagnitudeSpectrum();
matplotlibcpp::figure();
matplotlibcpp::title("Magnitude Spectrum");
matplotlibcpp::plot(magnitude_spectrum);
matplotlibcpp::show();
}
This is the header file plot_fourier_transform.hpp:
#define INCLUDE_PLOT_SOUND_WAVE_HPP_
#include <iostream>
#include <vector>
#include <AudioFile.h>
#include <matplotlibcpp.h>
#endif // INCLUDE_PLOT_SOUND_WAVE_HPP_
#ifndef INCLUDE_PLOT_SOUND_WAVE_HPP_
#define INCLUDE_PLOT_SOUND_WAVE_HPP_
#include <iostream>
#include <vector>
#include <AudioFile.h>
#include <matplotlibcpp.h>
#endif // INCLUDE_PLOT_SOUND_WAVE_HPP_
Here is the error I received. It seems the linker cannot find kiss_fft library correctly. I tried to add #define USE_KISS_FFT by brute force, but cmake tells me that USE_KISS_FFT is already defined if I do it this way.
[main] Building folder: sound_detection clean
[build] Starting build
[proc] Executing command: /usr/bin/cmake --build /home/fred/Documents/Research/sound_detection/build --config Debug --target clean --
[build] [1/1 100% :: 0.008] Cleaning all built files...
[build] Cleaning... 22 files.
[build] Build finished with exit code 0
[main] Building folder: sound_detection
[build] Starting build
[proc] Executing command: /usr/bin/cmake --build /home/fred/Documents/Research/sound_detection/build --config Debug --target all -- -j 6
[build] [6/23 4% :: 4.604] Building CXX object third_party_libraries/AudioFile/tests/CMakeFiles/Tests.dir/GeneralTests.cpp.o
[build] [7/23 8% :: 4.755] Building CXX object third_party_libraries/Gist/src/CMakeFiles/Gist.dir/AccelerateFFT.cpp.o
[build] [8/23 13% :: 4.830] Building CXX object third_party_libraries/AudioFile/tests/CMakeFiles/Tests.dir/FileWritingTests.cpp.o
[build] [9/23 17% :: 4.967] Building CXX object third_party_libraries/AudioFile/examples/CMakeFiles/Examples.dir/examples.cpp.o
[build] [10/23 21% :: 5.282] Building CXX object third_party_libraries/AudioFile/tests/CMakeFiles/Tests.dir/AiffLoadingTests.cpp.o
[build] [11/23 26% :: 5.307] Linking CXX executable third_party_libraries/AudioFile/examples/Examples
[build] [12/23 30% :: 5.453] Building CXX object third_party_libraries/AudioFile/tests/CMakeFiles/Tests.dir/WavLoadingTests.cpp.o
[build] [13/23 34% :: 5.480] Building CXX object third_party_libraries/Gist/src/CMakeFiles/Gist.dir/CoreTimeDomainFeatures.cpp.o
[build] [14/23 39% :: 5.575] Building CXX object third_party_libraries/Gist/src/CMakeFiles/Gist.dir/CoreFrequencyDomainFeatures.cpp.o
[build] [15/23 43% :: 6.326] Building CXX object third_party_libraries/Gist/src/CMakeFiles/Gist.dir/OnsetDetectionFunction.cpp.o
[build] [16/23 47% :: 6.421] Building CXX object third_party_libraries/Gist/src/CMakeFiles/Gist.dir/WindowFunctions.cpp.o
[build] [17/23 52% :: 6.697] Building CXX object third_party_libraries/Gist/src/CMakeFiles/Gist.dir/Yin.cpp.o
[build] [18/23 56% :: 6.742] Building CXX object third_party_libraries/Gist/src/CMakeFiles/Gist.dir/Gist.cpp.o
[build] [18/23 60% :: 6.960] Building CXX object third_party_libraries/Gist/src/CMakeFiles/Gist.dir/MFCC.cpp.o
[build] [19/23 65% :: 7.165] Linking CXX static library third_party_libraries/Gist/src/libGist.a
[build] [19/23 69% :: 8.961] Building CXX object src/CMakeFiles/main.dir/main.cpp.o
[build] [20/23 73% :: 9.200] Linking CXX executable ../bin/sound_detection_main.o
[build] [20/23 78% :: 9.336] Building CXX object third_party_libraries/AudioFile/tests/CMakeFiles/Tests.dir/main.cpp.o
[build] [21/23 82% :: 9.609] Building CXX object src/plot_fourier_transform/CMakeFiles/plot_fourier_transform.dir/plot_fourier_transform.cpp.o
[build] [22/23 86% :: 9.698] Linking CXX executable third_party_libraries/AudioFile/tests/Tests
[build] [22/23 91% :: 9.806] Building CXX object src/plot_sound_wave/CMakeFiles/plot_sound_wave.dir/plot_sound_wave.cpp.o
[build] [23/23 95% :: 9.871] Linking CXX executable ../src/bin/plot_fourier_transform.o
[build] FAILED: ../src/bin/plot_fourier_transform.o
[build] : && /bin/g++-9 -g -rdynamic src/plot_fourier_transform/CMakeFiles/plot_fourier_transform.dir/plot_fourier_transform.cpp.o -o ../src/bin/plot_fourier_transform.o third_party_libraries/Gist/src/libGist.a /usr/lib/x86_64-linux-gnu/libpython3.8.so && :
[build] /usr/bin/ld: third_party_libraries/Gist/src/libGist.a(Gist.cpp.o): in function `Gist<float>::configureFFT()':
[build] /home/fred/Documents/Research/sound_detection/build/../third_party_libraries/Gist/src/Gist.cpp:264: undefined reference to `kiss_fft_alloc'
[build] /usr/bin/ld: third_party_libraries/Gist/src/libGist.a(Gist.cpp.o): in function `Gist<float>::performFFT()':
[build] /home/fred/Documents/Research/sound_detection/build/../third_party_libraries/Gist/src/Gist.cpp:326: undefined reference to `kiss_fft'
[build] /usr/bin/ld: third_party_libraries/Gist/src/libGist.a(Gist.cpp.o): in function `Gist<double>::configureFFT()':
[build] /home/fred/Documents/Research/sound_detection/build/../third_party_libraries/Gist/src/Gist.cpp:264: undefined reference to `kiss_fft_alloc'
[build] /usr/bin/ld: third_party_libraries/Gist/src/libGist.a(Gist.cpp.o): in function `Gist<double>::performFFT()':
[build] /home/fred/Documents/Research/sound_detection/build/../third_party_libraries/Gist/src/Gist.cpp:326: undefined reference to `kiss_fft'
[build] collect2: error: ld returned 1 exit status
[build] [23/23 100% :: 9.953] Linking CXX executable ../bin/plot_sound_wave.o
[build] ninja: build stopped: subcommand failed.
[build] Build finished with exit code 1
Would you be able to help me figure out what is going on?
Hello !
I'm new to audio manipulation and I'd like to know how to use properly your gists function to do onset detection. First question is I don't know what to put in the energyDifference function paramaters. Can you explain me a little bit ?
Thank you ;)
Hi,
First, thanks for the good work!!!
I thought I had an error, but as always as soon as it was posted I found my own error....
Just telling that it works fine on pocketbeagle with debian linux.
Best, Hans.
Hello,
Thanks for this great library!
Is there any way to use your code to create mel-spectrograms, besides for dividing the audio into segments of the desired window length, getting the mel-spectrum for each, and putting them together into a mel-spectrogram yourself?
Thank you very much!
Hi,
I'm trying to compile the code but I'm not sure how to set the fft macros. Can you help me with this?
Here's my makefile. Adding "-DUSE_KISS_FFT" to the flags didn't help
`
LDFLAGS = -lgsl -lgslcblas -lm -lsndfile -DUSE_KISS_FFT
a: test.o inference.o
g++ test.o inference.o -o a $(LDFLAGS)
test.o: test.cpp inference.hpp
g++ -c test.cpp inference.hpp
inference.o: inference.cpp inference.hpp
g++ -c inference.cpp inference.hpp
clean:
-rm -f test.o inference.o inference.h.gch
`
Here's the error:
Gist/src/Gist.h:56:2: error: #error "You must define one FFT macro to ensure you select a FFT implementation - either USE_FFTW, USE_KISS_FFT or USE_ACCELERATE_FFT. You have either not defined one of these macros or you have defined more than one of them." 56 | #error "You must define one FFT macro to ensure you select a FFT implementation - either USE_FFTW, USE_KISS_FFT or USE_ACCELERATE_FFT. You have either not defined one of these macros or you have defined more than one of them." | ^~~~~ make: *** [makefile:7: test.o] Error 1
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.