Index: /mds-and-trees/tree-genealogy.py
===================================================================
--- /mds-and-trees/tree-genealogy.py	(revision 563)
+++ /mds-and-trees/tree-genealogy.py	(revision 564)
@@ -25,26 +25,43 @@
 
 def svg_generate_line_style(percent):
+    # hotdog
     from_col = [100, 70, 0]
-    to_col = [100, 0, 0]
-    # from_col = [0, 100, 50]
-    # to_col = [20, 0, 100]
-
-    percent = 1 - ((1-percent)**10)
+    to_col = [60, 0, 0]
+    # neon
+    # from_col = [30, 200, 255]
+    # to_col = [240, 0, 220]
+
+    from_opa = 0.2
+    to_opa = 1.0
+    from_stroke = 1
+    to_stroke = 3
+
+    opa = from_opa*(1-percent) + to_opa*percent
+    stroke = from_stroke*(1-percent) + to_stroke*percent
+
+    percent = 1 - ((1-percent)**20)
 
     return 'stroke="rgb(' + str(from_col[0]*(1-percent) + to_col[0]*percent) + '%,' \
            + str(from_col[1]*(1-percent) + to_col[1]*percent) + '%,' \
-           + str(from_col[2]*(1-percent) + to_col[2]*percent) + '%)" stroke-width="1" stroke-opacity="0.8"'
+           + str(from_col[2]*(1-percent) + to_col[2]*percent) + '%)" stroke-width="' + str(stroke) + '" stroke-opacity="' + str(opa) + '"'
 
 def svg_generate_dot_style(percent):
     from_col = [100, 90, 0]
-    to_col = [100, 0, 0]
-    # from_col = [0, 100, 50]
-    # to_col = [20, 0, 100]
-
-    percent = 1 - ((1-percent)**10)
+    to_col = [60, 0, 0]
+    # neon
+    # from_col = [30, 200, 255]
+    # to_col = [240, 0, 220]
+
+    from_opa = 0.2
+    to_opa = 1.0
+
+    opa = from_opa*(1-percent) + to_opa*percent
+
+    percent = 1 - ((1-percent)**20)
 
     return 'fill="rgb(' + str(from_col[0]*(1-percent) + to_col[0]*percent) + '%,' \
            + str(from_col[1]*(1-percent) + to_col[1]*percent) + '%,' \
-           + str(from_col[2]*(1-percent) + to_col[2]*percent) + '%)" r="1.5" stroke="black" stroke-width="0.2"' #fill-opacity="0.5"'
+           + str(from_col[2]*(1-percent) + to_col[2]*percent) + '%)" r="1.5" stroke="black" stroke-width="0.2" fill-opacity="' + str(opa) + '" ' \
+           'stroke-opacity="' + str(opa) + '"'
 
 # -------------------
@@ -60,4 +77,5 @@
                 #print("B" +str(creature))
                 if "FromIDs" in creature:
+                    assert(len(creature["FromIDs"]) == 1)
                     nodes[creature["ID"]] = creature["FromIDs"][0]
                     if not creature["FromIDs"][0] in nodes:
@@ -131,5 +149,5 @@
     for c in inv_nodes[node]:
         #print(node + "->" + c)
-        dissimilarity = random.gauss(0,0.3)
+        dissimilarity = 0.5 #random.gauss(0,0.3)
         if TIME == "REAL":
             id = ""
@@ -165,9 +183,11 @@
         if c in inv_nodes:
             draw_children_recurrent(c, max_depth)
+
+        line_style = (svg_line_style if args.mono_tree else svg_generate_line_style(depth[c]/max_depth))
+        dot_style = (svg_dot_style if args.mono_tree else svg_generate_dot_style(depth[c]/max_depth))
+
         svg_add_line( (w_margin+w_no_margs*(positions[node][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[node][1]/max_height),
-            (w_margin+w_no_margs*(positions[c][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[c][1]/max_height),
-                      (svg_line_style if args.mono_tree else svg_generate_line_style(depth[c]/max_depth)))
-        svg_add_dot( (w_margin+w_no_margs*(positions[c][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[c][1]/max_height),
-                     (svg_dot_style if args.mono_tree else svg_generate_dot_style(depth[c]/max_depth)))
+            (w_margin+w_no_margs*(positions[c][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[c][1]/max_height), line_style)
+        svg_add_dot( (w_margin+w_no_margs*(positions[c][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[c][1]/max_height), dot_style)
 def draw_children():
     max_depth = 0
@@ -175,6 +195,6 @@
             max_depth = max(max_depth, v)
     draw_children_recurrent(firstnode, max_depth)
-    svg_add_dot( (w_margin+w_no_margs*(positions[firstnode][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[firstnode][1]/max_height),
-                 (svg_dot_style if args.mono_tree else svg_generate_dot_style(depth[firstnode]/max_depth)))
+    dot_style = (svg_dot_style if args.mono_tree else svg_generate_dot_style(depth[firstnode]/max_depth))
+    svg_add_dot( (w_margin+w_no_margs*(positions[firstnode][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[firstnode][1]/max_height), dot_style)
 
 def draw_spine_recurrent(node):
@@ -184,6 +204,8 @@
             if c in inv_nodes:
                 draw_spine_recurrent(c)
+
+            line_style = svg_spine_line_style
             svg_add_line( (w_margin+w_no_margs*(positions[node][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[node][1]/max_height),
-                (w_margin+w_no_margs*(positions[c][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[c][1]/max_height), svg_spine_line_style)
+                (w_margin+w_no_margs*(positions[c][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[c][1]/max_height), line_style)
             #svg_add_dot( (w_margin+w_no_margs*(positions[c][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[c][1]/max_height), svg_spine_dot_style)
 def draw_spine():
@@ -197,7 +219,8 @@
             if c in inv_nodes:
                 draw_skeleton_reccurent(c, max_depth)
+
+            line_style = svg_spine_line_style
             svg_add_line( (w_margin+w_no_margs*(positions[node][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[node][1]/max_height),
-                (w_margin+w_no_margs*(positions[c][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[c][1]/max_height),
-                          svg_spine_line_style)
+                (w_margin+w_no_margs*(positions[c][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[c][1]/max_height), line_style)
             #svg_add_dot( (w_margin+w_no_margs*(positions[c][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[c][1]/max_height),
             #             svg_spine_dot_style)
@@ -210,5 +233,4 @@
     #svg_add_dot( (w_margin+w_no_margs*(positions[firstnode][0]-min_width)/(max_width-min_width), h_margin+h_no_margs*positions[firstnode][1]/max_height),
     #             svg_spine_dot_style)
-
 
 
