diffseldsparse_benchmark.ml 893 Bytes
Newer Older
1
open Core
Philippe Veber's avatar
Philippe Veber committed
2
open Codepi
3 4

let main ~n_h0 ~n_ha ~seed:i () =
5
  let open Simulation_dataset in
6
  let sim =
Philippe Veber's avatar
Philippe Veber committed
7
    bppseqgen_mixed
Philippe Veber's avatar
Philippe Veber committed
8
      ~tree:(NHX (Bistro.Workflow.input "example/trees_analyses/cyp_coding.Chrysithr_root.nhx"))
9 10
      ~profiles:"example/aa_fitness/263SelectedProfiles.tsv"
      ~n_h0 ~n_ha ~ne_s:4. ~seed:i ()
11 12
  in
  let w = benchmark sim in
Philippe Veber's avatar
Philippe Veber committed
13 14
  Bistro_engine.Scheduler.simple_eval_exn ~np:4 ~mem:(`GB 4) (Bistro.Workflow.path w)
  |> print_endline
15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31

let command =
  let open Command.Let_syntax in
  Command.basic
    ~summary:"Run diffseldsparse bench"
    [%map_open
      let n_ha =
        flag "--n-ha" (required int) ~doc:"INT Number of Ha sites"
      and n_h0 =
        flag "--n-h0" (required int) ~doc:"INT Number of H0 sites"
      and seed =
        flag "--seed" (required int) ~doc:"INT Global seed"
      in
      main ~n_ha ~n_h0 ~seed
    ]

let () = Command.run command