MATLAB.jl
MATLAB.jl copied to clipboard
Failed to open a MATLAB engine session on Windows
Hello,
When calling MSession(), I get the following error on Windows: ERROR: MEngineError("Failed to open a MATLAB engine session") in MSession at MATLAB\cVrxc\src\engine.jl:23.
I'm using Matlab R2019b 64 bits. I can start Matlab normally. I have set the env variable MATLAB_HOME and runned matlab -regserver in a Command Prompt as Administrator.
Anyone knows how to fix this?
which julia version and platform?
Julia 1.2.0 Windows10
Without explicitly calling MSession
, can you just do
mat"ver"
to see if Julia will connect to the Matlab engine?
Without explicitly calling
MSession
, can you just domat"ver"
to see if Julia will connect to the Matlab engine?
It reports the error: MEngineError("failed to open MATLAB engine session")
very odd.
I had to do the following (which is manually/hardcoded for R2020b)
- clone my version https://github.com/jacob-roth/MATLAB.jl.git
- add
push!(LOAD_PATH,"C:\\Users\\roth0674\\git\\MATLAB.jl")
to AppData/Local/Programs/Julia-1.x.x/etc/julia/startup.jl and open REPL- from REPL, set ENV["MATLAB_ROOT"] = "C:\Program Files\MATLAB\R2020b\" (you will have to move it to this location if you dont want to edit my fork)
- ] add "C:\path\to\cloned\MATLAB.jl"
- ] build MATLAB
- using MATLAB