From 6b1ca5d9d9bd0f64dda7a5cdc02d03100caac437 Mon Sep 17 00:00:00 2001 From: troyyyyy <49091847+troyyyyy@users.noreply.github.com> Date: Wed, 7 Dec 2022 13:35:42 +0800 Subject: [PATCH] Fix bugs for non-zoopt option --- abducer/abducer_base.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/abducer/abducer_base.py b/abducer/abducer_base.py index 3dd4822..5060529 100644 --- a/abducer/abducer_base.py +++ b/abducer/abducer_base.py @@ -212,7 +212,7 @@ if __name__ == '__main__': print() kb = HED_prolog_KB() - abd = AbducerBase(kb, zoopt=True, multiple_predictions=True) + abd = AbducerBase(kb, zoopt=False, multiple_predictions=True) consist_exs = [[1, '+', 0, '=', 0], [1, '+', 1, '=', 0], [0, '+', 0, '=', 1, 1]] consist_exs2 = [[1, '+', 0, '=', 0], [1, '+', 1, '=', 0], [0, '+', 1, '=', 1, 1]] # not consistent with rules inconsist_exs = [[1, '+', 0, '=', 0], [1, '=', 1, '=', 0], [0, '=', 0, '=', 1, 1]] @@ -222,9 +222,9 @@ if __name__ == '__main__': print(kb.consist_rule(consist_exs, rules), kb.consist_rule(consist_exs2, rules)) print() - res = abd.abduce((consist_exs, True, None)) + res = abd.abduce((consist_exs, None, True)) print(res) - res = abd.abduce((inconsist_exs, True, None)) + res = abd.abduce((inconsist_exs, None, True)) print(res) print()