Tom
unread,Nov 19, 2009, 2:42:35 PM11/19/09Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to PyKE
Hi all,
I'm sure this is a trivial question, so I really appreciate anyone
taking the time to answer it:
I'm trying to use Pyke to solve some taxonomy problems, within the
larger scope of inference.
I created a krb called taxonomy_rules.krb, within a folder called
taxonomy. I wanted to define a function, 'assertfacts', that takes a
rule_base and a particular framework and applies the rules within that
framework. When I try to run the following line by calling that
function:
engine.activate('taxonomy_rules')
I get this:
Traceback (most recent call last):
File "<pyshell#6>", line 1, in <module>
assert_facts()
File "<pyshell#5>", line 2, in assert_facts
engine = knowledge_engine.engine('taxonomy')
File "build\bdist.win32\egg\pyke\knowledge_engine.py", line 77, in
__init__
for path in paths: self._init_path(path, target_pkgs)
File "build\bdist.win32\egg\pyke\knowledge_engine.py", line 163, in
_init_path
target_pkg.import_(target_package_name[:last_dot]) \
File "build\bdist.win32\egg\pyke\target_pkg.py", line 304, in
import_
mod = __import__(modulename)
ImportError: No module named taxonomy
However, if I just try to run "engine.activate('taxonomy_rules')"
within my python IDLE, it works fine. Is there something wrong with
the paths here, and if so, how do I fix it?
Thanks again.