⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 marginal_nodes.m

📁 贝叶斯算法(matlab编写) 安装,添加目录 /home/ai2/murphyk/matlab/FullBNT
💻 M
字号:
function marginal = marginal_nodes(engine, b, nodes, t, add_ev, is_fam)% function marginal = marginal_nodes(engine, b, nodes, t, add_ev, is_fam) (jtree_2TBN)if nargin < 6, is_fam = 0; endss = engine.slice_size;if ~is_fam & (t > 1) & all(nodes<=ss)  nodes = nodes + ss;endif t==1  c = clq_containing_nodes(engine.jtree_engine1, nodes, is_fam);else  c = clq_containing_nodes(engine.jtree_engine, nodes, is_fam);endif c == -1  error(['no clique contains ' nodes])endbigpot = b.clpot{c};pot = marginalize_pot(bigpot, nodes, engine.maximize);marginal = pot_to_marginal(pot);% we convert the domain to the unrolled numbering system% so that add_ev_to_dmarginal (maybe called in update_ess) extracts the right evidence.if t > 1  marginal.domain = nodes+(t-2)*engine.slice_size;endassert(~add_ev);

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -