Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
39 changes: 36 additions & 3 deletions evolver.amlg
Original file line number Diff line number Diff line change
Expand Up @@ -365,7 +365,18 @@
(assign (assoc id (first (create_entities id diploid_react_base_template)) ))

;perform mixing
(mix_entities (list diploid "ploid1") (list diploid "ploid2") 0.5 0.5 0.95 (null) 0 (list id "ploid1_temp"))
(mix_entities (list diploid "ploid1") (list diploid "ploid2")
0.5 0.5
{
types_must_match .false
nominal_numbers .false
nominal_strings .false
recursive_matching .true
similar_mix_chance 0.95
unnamed_entity_mix_chance 0
}
(list id "ploid1_temp")
)
(clone_entities haploid (list id "ploid2_temp"))

;mutate
Expand All @@ -379,7 +390,18 @@

;haploid
;use haplodiploidy mechanism to make a haploid (male) from diploid (female)
(let (assoc temp_id (mix_entities (list diploid "ploid1") (list diploid "ploid2") 0.5 0.5 0.95))
(let (assoc temp_id
(mix_entities (list diploid "ploid1") (list diploid "ploid2")
0.5 0.5
{
types_must_match .false
nominal_numbers .false
nominal_strings .false
recursive_matching .true
similar_mix_chance 0.95
}
)
)
(mutate_entity temp_id mutation_rate id mutation_operator_weights mutation_type_weights)
(destroy_entities temp_id)
id
Expand All @@ -401,7 +423,18 @@

(if
(= (call determine_sex (assoc id id1)) (call determine_sex (assoc id id2)))
(mix_entities id1 id2 0.5 0.5 0.5 (null) 0.2 merged_id)
(mix_entities
id1 id2 0.5 0.5
{
types_must_match .false
nominal_numbers .false
nominal_strings .false
recursive_matching .true
similar_mix_chance 0.5
unnamed_entity_mix_chance 0.2
}
merged_id
)

;if different, then can't merge
(null)
Expand Down