diff --git a/ocaml/Random_variable.ml b/ocaml/Random_variable.ml index b2124a5..2ebbaee 100644 --- a/ocaml/Random_variable.ml +++ b/ocaml/Random_variable.ml @@ -429,7 +429,7 @@ let merge ~create_key ?update_block_id ?update_value ?update_weight t = if (x>y) then 1 else if (x List.rev_map (fun (x,y) -> y) + |> List.rev_map snd |> List.rev } @@ -555,8 +555,9 @@ let ( /! ) = two_variable_operator let compress = merge ~create_key:(fun block -> - Printf.sprintf "%s %10.10d" (Compute_node.to_string block.Block.compute_node) - (((Block_id.to_int block.Block.block_id)+1)/2)) + Printf.sprintf "%s %10.10d %10.10d" + (Compute_node.to_string block.Block.compute_node) block.Block.pid + (((Block_id.to_int block.Block.block_id)+1)/2)) ~update_block_id:(fun block_id -> ((Block_id.to_int block_id)+1)/2 |> Block_id.of_int ) @@ -678,6 +679,7 @@ let compress_files () = | Not_found -> true ) |> List.rev_map (fun x -> dir_name^x) + |> List.rev in let out_channel_dir =