Commit 1df3c58e authored by Carine Rey's avatar Carine Rey
Browse files

add pcoc_C60 as detection method

parent 4d0b124f
......@@ -8,6 +8,7 @@ open Defs
type result = [
| `Pcoc of [`pcoc] directory workflow
| `Pcoc_gamma of [`pcoc] directory workflow
| `Pcoc_C60 of [`pcoc] directory workflow
| `Diffsel of [`diffsel] directory workflow
| `Diffsel_bis of [`diffsel] directory workflow
| `Identical_LG of [`identical] directory workflow
......@@ -20,6 +21,7 @@ type result = [
let meth_string_of_result = function
| `Pcoc _ -> "pcoc"
| `Pcoc_gamma _ -> "pcoc_gamma"
| `Pcoc_C60 _ -> "pcoc_gamma"
| `Diffsel _ -> "diffsel"
| `Diffsel_bis _ -> "diffsel_bis"
| `Identical_LG _ -> "identical_LG"
......@@ -42,6 +44,7 @@ let merge_results ~res_by_tools : text_file workflow =
let w = match res with
| `Pcoc d -> Pcoc.results d
| `Pcoc_gamma d -> Pcoc.results d
| `Pcoc_C60 d -> Pcoc.results d
| `Diffsel d -> Diffsel.selector d
| `Diffsel_bis d -> Diffsel.selector d
| `Identical_LG d -> Identical.results d
......@@ -53,6 +56,7 @@ let merge_results ~res_by_tools : text_file workflow =
let opt = match res with
| `Pcoc _ -> string "--pcoc"
| `Pcoc_gamma _ -> string "--pcoc_gamma"
| `Pcoc_C60 _ -> string "--pcoc_C60"
| `Diffsel _ -> string "--diffsel"
| `Diffsel_bis _ -> string "--diffsel_bis"
| `Identical_LG _ -> string "--identical_LG"
......@@ -81,6 +85,7 @@ let plot_merge_results ~plot_all_sites ~(res_by_tools:result list) ~tree ~faa ~t
let opt = match res with
| `Pcoc _ -> "PCOC,PC,OC"
| `Pcoc_gamma _ -> "PCOC_gamma,PC_gamma,OC_gamma,"
| `Pcoc_C60 _ -> "PCOC_C60,PC_C60,OC_C60,"
| `Diffsel _ -> "Diffsel_mean,Diffsel_max"
| `Diffsel_bis _ -> "Diffsel_bis_mean,Diffsel_bis_max"
| `Identical_LG _ -> "Identical_LG08"
......@@ -94,8 +99,9 @@ let plot_merge_results ~plot_all_sites ~(res_by_tools:result list) ~tree ~faa ~t
in
let meths_t = List.map res_by_tools ~f:(fun res ->
let opt = match res with
| `Pcoc _ -> "PCOC:0.99"
| `Pcoc_gamma _ -> "PCOC_gamma:0.99"
| `Pcoc _ -> "PCOC:0.99,PC:0.99,OC:0.99"
| `Pcoc_gamma _ -> "PCOC_gamma:0.99,PC_gamma:0.99,OC_gamma:0.99"
| `Pcoc_C60 _ -> "PCOC_C60:0.99,PC_C60:0.99,OC_C60:0.99"
| `Diffsel _ -> "Diffsel_mean:0.11,Diffsel_max:0.9"
| `Diffsel_bis _ -> "Diffsel_bis_mean:0.11,Diffsel_bis_max:0.9"
| `Identical_LG _ -> "Identical_LG08:0.9"
......
......@@ -9,6 +9,7 @@ open Defs
type result = [
| `Pcoc of [`pcoc] directory workflow
| `Pcoc_gamma of [`pcoc] directory workflow
| `Pcoc_C60 of [`pcoc] directory workflow
| `Diffsel of [`diffsel] directory workflow
| `Diffsel_bis of [`diffsel] directory workflow
| `Identical_LG of [`identical] directory workflow
......
......@@ -117,6 +117,7 @@ let repo_of_detection_result res =
match res with
| `Pcoc w -> item ["pcoc.results.tsv"] (Pcoc.results w)
| `Pcoc_gamma w -> item ["pcoc_gamma.results.tsv"] (Pcoc.results w)
| `Pcoc_C60 w -> item ["pcoc_C60.results.tsv"] (Pcoc.results w)
| `Diffsel w -> item ["diffsel.results.tsv"] (Diffsel.selector w)
| `Diffsel_bis w -> item ["diffsel_bis.results.tsv"] (Diffsel.selector w)
| `Identical_LG w -> item ["Identical_LG.results.tsv"] (Identical.results w)
......@@ -129,6 +130,7 @@ let repo_of_detection_result res =
match res with
| `Pcoc w -> item ["raw_results"] w
| `Pcoc_gamma w -> item ["raw_results"] w
| `Pcoc_C60 w -> item ["raw_results"] w
| `Diffsel w -> item ["raw_results"] w
| `Diffsel_bis w -> item ["raw_results"] w
| `Identical_LG w -> item ["raw_results"] w
......@@ -172,6 +174,7 @@ let derive_from_det_meth ~det_meth ~(dataset : Dataset.t) ~preview =
match det_meth with
| `Pcoc -> `Pcoc (Pcoc.pcoc ~catx_est:10 ~plot_complete:true ~gamma:false ~faa ~tree:tree_sc)
| `Pcoc_gamma -> `Pcoc_gamma (Pcoc.pcoc ~catx_est:10 ~plot_complete: true ~gamma:true ~faa ~tree:tree_sc)
| `Pcoc_C60 -> `Pcoc_gamma (Pcoc.pcoc ~catx_est:60 ~plot_complete: true ~gamma:false ~faa ~tree:tree_sc)
| `Tdg09 -> `Tdg09 (Tamuri.tdg09 ~faa ~tree:tree_sc)
| `Diffsel -> `Diffsel (Diffsel.diffsel ~phy_n ~tree:diffsel_tree ~w_every ~n_cycles ~id:1)
| `Diffsel_bis -> `Diffsel_bis (Diffsel.diffsel ~phy_n ~tree:diffsel_tree ~w_every ~n_cycles ~id:2)
......@@ -183,10 +186,18 @@ let derive_from_det_meth ~det_meth ~(dataset : Dataset.t) ~preview =
let derive_from_dataset ~dataset ~preview ~no_diffsel=
let det_meths = [
[`Pcoc;`Pcoc_gamma;
[`Pcoc;
`Tdg09;
`Identical_LG;`Identical_WAG;
`Topological_LG;`Topological_WAG] ;
`Identical_LG;
`Topological_LG;] ;
if preview then
[]
else
[`Pcoc_gamma;`Pcoc_C60;
`Identical_WAG;
`Topological_WAG;
]
;
if no_diffsel then
[]
else
......
......@@ -54,6 +54,8 @@ availableOptions.add_argument('--pcoc', type=str,
help="Pcoc output name", default = None)
availableOptions.add_argument('--pcoc_gamma', type=str,
help="Pcoc_gamma output name", default = None)
availableOptions.add_argument('--pcoc_C60', type=str,
help="Pcoc_C60 output name", default = None)
availableOptions.add_argument('--diffsel', type=str,
help="Diffsel output name", default = None)
availableOptions.add_argument('--diffsel_bis', type=str,
......@@ -77,6 +79,7 @@ args = parser.parse_args()
df_pcoc = pd.DataFrame()
df_pcoc_gamma = pd.DataFrame()
df_pcoc_C60 = pd.DataFrame()
df_diffsel = pd.DataFrame()
df_diffsel_bis = pd.DataFrame()
df_identical_LG = pd.DataFrame()
......@@ -94,7 +97,13 @@ if args.pcoc_gamma :
df_pcoc_gamma = df_pcoc_gamma[['Sites','PCOC','PC','OC']]
df_pcoc_gamma.rename(columns={'PCOC': 'PCOC_gamma',
'PC': 'PC_gamma',
'OC': 'OC_gamma'}, inplace=True)
'OC': 'OC_C60'}, inplace=True)
if args.pcoc_C60 :
df_pcoc_C60 = pd.read_csv(args.pcoc_C60, sep="\t")
df_pcoc_C60 = df_pcoc_C60[['Sites','PCOC','PC','OC']]
df_pcoc_C60.rename(columns={'PCOC': 'PCOC_C60',
'PC': 'PC_C60',
'OC': 'OC_C60'}, inplace=True)
if args.diffsel_bis :
df_diffsel_bis = pd.read_csv(args.diffsel_bis, sep="\t")
df_diffsel_bis = df_diffsel_bis[['Sites','Diffsel_mean','Diffsel_max']]
......@@ -126,7 +135,7 @@ if args.tdg09 :
df_tdg09 = pd.read_csv(args.tdg09, sep="\t")
df_list = [df for df in [df_pcoc, df_pcoc_gamma,
df_list = [df for df in [df_pcoc, df_pcoc_gamma, df_pcoc_C60,
df_diffsel, df_diffsel_bis,
df_identical_LG, df_identical_WAG,
df_topological_LG, df_topological_WAG,
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment