Is that possible to convert the Bayesian network designed in Genie to Matlab?
Thanks in advance.
Genie to Matlab
-
- Site Admin
- Posts: 1417
- Joined: Mon Nov 26, 2007 5:51 pm
Re: Genie to Matlab
It depends on what kind of Matlab output you want. There's no direct way to load a .xdsl file into Matlab.sirinoz wrote:Is that possible to convert the Bayesian network designed in Genie to Matlab?
Re: Genie to Matlab
I want probability values of target nodes given some other nodes.
Re: Genie to Matlab
shooltz wrote:It depends on what kind of Matlab output you want. There's no direct way to load a .xdsl file into Matlab.sirinoz wrote:Is that possible to convert the Bayesian network designed in Genie to Matlab?
I want probability values of target nodes given some other nodes.
-
- Site Admin
- Posts: 1417
- Joined: Mon Nov 26, 2007 5:51 pm
Re: Genie to Matlab
You have three options:sirinoz wrote:I want probability values of target nodes given some other nodes.
1) create an external, standalone executable linked with SMILE. Thie program would be called from Matlab with the system() function.
http://www.mathworks.com/help/matlab/ref/system.html
2) call jSMILE (Java) directly from Matlab:
http://www.mathworks.com/help/matlab/us ... atlab.html
3) call SMILE (C++) directly from Matlab
http://www.mathworks.com/help/matlab/wr ... files.html
Re: Genie to Matlab
Hello,
I am working on the third option of the last post, i.e. calling SMILE (C++) directly from Matlab.
After adding the path leading to SMILE folder, I try to add SMILE library to Matlab with the following code
Unfortunately I get the following message from Matlab
Does anyone know the reason of this error?
Moreover I read on "loadlibrary" description of Matlab that
I am working on the third option of the last post, i.e. calling SMILE (C++) directly from Matlab.
After adding the path leading to SMILE folder, I try to add SMILE library to Matlab with the following code
Code: Select all
loadlibrary('smile','smile.h');
Code: Select all
Error using loadlibrary
Failed to preprocess the input file.
Output from preprocessor is:smile.h
C:\Users\mancusa1\Visual Studio 2015\smile_vc14_x64\smile.h(26): fatal error C1189: #error: SMILE : in
debug build the runtime library must be set to Multi-threaded Debug DLL
Moreover I read on "loadlibrary" description of Matlab that
I wonder if SMILE functions are declared as extern "C".Functions written in C++ must be declared as extern "C".
-
- Site Admin
- Posts: 1417
- Joined: Mon Nov 26, 2007 5:51 pm
Re: Genie to Matlab
They can't be declared as extern "C", because almost all of the SMILE's functionality is exposed as C++ classes (there are a few global functions, but they're a tiny minority).I wonder if SMILE functions are declared as extern "C".
What you'd need to do is create your own extern "C" function(s) which call into SMILE. This may be doable depeding on what do you want to achieve. I believe it's not a reasonable way to obtain a fully featured SMILE wrapper for Matlab.