<spanid="pyctbn-pyctbn-estimators-fam-score-calculator-module"></span><h2>PyCTBN.PyCTBN.estimators.fam_score_calculator module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.estimators.fam_score_calculator"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-estimators-parameters-estimator-module"></span><h2>PyCTBN.PyCTBN.estimators.parameters_estimator module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.estimators.parameters_estimator"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-estimators-structure-constraint-based-estimator-module"></span><h2>PyCTBN.PyCTBN.estimators.structure_constraint_based_estimator module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.estimators.structure_constraint_based_estimator"title="Permalink to this headline">¶</a></h2>
<codeclass="sig-name descname">ctpc_algorithm</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">disable_multiprocessing</span><spanclass="p">:</span><spanclass="n">bool</span><spanclass="o">=</span><spanclass="default_value">False</span></em><spanclass="sig-paren">)</span><aclass="headerlink"href="#PyCTBN.PyCTBN.estimators.structure_constraint_based_estimator.StructureConstraintBasedEstimator.ctpc_algorithm"title="Permalink to this definition">¶</a></dt>
<codeclass="sig-name descname">ctpc_algorithm</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">disable_multiprocessing</span><spanclass="p">:</span><spanclass="n">bool</span><spanclass="o">=</span><spanclass="default_value">False</span></em>, <emclass="sig-param"><spanclass="n">processes_number</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em><spanclass="sig-paren">)</span><aclass="headerlink"href="#PyCTBN.PyCTBN.estimators.structure_constraint_based_estimator.StructureConstraintBasedEstimator.ctpc_algorithm"title="Permalink to this definition">¶</a></dt>
<dd><p>Compute the CTPC algorithm over the entire net.</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>disable_multiprocessing</strong> (<em>Boolean</em><em>, </em><em>optional</em>) – true if you desire to disable the multiprocessing operations, default to False</p></li>
<li><p><strong>processes_number</strong> – if disable_multiprocessing is false indicates</p></li>
</ul>
</dd>
</dl>
<p>the maximum number of process; if None it will be automatically set, default to None
<codeclass="sig-name descname">estimate_structure</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">disable_multiprocessing</span><spanclass="p">:</span><spanclass="n">bool</span><spanclass="o">=</span><spanclass="default_value">False</span></em><spanclass="sig-paren">)</span><aclass="headerlink"href="#PyCTBN.PyCTBN.estimators.structure_constraint_based_estimator.StructureConstraintBasedEstimator.estimate_structure"title="Permalink to this definition">¶</a></dt>
<dd><p>Abstract method to estimate the structure</p>
<codeclass="sig-name descname">estimate_structure</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">disable_multiprocessing</span><spanclass="p">:</span><spanclass="n">bool</span><spanclass="o">=</span><spanclass="default_value">False</span></em>, <emclass="sig-param"><spanclass="n">processes_number</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em><spanclass="sig-paren">)</span><aclass="headerlink"href="#PyCTBN.PyCTBN.estimators.structure_constraint_based_estimator.StructureConstraintBasedEstimator.estimate_structure"title="Permalink to this definition">¶</a></dt>
<dd><p>Compute the constraint-based algorithm to find the optimal structure</p>
<dlclass="field-list simple">
<dtclass="field-odd">Returns</dt>
<ddclass="field-odd"><p>List of estimated edges</p>
</dd>
<dtclass="field-even">Return type</dt>
<ddclass="field-even"><p>Typing.List</p>
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>disable_multiprocessing</strong> (<em>Boolean</em><em>, </em><em>optional</em>) – true if you desire to disable the multiprocessing operations, default to False</p></li>
<li><p><strong>processes_number</strong> – if disable_multiprocessing is false indicates</p></li>
</ul>
</dd>
</dl>
<p>the maximum number of process; if None it will be automatically set, default to None
:type processes_number: int, optional</p>
</dd></dl>
<dlclass="py method">
@ -521,8 +533,8 @@ it is performed also the chi_test.</p>
<spanid="pyctbn-pyctbn-estimators-structure-estimator-module"></span><h2>PyCTBN.PyCTBN.estimators.structure_estimator module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.estimators.structure_estimator"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-estimators-structure-score-based-estimator-module"></span><h2>PyCTBN.PyCTBN.estimators.structure_score_based_estimator module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.estimators.structure_score_based_estimator"title="Permalink to this headline">¶</a></h2>
<codeclass="sig-name descname">estimate_structure</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">max_parents</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">iterations_number</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">40</span></em>, <emclass="sig-param"><spanclass="n">patience</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">tabu_length</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">tabu_rules_duration</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">optimizer</span><spanclass="p">:</span><spanclass="n">str</span><spanclass="o">=</span><spanclass="default_value">'tabu'</span></em>, <emclass="sig-param"><spanclass="n">disable_multiprocessing</span><spanclass="p">:</span><spanclass="n">bool</span><spanclass="o">=</span><spanclass="default_value">False</span></em><spanclass="sig-paren">)</span><aclass="headerlink"href="#PyCTBN.PyCTBN.estimators.structure_score_based_estimator.StructureScoreBasedEstimator.estimate_structure"title="Permalink to this definition">¶</a></dt>
<codeclass="sig-name descname">estimate_structure</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">max_parents</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">iterations_number</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">40</span></em>, <emclass="sig-param"><spanclass="n">patience</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">tabu_length</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">tabu_rules_duration</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">optimizer</span><spanclass="p">:</span><spanclass="n">str</span><spanclass="o">=</span><spanclass="default_value">'tabu'</span></em>, <emclass="sig-param"><spanclass="n">disable_multiprocessing</span><spanclass="p">:</span><spanclass="n">bool</span><spanclass="o">=</span><spanclass="default_value">False</span></em>, <emclass="sig-param"><spanclass="n">processes_number</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em><spanclass="sig-paren">)</span><aclass="headerlink"href="#PyCTBN.PyCTBN.estimators.structure_score_based_estimator.StructureScoreBasedEstimator.estimate_structure"title="Permalink to this definition">¶</a></dt>
<dd><p>Compute the score-based algorithm to find the optimal structure</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
@ -735,9 +747,12 @@ using a score based approach and differt kinds of optimization algorithms.</p>
<li><p><strong>tabu_rules_duration</strong> (<em>int</em><em>, </em><em>optional</em>) – number of iterations in which each rule keeps its value, default to None</p></li>
<li><p><strong>optimizer</strong> (<em>string</em><em>, </em><em>optional</em>) – name of the optimizer algorithm. Possible values: ‘hill’ (Hill climbing),’tabu’ (tabu search), defualt to ‘tabu’</p></li>
<li><p><strong>disable_multiprocessing</strong> (<em>Boolean</em><em>, </em><em>optional</em>) – true if you desire to disable the multiprocessing operations, default to False</p></li>
<li><p><strong>processes_number</strong> – if disable_multiprocessing is false indicates</p></li>
</ul>
</dd>
</dl>
<p>the maximum number of process; if None it will be automatically set, default to None
:type processes_number: int, optional</p>
</dd></dl>
<dlclass="py method">
@ -762,11 +777,11 @@ using a score based approach and differt kinds of optimization algorithms.</p>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.PyCTBN.estimators"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-optimizers-constraint-based-optimizer-module"></span><h2>PyCTBN.PyCTBN.optimizers.constraint_based_optimizer module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.optimizers.constraint_based_optimizer"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-optimizers-hill-climbing-search-module"></span><h2>PyCTBN.PyCTBN.optimizers.hill_climbing_search module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.optimizers.hill_climbing_search"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-optimizers-optimizer-module"></span><h2>PyCTBN.PyCTBN.optimizers.optimizer module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.optimizers.optimizer"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-optimizers-tabu-search-module"></span><h2>PyCTBN.PyCTBN.optimizers.tabu_search module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.optimizers.tabu_search"title="Permalink to this headline">¶</a></h2>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.PyCTBN.optimizers"title="Permalink to this headline">¶</a></h2>
<h1>PyCTBN.PyCTBN.structure_graph package<aclass="headerlink"href="#pyctbn-pyctbn-structure-graph-package"title="Permalink to this headline">¶</a></h1>
<divclass="section"id="submodules">
<sectionid="submodules">
<h2>Submodules<aclass="headerlink"href="#submodules"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-structure-graph-conditional-intensity-matrix-module"></span><h2>PyCTBN.PyCTBN.structure_graph.conditional_intensity_matrix module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.structure_graph.conditional_intensity_matrix"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-structure-graph-network-graph-module"></span><h2>PyCTBN.PyCTBN.structure_graph.network_graph module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.structure_graph.network_graph"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-structure-graph-sample-path-module"></span><h2>PyCTBN.PyCTBN.structure_graph.sample_path module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.structure_graph.sample_path"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-structure-graph-set-of-cims-module"></span><h2>PyCTBN.PyCTBN.structure_graph.set_of_cims module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.structure_graph.set_of_cims"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-structure-graph-structure-module"></span><h2>PyCTBN.PyCTBN.structure_graph.structure module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.structure_graph.structure"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-structure-graph-trajectory-module"></span><h2>PyCTBN.PyCTBN.structure_graph.trajectory module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.structure_graph.trajectory"title="Permalink to this headline">¶</a></h2>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.PyCTBN.structure_graph"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-utility-abstract-importer-module"></span><h2>PyCTBN.PyCTBN.utility.abstract_importer module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.utility.abstract_importer"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-utility-cache-module"></span><h2>PyCTBN.PyCTBN.utility.cache module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.utility.cache"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-utility-json-importer-module"></span><h2>PyCTBN.PyCTBN.utility.json_importer module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.utility.json_importer"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-utility-sample-importer-module"></span><h2>PyCTBN.PyCTBN.utility.sample_importer module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.utility.sample_importer"title="Permalink to this headline">¶</a></h2>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.PyCTBN.utility"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-estimators-test-parameters-estimator-module"></span><h2>PyCTBN.tests.estimators.test_parameters_estimator module<aclass="headerlink"href="#module-PyCTBN.tests.estimators.test_parameters_estimator"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-estimators-test-structure-constraint-based-estimator-module"></span><h2>PyCTBN.tests.estimators.test_structure_constraint_based_estimator module<aclass="headerlink"href="#module-PyCTBN.tests.estimators.test_structure_constraint_based_estimator"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-estimators-test-structure-estimator-module"></span><h2>PyCTBN.tests.estimators.test_structure_estimator module<aclass="headerlink"href="#module-PyCTBN.tests.estimators.test_structure_estimator"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-estimators-test-structure-score-based-estimator-module"></span><h2>PyCTBN.tests.estimators.test_structure_score_based_estimator module<aclass="headerlink"href="#module-PyCTBN.tests.estimators.test_structure_score_based_estimator"title="Permalink to this headline">¶</a></h2>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.tests.estimators"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-optimizers-test-hill-climbing-search-module"></span><h2>PyCTBN.tests.optimizers.test_hill_climbing_search module<aclass="headerlink"href="#module-PyCTBN.tests.optimizers.test_hill_climbing_search"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-optimizers-test-tabu-search-module"></span><h2>PyCTBN.tests.optimizers.test_tabu_search module<aclass="headerlink"href="#module-PyCTBN.tests.optimizers.test_tabu_search"title="Permalink to this headline">¶</a></h2>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.tests.optimizers"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-structure-graph-test-cim-module"></span><h2>PyCTBN.tests.structure_graph.test_cim module<aclass="headerlink"href="#module-PyCTBN.tests.structure_graph.test_cim"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-structure-graph-test-networkgraph-module"></span><h2>PyCTBN.tests.structure_graph.test_networkgraph module<aclass="headerlink"href="#module-PyCTBN.tests.structure_graph.test_networkgraph"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-structure-graph-test-sample-path-module"></span><h2>PyCTBN.tests.structure_graph.test_sample_path module<aclass="headerlink"href="#module-PyCTBN.tests.structure_graph.test_sample_path"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-structure-graph-test-setofcims-module"></span><h2>PyCTBN.tests.structure_graph.test_setofcims module<aclass="headerlink"href="#module-PyCTBN.tests.structure_graph.test_setofcims"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-structure-graph-test-structure-module"></span><h2>PyCTBN.tests.structure_graph.test_structure module<aclass="headerlink"href="#module-PyCTBN.tests.structure_graph.test_structure"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-structure-graph-test-trajectory-module"></span><h2>PyCTBN.tests.structure_graph.test_trajectory module<aclass="headerlink"href="#module-PyCTBN.tests.structure_graph.test_trajectory"title="Permalink to this headline">¶</a></h2>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.tests.structure_graph"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-utility-test-cache-module"></span><h2>PyCTBN.tests.utility.test_cache module<aclass="headerlink"href="#module-PyCTBN.tests.utility.test_cache"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-utility-test-json-importer-module"></span><h2>PyCTBN.tests.utility.test_json_importer module<aclass="headerlink"href="#module-PyCTBN.tests.utility.test_json_importer"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-utility-test-sample-importer-module"></span><h2>PyCTBN.tests.utility.test_sample_importer module<aclass="headerlink"href="#module-PyCTBN.tests.utility.test_sample_importer"title="Permalink to this headline">¶</a></h2>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.tests.utility"title="Permalink to this headline">¶</a></h2>
<h2>Implementing your own data importer<aclass="headerlink"href="#implementing-your-own-data-importer"title="Permalink to this headline">¶</a></h2>
<divclass="highlight-python notranslate"><divclass="highlight"><pre><span></span><spanclass="sd">"""This example demonstrates the implementation of a simple data importer the extends the class abstract importer to import data in csv format.</span>
<spanclass="sd">The net in exam has three ternary nodes and no prior net structure.</span>
<spanid="pyctbn-pyctbn-estimators-fam-score-calculator-module"></span><h2>PyCTBN.PyCTBN.estimators.fam_score_calculator module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.estimators.fam_score_calculator"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-estimators-parameters-estimator-module"></span><h2>PyCTBN.PyCTBN.estimators.parameters_estimator module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.estimators.parameters_estimator"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-estimators-structure-constraint-based-estimator-module"></span><h2>PyCTBN.PyCTBN.estimators.structure_constraint_based_estimator module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.estimators.structure_constraint_based_estimator"title="Permalink to this headline">¶</a></h2>
<codeclass="sig-name descname">ctpc_algorithm</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">disable_multiprocessing</span><spanclass="p">:</span><spanclass="n">bool</span><spanclass="o">=</span><spanclass="default_value">False</span></em><spanclass="sig-paren">)</span><aclass="headerlink"href="#PyCTBN.PyCTBN.estimators.structure_constraint_based_estimator.StructureConstraintBasedEstimator.ctpc_algorithm"title="Permalink to this definition">¶</a></dt>
<codeclass="sig-name descname">ctpc_algorithm</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">disable_multiprocessing</span><spanclass="p">:</span><spanclass="n">bool</span><spanclass="o">=</span><spanclass="default_value">False</span></em>, <emclass="sig-param"><spanclass="n">processes_number</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em><spanclass="sig-paren">)</span><aclass="headerlink"href="#PyCTBN.PyCTBN.estimators.structure_constraint_based_estimator.StructureConstraintBasedEstimator.ctpc_algorithm"title="Permalink to this definition">¶</a></dt>
<dd><p>Compute the CTPC algorithm over the entire net.</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>disable_multiprocessing</strong> (<em>Boolean</em><em>, </em><em>optional</em>) – true if you desire to disable the multiprocessing operations, default to False</p></li>
<li><p><strong>processes_number</strong> – if disable_multiprocessing is false indicates</p></li>
</ul>
</dd>
</dl>
<p>the maximum number of process; if None it will be automatically set, default to None
<codeclass="sig-name descname">estimate_structure</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">disable_multiprocessing</span><spanclass="p">:</span><spanclass="n">bool</span><spanclass="o">=</span><spanclass="default_value">False</span></em><spanclass="sig-paren">)</span><aclass="headerlink"href="#PyCTBN.PyCTBN.estimators.structure_constraint_based_estimator.StructureConstraintBasedEstimator.estimate_structure"title="Permalink to this definition">¶</a></dt>
<dd><p>Abstract method to estimate the structure</p>
<codeclass="sig-name descname">estimate_structure</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">disable_multiprocessing</span><spanclass="p">:</span><spanclass="n">bool</span><spanclass="o">=</span><spanclass="default_value">False</span></em>, <emclass="sig-param"><spanclass="n">processes_number</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em><spanclass="sig-paren">)</span><aclass="headerlink"href="#PyCTBN.PyCTBN.estimators.structure_constraint_based_estimator.StructureConstraintBasedEstimator.estimate_structure"title="Permalink to this definition">¶</a></dt>
<dd><p>Compute the constraint-based algorithm to find the optimal structure</p>
<dlclass="field-list simple">
<dtclass="field-odd">Returns</dt>
<ddclass="field-odd"><p>List of estimated edges</p>
</dd>
<dtclass="field-even">Return type</dt>
<ddclass="field-even"><p>Typing.List</p>
<dtclass="field-odd">Parameters</dt>
<ddclass="field-odd"><ulclass="simple">
<li><p><strong>disable_multiprocessing</strong> (<em>Boolean</em><em>, </em><em>optional</em>) – true if you desire to disable the multiprocessing operations, default to False</p></li>
<li><p><strong>processes_number</strong> – if disable_multiprocessing is false indicates</p></li>
</ul>
</dd>
</dl>
<p>the maximum number of process; if None it will be automatically set, default to None
:type processes_number: int, optional</p>
</dd></dl>
<dlclass="py method">
@ -521,8 +533,8 @@ it is performed also the chi_test.</p>
<spanid="pyctbn-pyctbn-estimators-structure-estimator-module"></span><h2>PyCTBN.PyCTBN.estimators.structure_estimator module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.estimators.structure_estimator"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-estimators-structure-score-based-estimator-module"></span><h2>PyCTBN.PyCTBN.estimators.structure_score_based_estimator module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.estimators.structure_score_based_estimator"title="Permalink to this headline">¶</a></h2>
<codeclass="sig-name descname">estimate_structure</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">max_parents</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">iterations_number</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">40</span></em>, <emclass="sig-param"><spanclass="n">patience</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">tabu_length</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">tabu_rules_duration</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">optimizer</span><spanclass="p">:</span><spanclass="n">str</span><spanclass="o">=</span><spanclass="default_value">'tabu'</span></em>, <emclass="sig-param"><spanclass="n">disable_multiprocessing</span><spanclass="p">:</span><spanclass="n">bool</span><spanclass="o">=</span><spanclass="default_value">False</span></em><spanclass="sig-paren">)</span><aclass="headerlink"href="#PyCTBN.PyCTBN.estimators.structure_score_based_estimator.StructureScoreBasedEstimator.estimate_structure"title="Permalink to this definition">¶</a></dt>
<codeclass="sig-name descname">estimate_structure</code><spanclass="sig-paren">(</span><emclass="sig-param"><spanclass="n">max_parents</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">iterations_number</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">40</span></em>, <emclass="sig-param"><spanclass="n">patience</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">tabu_length</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">tabu_rules_duration</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em>, <emclass="sig-param"><spanclass="n">optimizer</span><spanclass="p">:</span><spanclass="n">str</span><spanclass="o">=</span><spanclass="default_value">'tabu'</span></em>, <emclass="sig-param"><spanclass="n">disable_multiprocessing</span><spanclass="p">:</span><spanclass="n">bool</span><spanclass="o">=</span><spanclass="default_value">False</span></em>, <emclass="sig-param"><spanclass="n">processes_number</span><spanclass="p">:</span><spanclass="n">int</span><spanclass="o">=</span><spanclass="default_value">None</span></em><spanclass="sig-paren">)</span><aclass="headerlink"href="#PyCTBN.PyCTBN.estimators.structure_score_based_estimator.StructureScoreBasedEstimator.estimate_structure"title="Permalink to this definition">¶</a></dt>
<dd><p>Compute the score-based algorithm to find the optimal structure</p>
<dlclass="field-list simple">
<dtclass="field-odd">Parameters</dt>
@ -735,9 +747,12 @@ using a score based approach and differt kinds of optimization algorithms.</p>
<li><p><strong>tabu_rules_duration</strong> (<em>int</em><em>, </em><em>optional</em>) – number of iterations in which each rule keeps its value, default to None</p></li>
<li><p><strong>optimizer</strong> (<em>string</em><em>, </em><em>optional</em>) – name of the optimizer algorithm. Possible values: ‘hill’ (Hill climbing),’tabu’ (tabu search), defualt to ‘tabu’</p></li>
<li><p><strong>disable_multiprocessing</strong> (<em>Boolean</em><em>, </em><em>optional</em>) – true if you desire to disable the multiprocessing operations, default to False</p></li>
<li><p><strong>processes_number</strong> – if disable_multiprocessing is false indicates</p></li>
</ul>
</dd>
</dl>
<p>the maximum number of process; if None it will be automatically set, default to None
:type processes_number: int, optional</p>
</dd></dl>
<dlclass="py method">
@ -762,11 +777,11 @@ using a score based approach and differt kinds of optimization algorithms.</p>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.PyCTBN.estimators"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-optimizers-constraint-based-optimizer-module"></span><h2>PyCTBN.PyCTBN.optimizers.constraint_based_optimizer module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.optimizers.constraint_based_optimizer"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-optimizers-hill-climbing-search-module"></span><h2>PyCTBN.PyCTBN.optimizers.hill_climbing_search module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.optimizers.hill_climbing_search"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-optimizers-optimizer-module"></span><h2>PyCTBN.PyCTBN.optimizers.optimizer module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.optimizers.optimizer"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-optimizers-tabu-search-module"></span><h2>PyCTBN.PyCTBN.optimizers.tabu_search module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.optimizers.tabu_search"title="Permalink to this headline">¶</a></h2>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.PyCTBN.optimizers"title="Permalink to this headline">¶</a></h2>
<h1>PyCTBN.PyCTBN.structure_graph package<aclass="headerlink"href="#pyctbn-pyctbn-structure-graph-package"title="Permalink to this headline">¶</a></h1>
<divclass="section"id="submodules">
<sectionid="submodules">
<h2>Submodules<aclass="headerlink"href="#submodules"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-structure-graph-conditional-intensity-matrix-module"></span><h2>PyCTBN.PyCTBN.structure_graph.conditional_intensity_matrix module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.structure_graph.conditional_intensity_matrix"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-structure-graph-network-graph-module"></span><h2>PyCTBN.PyCTBN.structure_graph.network_graph module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.structure_graph.network_graph"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-structure-graph-sample-path-module"></span><h2>PyCTBN.PyCTBN.structure_graph.sample_path module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.structure_graph.sample_path"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-structure-graph-set-of-cims-module"></span><h2>PyCTBN.PyCTBN.structure_graph.set_of_cims module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.structure_graph.set_of_cims"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-structure-graph-structure-module"></span><h2>PyCTBN.PyCTBN.structure_graph.structure module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.structure_graph.structure"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-structure-graph-trajectory-module"></span><h2>PyCTBN.PyCTBN.structure_graph.trajectory module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.structure_graph.trajectory"title="Permalink to this headline">¶</a></h2>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.PyCTBN.structure_graph"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-utility-abstract-importer-module"></span><h2>PyCTBN.PyCTBN.utility.abstract_importer module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.utility.abstract_importer"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-utility-cache-module"></span><h2>PyCTBN.PyCTBN.utility.cache module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.utility.cache"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-utility-json-importer-module"></span><h2>PyCTBN.PyCTBN.utility.json_importer module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.utility.json_importer"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-pyctbn-utility-sample-importer-module"></span><h2>PyCTBN.PyCTBN.utility.sample_importer module<aclass="headerlink"href="#module-PyCTBN.PyCTBN.utility.sample_importer"title="Permalink to this headline">¶</a></h2>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.PyCTBN.utility"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-estimators-test-parameters-estimator-module"></span><h2>PyCTBN.tests.estimators.test_parameters_estimator module<aclass="headerlink"href="#module-PyCTBN.tests.estimators.test_parameters_estimator"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-estimators-test-structure-constraint-based-estimator-module"></span><h2>PyCTBN.tests.estimators.test_structure_constraint_based_estimator module<aclass="headerlink"href="#module-PyCTBN.tests.estimators.test_structure_constraint_based_estimator"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-estimators-test-structure-estimator-module"></span><h2>PyCTBN.tests.estimators.test_structure_estimator module<aclass="headerlink"href="#module-PyCTBN.tests.estimators.test_structure_estimator"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-estimators-test-structure-score-based-estimator-module"></span><h2>PyCTBN.tests.estimators.test_structure_score_based_estimator module<aclass="headerlink"href="#module-PyCTBN.tests.estimators.test_structure_score_based_estimator"title="Permalink to this headline">¶</a></h2>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.tests.estimators"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-optimizers-test-hill-climbing-search-module"></span><h2>PyCTBN.tests.optimizers.test_hill_climbing_search module<aclass="headerlink"href="#module-PyCTBN.tests.optimizers.test_hill_climbing_search"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-optimizers-test-tabu-search-module"></span><h2>PyCTBN.tests.optimizers.test_tabu_search module<aclass="headerlink"href="#module-PyCTBN.tests.optimizers.test_tabu_search"title="Permalink to this headline">¶</a></h2>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.tests.optimizers"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-structure-graph-test-cim-module"></span><h2>PyCTBN.tests.structure_graph.test_cim module<aclass="headerlink"href="#module-PyCTBN.tests.structure_graph.test_cim"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-structure-graph-test-networkgraph-module"></span><h2>PyCTBN.tests.structure_graph.test_networkgraph module<aclass="headerlink"href="#module-PyCTBN.tests.structure_graph.test_networkgraph"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-structure-graph-test-sample-path-module"></span><h2>PyCTBN.tests.structure_graph.test_sample_path module<aclass="headerlink"href="#module-PyCTBN.tests.structure_graph.test_sample_path"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-structure-graph-test-setofcims-module"></span><h2>PyCTBN.tests.structure_graph.test_setofcims module<aclass="headerlink"href="#module-PyCTBN.tests.structure_graph.test_setofcims"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-structure-graph-test-structure-module"></span><h2>PyCTBN.tests.structure_graph.test_structure module<aclass="headerlink"href="#module-PyCTBN.tests.structure_graph.test_structure"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-structure-graph-test-trajectory-module"></span><h2>PyCTBN.tests.structure_graph.test_trajectory module<aclass="headerlink"href="#module-PyCTBN.tests.structure_graph.test_trajectory"title="Permalink to this headline">¶</a></h2>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.tests.structure_graph"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-utility-test-cache-module"></span><h2>PyCTBN.tests.utility.test_cache module<aclass="headerlink"href="#module-PyCTBN.tests.utility.test_cache"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-utility-test-json-importer-module"></span><h2>PyCTBN.tests.utility.test_json_importer module<aclass="headerlink"href="#module-PyCTBN.tests.utility.test_json_importer"title="Permalink to this headline">¶</a></h2>
<spanid="pyctbn-tests-utility-test-sample-importer-module"></span><h2>PyCTBN.tests.utility.test_sample_importer module<aclass="headerlink"href="#module-PyCTBN.tests.utility.test_sample_importer"title="Permalink to this headline">¶</a></h2>
<spanid="module-contents"></span><h2>Module contents<aclass="headerlink"href="#module-PyCTBN.tests.utility"title="Permalink to this headline">¶</a></h2>
<h2>Implementing your own data importer<aclass="headerlink"href="#implementing-your-own-data-importer"title="Permalink to this headline">¶</a></h2>
<divclass="highlight-python notranslate"><divclass="highlight"><pre><span></span><spanclass="sd">"""This example demonstrates the implementation of a simple data importer the extends the class abstract importer to import data in csv format.</span>
<spanclass="sd">The net in exam has three ternary nodes and no prior net structure.</span>