Closed tpacker closed 5 years ago
I should have mentioned that the compound queries didn't work when I used J-MLNs engine. It does seem to work when I use PyMLNs engine.
That's the expected behaviour. Formula queries and parameters like "debug=True" will only work with PyMLNs. I have updated the tutorial page to name the engine to apply.
As far as pymlns_example.py
is concerned, the way the inference results were read could not generalise to queries that require grounding. With commit e807e0777e452dcfa083dcd65562b1db7ebac893 , I have now changed it to use a different mechanism that does generalise.
Thanks
I recently set up ProbCod on a MacBook using Anaconda in order to run it in an environment with Python 2.7 (I usually use Python 3).
When I run the MLN Query Tool and give it a query containing
^
orv
such asSmokes(Ann) ^ Smokes(Bob)
while running through the tutorial at https://github.com/opcode81/ProbCog/wiki/MLN-Tutorial, I always get no results and a message: "Warning: None of the queries could be matched to a variable." This doesn't seem to be expected behavior, given the tutorial. I would like to try queries with conjunctions.Also, adding parameter "debug=True" doesn't seem to do anything.
I can get some output for compound queries if I issue the query in the Python script
python pymlns_example.py
. In this case, I wonder why, when I issue a query with variables inside predicates (instead of ground formulas), it only seems to return the first results. If I turn on Verbose outputresults = mrf.inferMCSAT(queries, verbose=True)
I can see that it has calculated all the values I was looking for.