return self.file_names[oldnew]
def html_record_string (self, dest_dir):
- self.link_files_for_html (dest_dir)
-
dist = self.distance()
details = self.get_distance_details ()
details_base = os.path.splitext (self.file_names[1])[0]
details_base += '.details.html'
fn = dest_dir + '/' + details_base
- open (fn, 'w').write (details)
+ open_write_file (fn).write (details)
details = '<br>(<a href="%(details_base)s">details</a>)' % locals ()
str += '%-8s: %d\n' % (k, int (self.results[oldnew][k]))
else:
str += '%-8s: %8d (%5.3f)\n' % (k, int (self.results[oldnew][k]),
- self.get_ratio (k))
+ self.get_ratio (k))
return '<pre>%s</pre>' % str
note_info, self.contents[oldnew])
dist = 0.0
- factor = {'time': 1.0 ,
- 'cells': 10.0,
+ factor = {'time': 2.0 ,
+ 'cells': 5.0,
}
for k in ('time', 'cells'):
- dist += math.tan (self.get_ratio (k) /(0.5* math.pi)) * factor[k] - 1
+ real_val = math.tan (self.get_ratio (k) * 0.5* math.pi)
+ dist += math.exp (math.fabs (real_val) * factor[k]) - 1
dist = min (dist, 100)
return dist
j += 1
for e in t:
+ ev_str = repr (e)
+ if re.search ('LilyPond [0-9.]+', ev_str):
+ continue
+
str += ' ev %s\n' % `e`
return str
dest_file = dest_dir + '/index.html'
open_write_file (dest_file).write (html)
+
+
+ for link in changed:
+ link.link_files_for_html (dest_dir)
+
def print_results (self, threshold):
self.write_text_result_page ('', threshold)