.. _structure_learning_algorithms: Algorithms ======================================= .. toctree:: :hidden: :glob: :maxdepth: 1 :name: Structure learning algorithms :caption: Structure learning algorithms structure_learning_algorithms/gcastle_anm structure_learning_algorithms/rblip_asobs structure_learning_algorithms/bdgraph structure_learning_algorithms/tetrad_boss structure_learning_algorithms/gcastle_corl structure_learning_algorithms/athomas_jtsamplers structure_learning_algorithms/corr_thresh structure_learning_algorithms/gcastle_direct_lingam structure_learning_algorithms/dualpc structure_learning_algorithms/tetrad_fas structure_learning_algorithms/tetrad_fask structure_learning_algorithms/tetrad_fges structure_learning_algorithms/tetrad_fofc structure_learning_algorithms/tetrad_ftfc structure_learning_algorithms/bnlearn_fastiamb structure_learning_algorithms/gcastle_gae structure_learning_algorithms/pcalg_gies structure_learning_algorithms/sklearn_glasso structure_learning_algorithms/huge_glasso structure_learning_algorithms/gobnilp structure_learning_algorithms/gcastle_golem structure_learning_algorithms/causallearn_grasp structure_learning_algorithms/tetrad_grasp structure_learning_algorithms/bnlearn_gs structure_learning_algorithms/causaldag_gsp structure_learning_algorithms/grues structure_learning_algorithms/gcastle_grandag structure_learning_algorithms/bnlearn_h2pc structure_learning_algorithms/bnlearn_hc structure_learning_algorithms/bnlearn_hpc structure_learning_algorithms/bnlearn_iamb structure_learning_algorithms/bnlearn_iambfdr structure_learning_algorithms/gcastle_ica_lingam structure_learning_algorithms/tetrad_ica-lingam structure_learning_algorithms/bnlearn_interiamb structure_learning_algorithms/bidag_itsearch structure_learning_algorithms/huge_mb structure_learning_algorithms/gcastle_mcsl structure_learning_algorithms/mice structure_learning_algorithms/bnlearn_mmhc structure_learning_algorithms/bnlearn_mmpc structure_learning_algorithms/mvpc structure_learning_algorithms/causallearn_ges structure_learning_algorithms/gcastle_notears structure_learning_algorithms/gcastle_notears_low_rank structure_learning_algorithms/gcastle_notears_nonlinear structure_learning_algorithms/bidag_order_mcmc structure_learning_algorithms/pcalg_pc structure_learning_algorithms/bnlearn_pcstable structure_learning_algorithms/tetrad_pc structure_learning_algorithms/gcastle_pc structure_learning_algorithms/paralleldg structure_learning_algorithms/trilearn_pgibbs structure_learning_algorithms/bidag_partition_mcmc structure_learning_algorithms/prec_thresh structure_learning_algorithms/equsa_psilearner structure_learning_algorithms/pyagrum structure_learning_algorithms/gcastle_rl structure_learning_algorithms/bnlearn_rsmax2 structure_learning_algorithms/bnlearn_sihitonpc structure_learning_algorithms/huge_tiger structure_learning_algorithms/bips_tpc structure_learning_algorithms/bnlearn_tabu Benchpress provides access to a wide range of open-source packages for causal discovery and structure learning such as `pcalg `__, `BDgraph `__, `gCastle `__, `TETRAD `__, `bnlearn `__, `causal-learn `__, and many others, making it easy to use and compare different algorithms within a unified framework. The algorithms are accesed through their corresponding modules, which are listed below. To use an algorithm module, a section with the corresponding name is simply added to the ``structure_learning_algorithms`` section of the JSON config file. Sample JSON snippets are provided for each module and you may also review :ref:`json_config` to see how it works. The algorithm parameters used in the modules are inherited from the underlying packages as much as possible, maintaining consistency with the original implementations. This means that users familiar with the original packages can easily transfer their knowledge and existing configurations to Benchpress. Users can also refer to the documentation of the underlying packages (linked to in each module) to better understand the parameters and their effects. Apart from the original parameters, each algorithm module is equipped with an additional parameter, ``timeout``, which is the maximum time in seconds allowed for the algorithm to run. After the timeout, the algorithm will be terminated and either an empty file will be created or the current best graph will be saved (if the algorithm supports that). Modules for MCMC algorithms can be used seamlessly with the other modules. However, apart from the original parameters and ``timeout``, these modules have four additional fields: * ``mcmc_seed`` is the random seed for the algorithm. * ``mcmc_estimator`` specifies which estimator to use (*threshold* or *map*). * ``threshold`` specifies the threshold for the posterior edge probabilities if ``mcmc_estimator`` is set to *threshold*. * ``burnin_frac`` is a value in (0, 1) that specifies the fraction of the samples at the beginning of the graph trajectory to be discarded as burn-in. .. list-table:: :class: sphinx-datatable :header-rows: 1 * - Algorithm - Package - Graph - Data - MCMC - Edge constraints - Data missingness - Intervention type * - :ref:`ANMNonlinear ` - `gCastle `__ - `DAG `__ - C, D - - - - * - :ref:`ASOBS ` - `r.blip `__ - `DAG `__ - D - - - - * - :ref:`BDgraph ` - `BDgraph `__ - `UG `__ - C, D, M - Yes - - `MCAR `__ - * - :ref:`BOSS ` - `TETRAD `__ - `CPDAG `__ - C, D - - :ref:`Yes ` - - * - :ref:`Chordal graph samplers ` - `A. Thomas `__ - `DG `__ - C, D - Yes - - - * - :ref:`Corrmat thresh ` - `Benchpress `__ - `UG `__ - C - - - - * - :ref:`Direct LINGAM ` - `gCastle `__ - `DAG `__ - C - - - - * - :ref:`Dual PC ` - `dualPC `__ - `CG `__, `CPDAG `__ - C - - - - * - :ref:`FASK ` - `TETRAD `__ - `DAG `__ - C, D - - :ref:`Yes ` - - * - :ref:`FGES ` - `TETRAD `__ - `CPDAG `__ - C, D - - :ref:`Yes ` - - * - :ref:`FOFC ` - `TETRAD `__ - `DAG `__ - C, D - - :ref:`Yes ` - - * - :ref:`FTFC ` - `TETRAD `__ - `DAG `__ - C, D - - :ref:`Yes ` - - * - :ref:`Fast IAMB ` - `bnlearn `__ - `DAG `__ - C, D, M - - :ref:`Yes ` - - * - :ref:`GAE ` - `gCastle `__ - `DAG `__ - C - - - - * - :ref:`GIES ` - `pcalg `__ - `CPDAG `__ - C - - :ref:`Yes ` - - hard * - :ref:`GLasso ` - `scikit-learn `__ - `UG `__ - C - - - - * - :ref:`GLasso ` - `huge `__ - `UG `__ - C - - - - * - :ref:`GOBNILP ` - `GOBNILP `__ - `DAG `__ - C, D - - :ref:`Yes ` - - * - :ref:`GOLEM ` - `gCastle `__ - `DAG `__ - C - - - - * - :ref:`GRaSP ` - `causal-learn `__ - `CPDAG `__ - C, D - - - - * - :ref:`GRaSP ` - `TETRAD `__ - `CPDAG `__ - C, D - - :ref:`Yes ` - - * - :ref:`GS ` - `bnlearn `__ - `DAG `__ - C, D, M - - :ref:`Yes ` - - * - :ref:`GSP ` - `CausalDAG `__ - `DAG `__ - C - - - - * - :ref:`GrUES ` - `gues `__ - `UDG `__ - C - Yes - - - * - :ref:`GraNDAG ` - `gCastle `__ - `DAG `__ - C - - - - * - :ref:`H2PC ` - `bnlearn `__ - `DAG `__ - C, D, M - - :ref:`Yes ` - - * - :ref:`HC ` - `bnlearn `__ - `DAG `__ - C, D, M - - :ref:`Yes ` - - * - :ref:`HPC ` - `bnlearn `__ - `DAG `__ - C, D, M - - :ref:`Yes ` - - * - :ref:`IAMB ` - `bnlearn `__ - `DAG `__ - C, D, M - - :ref:`Yes ` - - * - :ref:`IAMB-FDR ` - `bnlearn `__ - `DAG `__ - C, D, M - - :ref:`Yes ` - - * - :ref:`ICA-LiNGAM ` - `gCastle `__ - `DAG `__ - C - - - - * - :ref:`ICA-LiNGAM ` - `TETRAD `__ - `DAG `__ - C - - :ref:`Yes ` - - * - :ref:`INTER-IAMB ` - `bnlearn `__ - `DAG `__ - C, D, M - - :ref:`Yes ` - - * - :ref:`Iterative MCMC ` - `BiDAG `__ - `DAG `__, `CPDAG `__ - C, D - Yes - :ref:`Yes ` - - * - :ref:`M&B cov est ` - `huge `__ - `UG `__ - C - - - - * - :ref:`MCSL ` - `gCastle `__ - `DAG `__ - C - - - - * - :ref:`MICE ` - `mice `__ - - C, D, M - - - - * - :ref:`MMHC ` - `bnlearn `__ - `DAG `__ - C, D, M - - :ref:`Yes ` - - * - :ref:`MMPC ` - `bnlearn `__ - `DAG `__ - C, D, M - - :ref:`Yes ` - - * - :ref:`MVPC ` - `MVPC `__ - `CPDAG `__ - C, D - - :ref:`Yes ` - `MAR `__, `MNAR `__, `MCAR `__ - * - :ref:`NO TEARS ` - `gCastle `__ - `DAG `__ - C - - - - * - :ref:`NO TEARS low rank ` - `gCastle `__ - `DAG `__ - C - - - - * - :ref:`NO TEARS non-linear ` - `gCastle `__ - `DAG `__ - C - - - - * - :ref:`Order MCMC ` - `BiDAG `__ - `DAG `__, `CPDAG `__ - C, D - Yes - :ref:`Yes ` - - * - :ref:`PC ` - `pcalg `__ - `CPDAG `__, `CG `__ - C, D - - :ref:`Yes ` - - * - :ref:`PC ` - `bnlearn `__ - `DAG `__ - C, D, M - - :ref:`Yes ` - - * - :ref:`PC ` - `TETRAD `__ - `DAG `__ - C, D, M - - :ref:`Yes ` - - * - :ref:`PC ` - `gCastle `__ - `DAG `__ - C - - - - * - :ref:`Parallel DG ` - `parallelDG `__ - `DG `__ - C, D - Yes - - - * - :ref:`Particle Gibbs ` - `trilearn `__ - `DG `__ - C, D - Yes - - - * - :ref:`Partition MCMC ` - `BiDAG `__ - `DAG `__, `CPDAG `__ - C, D - Yes - :ref:`Yes ` - - * - :ref:`Precmat thresh ` - `Benchpress `__ - `UG `__ - C - - - - * - :ref:`Psi-learning ` - `equSA `__ - `UG `__ - C - - - - * - :ref:`PyAgrum ` - `pyagrum `__ - `DAG `__ - B - - - - * - :ref:`RSMAX2 ` - `bnlearn `__ - `DAG `__ - C, D, M - - :ref:`Yes ` - - * - :ref:`S-I HITON-PC ` - `bnlearn `__ - `DAG `__ - C, D, M - - :ref:`Yes ` - - * - :ref:`TIGER ` - `huge `__ - `UG `__ - C - - - - * - :ref:`TPC ` - `tpc `__ - `CPDAG `__, `MPDAG `__, `TMPDAG `__ - C, D, M - - :ref:`Yes ` - `MAR `__, `MNAR `__, `MCAR `__ - * - :ref:`Tabu ` - `bnlearn `__ - `DAG `__ - C, D, M - - :ref:`Yes ` - -