77from .utils import *
88
99def main ():
10- parser = argparse .ArgumentParser (prog = 'cefcon ' , formatter_class = argparse .ArgumentDefaultsHelpFormatter )
10+ parser = argparse .ArgumentParser (prog = 'CEFCON ' , formatter_class = argparse .ArgumentDefaultsHelpFormatter )
1111 parser = add_main_args (parser )
1212 args = parser .parse_args ()
1313
@@ -51,11 +51,18 @@ def main():
5151 print ('Identifying driver regulators...' )
5252 critical_genes , out_critical_genes , in_critical_genes = highly_weighted_genes (gene_influence_scores ,
5353 topK = args .topK_drivers )
54- cellFate_drivers_set , MDS_driver_set , MFVS_driver_set , _ = driver_regulators (G_predicted ,
54+ cellFate_drivers_set , MDS_driver_set , MFVS_driver_set , a = driver_regulators (G_predicted ,
5555 gene_influence_scores ,
5656 topK = args .topK_drivers ,
5757 driver_union = True ,
5858 plot_Venn = False )
59+ ### Temp for Case analysis
60+ import pickle
61+ DriverSet = {'N_genes' :data .n_vars , 'MDS' :MDS_driver_set , 'MFVS' :MFVS_driver_set , 'Critical' :a }
62+ DriverSet_file = open (fspath (p / 'DriverSet.pkl' ), 'wb' )
63+ pickle .dump (DriverSet , DriverSet_file )
64+ DriverSet_file .close ()
65+ ###
5966
6067 # Driver genes ranking save to file
6168 drivers_results = gene_influence_scores .loc [gene_influence_scores .index .isin (list (cellFate_drivers_set )), :].copy ()
@@ -85,15 +92,15 @@ def add_main_args(parser: argparse.ArgumentParser):
8592 # Input data
8693 input_parser = parser .add_argument_group (title = 'Input data options' )
8794 input_parser .add_argument ('--input_expData' , type = str , required = True , metavar = 'PATH' ,
88- help = 'input expression data file ' )
95+ help = 'path to the input gene expression data' )
8996 input_parser .add_argument ('--input_priorNet' , type = str , required = True , metavar = 'PATH' ,
90- help = 'input prior network file ' )
97+ help = 'path to the input prior gene interaction network ' )
9198 input_parser .add_argument ('--input_genesDE' , type = str , default = None , metavar = 'PATH' ,
92- help = 'input differential expression score file ' )
99+ help = 'path to the input gene differential expression score' )
93100 input_parser .add_argument ('--TFs' , type = str , default = None , metavar = 'PATH' ,
94- help = 'input transcriptional factors list' )
101+ help = 'path to the input transcriptional factors list' )
95102 input_parser .add_argument ('--additional_edges_pct' , type = float , default = 0.01 ,
96- help = 'percentage of additional interactions with highly co-expressions ' )
103+ help = 'proportion of high co-expression interactions to be added ' )
97104
98105 # GRN
99106 grn_parser = parser .add_argument_group (title = 'Cell-lineage-specific GRN construction options' )
@@ -109,7 +116,7 @@ def add_main_args(parser: argparse.ArgumentParser):
109116 grn_parser .add_argument ("--heads" , type = int , default = 4 ,
110117 help = "number of heads" )
111118 grn_parser .add_argument ("--attention" , type = str , default = 'COS' , choices = ['COS' , 'AD' , 'SD' ],
112- help = "type of attention function" )
119+ help = "type of attention scoring function" )
113120 grn_parser .add_argument ('--miu' , type = float , default = 0.5 ,
114121 help = 'parameter for considering the importance of attention coefficients of the first GNN layer' )
115122 grn_parser .add_argument ('--epochs' , type = int , default = 350 ,
@@ -125,7 +132,7 @@ def add_main_args(parser: argparse.ArgumentParser):
125132 # Driver regulators
126133 driver_parser = parser .add_argument_group (title = 'Driver regulator identification options' )
127134 driver_parser .add_argument ('--topK_drivers' , type = int , default = 50 ,
128- help = "number of candidate drivers genes according to the influence score " )
135+ help = "number of top-ranked candidate driver genes according to their influence scores " )
129136
130137 # Output dir
131138 parser .add_argument ("--out_dir" , type = str , required = True , default = './output' ,
0 commit comments