X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fsoftware%2Fcomponents%2Fmetadata%2FmetadataConstraints.ml;h=d7192bd7e75e12c65f1c0d12922ec6e5e3f31673;hb=b3ce13018a7e6230313124ee2428a91ec5109e51;hp=785f73fe4a326aa88b4f63e9ad9399baeeebe7e8;hpb=d78fbf3cface8f01d11f385757cbf47ae1866326;p=helm.git diff --git a/helm/software/components/metadata/metadataConstraints.ml b/helm/software/components/metadata/metadataConstraints.ml index 785f73fe4..d7192bd7e 100644 --- a/helm/software/components/metadata/metadataConstraints.ml +++ b/helm/software/components/metadata/metadataConstraints.ml @@ -546,9 +546,11 @@ let compute_with_only ~(dbd:HMysql.dbd) ?(facts=false) ?(where = `Conclusion) maximal_prefixes) in (* Printf.fprintf stderr "all: %d\n" (List.length all);flush_all (); *) +(* List.filter (function (_,uri) -> - prerr_endline ("W" ^UriManager.string_of_uri uri); - at_most ~dbd ~where constants uri) all + at_most ~dbd ~where constants uri) +*) + all in let equal_to = compute_exactly ~dbd ~facts ~where main prefixes in greater_than @ equal_to @@ -624,8 +626,10 @@ let sigmatch ~(dbd:HMysql.dbd) ?(facts=false) ?(where = `Conclusion) let subsets = power_upto just_factor constants in (* let _ = prerr_endline (("subsets: ")^ (string_of_int (List.length subsets))) in *) - let types_no = List.length types in - List.map (function (n,l) -> (n+types_no,types@l)) subsets + let types_no = List.length types in + if types_no > 0 then + List.map (function (n,l) -> (n+types_no,types@l)) subsets + else subsets in prerr_endline ("critical_value exceded..." ^ string_of_int constants_no); let all_constants = @@ -634,14 +638,16 @@ let sigmatch ~(dbd:HMysql.dbd) ?(facts=false) ?(where = `Conclusion) in compute_with_only ~dbd ~where main subsets all_constants else + (prerr_endline ("all subsets..." ^ string_of_int constants_no); let subsets = let subsets = power constants in let types_no = List.length types in if types_no > 0 then (0,[]) :: List.map (function (n,l) -> (n+types_no,types@l)) subsets else subsets - in - compute_exactly ~dbd ~facts ~where main subsets + in + prerr_endline "fine1"; + compute_exactly ~dbd ~facts ~where main subsets) (* match query wrappers *)