ConfigurationΒΆ
Siflex is configured via a JSON file specifying input/output paths and pipeline steps.
π Configuration fileΒΆ
{
"input_files": {
"sif_network": "data/cell_fate_plus.sif",
"node_hgnc_file": "data/NodeHGNC.csv",
"kegg_pathway": "data/kegg_pathway.csv",
"kegg_categories": "data/kegg_categories.json",
"bless_out": "data/tissue_folders",
"inhibitor_profiles": "data/inhibitor_profiles.csv"
},
"output_files": {
"node_scores": "output/node_scores.csv",
"node_scores_agg": "output/node_scores_agg.csv",
"pathway_scores": "output/pathway_scores.csv",
"synergy_scores": "output/synergy_scores.csv",
"node_pathway_index": "output/node_pathway_index.json",
"pathway_catalog": "output/pathway_catalog.json"
},
"steps": {
"calculate_scores": true,
"prepare_scores": true
}
}
π Input data formatsΒΆ
SIF network fileΒΆ
Tab-separated file with three columns:
source_node interaction_type target_node
EGFR activate MAPK1
PI3K inhibit PTEN
ORIS outputΒΆ
Directory structure with tissue folders containing cell line subdirectories:
tissue_folders/
βββ lung/
β βββ A549/
β β βββ Pairwise_comparison.tsv
β βββ H1299/
β βββ Pairwise_comparison.tsv
βββ breast/
βββ MCF7/
βββ Pairwise_comparison.tsv
Node-HGNC mapping (NodeHGNC.csv)ΒΆ
Node,HGNC
EGFR,EGFR
MAPK,MAPK1
KEGG pathway file (kegg_pathway.csv)ΒΆ
pathway_id,pathway_name,gene_symbols
hsa04010,MAPK signaling pathway,"EGFR,MAPK1,RAF1"
ποΈ ArchitectureΒΆ
Siflex follows a modular architecture with clean separation of concerns:
Data Layer (
features/): Data loading, transformation, and score calculationApplication Layer (
apps/): Data preparation functions for each explorerPresentation Layer (
apps/*_dash.py): Dash-based interactive visualisationsOrchestration Layer (
main.py): Pipeline coordination and CLI interface
SIFLEX/
βββ siflex/
β βββ cli.py # Command-line interface
β βββ config.py # Configuration management
β βββ main.py # Pipeline orchestration
β βββ apps/
β β βββ network_explorer.py # Network data preparation
β β βββ network_dash.py # Network visualisation
β β βββ pathway_explorer.py # Pathway data preparation
β β βββ pathway_dash.py # Pathway visualisation
β β βββ app_style.py # Shared styling
β βββ features/
β βββ calculate_scores.py # Score calculation logic
β βββ prepare_scores.py # Data preparation
β βββ data_utils.py # Data loading utilities
βββ tests/
βββ data/
βββ output/
βββ pyproject.toml