Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Open sidebar
VEBER Philippe
codepi
Commits
692a9283
Commit
692a9283
authored
Sep 04, 2018
by
LANORE Vincent
Browse files
Now computing add_indel seed from global dataset seed.
parent
66dbf3dc
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
9 additions
and
7 deletions
+9
-7
lib/dataset.ml
lib/dataset.ml
+8
-6
lib/ready_dataset.ml
lib/ready_dataset.ml
+1
-1
No files found.
lib/dataset.ml
View file @
692a9283
...
...
@@ -30,5 +30,7 @@ let add_indels_to_dataset d ~seed =
let
model_prefix
=
sprintf
"%s_0.33_i"
d
.
model_prefix
in
let
tree_prefix
=
d
.
tree_prefix
in
let
is_real
=
d
.
is_real
in
let
dataset
=
Ready_dataset
.
add_indels_to_ready_dataset
~
p
~
seed
d
.
dataset
in
{
model_prefix
;
tree_prefix
;
is_real
;
dataset
;
seed
=
Hashtbl
.
hash
d
.
seed
}
let
new_seed
=
Hashtbl
.
hash
seed
in
let
indel_seed
=
Hashtbl
.
hash
new_seed
in
let
dataset
=
Ready_dataset
.
add_indels_to_ready_dataset
~
p
~
seed
:
indel_seed
d
.
dataset
in
{
model_prefix
;
tree_prefix
;
is_real
;
dataset
;
seed
=
new_seed
}
lib/ready_dataset.ml
View file @
692a9283
...
...
@@ -86,7 +86,7 @@ let add_indels_to_fna ~(p:float) ~(seed:int) (fna:nucleotide_fasta workflow) : n
let
add_indels_to_ready_dataset
~
p
~
seed
d
=
let
r_d
=
to_raw
d
in
(* VL: one seed per fna. FIXME:should be computed from global seed and task info instead *)
let
fna
=
add_indels_to_fna
~
p
~
seed
:
(
Random
.
int
Int
.
max_value
)
r_d
.
fna
in
let
fna
=
add_indels_to_fna
~
p
~
seed
r_d
.
fna
in
let
fna_infos
=
r_d
.
fna_infos
in
let
ready_dataset
=
of_raw
{
Raw_dataset
.
input_tree
=
r_d
.
input_tree
;
fna
;
fna_infos
}
in
ready_dataset
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment