I've set up a Jupyter Notebook to run MATLAB via the matlab_kernel, following the instructions on this GitHub page. Basic functions like peaks or plot(...) work with no issue on Jupyter.
However, I got an error when executing a function that calls medfilt1.m in the signal toolbox (..\MATLAB\R2020a\toolbox\signal\signal\medfilt1.m):
Invalid MEX-file 'C:\Users\...\mvmedian.mexw64': The specified procedure could not be found.
I noticed that medfilt1.m calls mvmedian() function (y = mvmedian(x,n,dim,'central',missing,padding)) and mvmedian.mexw64 file does exist in ..\MATLAB\R2020a\toolbox\signal\signal\private.
I tried to check the dependencies of mvmedian.mexw64 using Dependency Walker by following the steps explained in here and MATLAB Answers. There are so many dependencies (.dll files), and I am not sure if I need to download all of them (from DLL-FILES.COM) and add their path to Jupyter Notebook...
The function runs without any issue when I run the same script directly in MATLAB.
Why does it give an error when I run it on Jupyter Notebook? Is this something to do with matlab_kernel? How can I resolve this issue?
Thanks,
My environment is:
64-bit Windows 10 (x64-based processor)
MATLAB 2023a
VS Code 1.81.0
Python 3.9.17