Printf.eprintf "Finding min occurences : ";
time
( List.fold_left (fun ((min_occ,kind)as acc) (tag,_) ->
- let numtags = Tree.subtree_tags v tag in
+ let numtags = Tree.subtree_tags v tag Tree.root in
if ((numtags < min_occ) && numtags >= 2)
then (numtags,`TAG(tag))
else acc) jump_to) ltags
(if !Options.count_only then "(counting only)" else if !Options.backward then "(bottomup)" else "");
begin
let _ = Gc.full_major();Gc.compact() in
+ let _ = Printf.eprintf "%!" in
(* let _ = Gc.set (disabled_gc) in *)
if !Options.backward && ((snd test_list) != `NOTHING )then
let oc = open_out f in
output_string oc "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n";
IdSet.iter (fun t ->
- Tree.print_xml_fast oc t;
+ Tree.print_xml_fast oc v t;
output_char oc '\n';
- output_string oc "----------\n";
+
) result) ();
end;
end;
begin
Printf.eprintf "Loading from file : ";
time (Tree.load ~sample:!Options.sample_factor )
- (Filename.chop_suffix !Options.input_file ".srx");
+ !Options.input_file;
end
else
let v =