sruthirameshv / aima-python Goto Github PK
View Code? Open in Web Editor NEWAutomatically exported from code.google.com/p/aima-python
Automatically exported from code.google.com/p/aima-python
If I try to run the tests
$ python doctests.py -v *.py
some fail because they can't find the data directory or the files in it.
These are the lines that originate the problems:
search.py:
BoggleFinder.wordlist = Wordlist("../data/wordlist")
(should be EN-text/wordlist)
text.py:
mandir = '../data/man/'
(should be MAN)
flatland = DataFile("flat11.txt").read() # there are two of these!
(should be EN-text/flatland.txt)
Finally, after replacing all the "../data/" with my "../aima-data/"
(checked out from the SVN repository), the tests were all successful (apart
from the one I mentioned in the other report).
--
Now I'll get back to try to understand the code, which is obviously much
more interesting. :-)
Thanks for releasing these programs with a free license, they're very
useful educational tools.
Best regards,
Matteo
Original issue reported on code.google.com by [email protected]
on 1 Oct 2007 at 3:04
Need to implement the missing algorithms.
Original issue reported on code.google.com by [email protected]
on 15 Jun 2007 at 7:39
What steps will reproduce the problem?
1. call random_player(game,state) in games.py
2.
3.
What is the expected output? What do you see instead?
Expected: A valid move returned
Unexpected Outcome:
Traceback (most recent call last):
File "<pyshell#28>", line 1, in <module>
games.random_player(game,gamestate)
File "/aima-python-read-only/games.py", line 121, in random_player
return random.choice(game.legal_moves(state))
TypeError: legal_moves() takes exactly 2 arguments (1 given)
What version of the product are you using? On what operating system?
Py 2.5.2 /linux latest aima code from svn
Please provide any additional information below.
To fix change line 121
from:
return random.choice(game.legal_moves())
to:
return random.choice(game.legal_moves(state))
Original issue reported on code.google.com by [email protected]
on 30 Jun 2008 at 1:55
Examples are checked via: map(self.check_example, self.examples).
self.check_example makes reference to self.attrs and self.attrnames, both
of which have not been initialized prior to making the map call.
Moving the map call to the end of the constructor fixes the problem.
Original issue reported on code.google.com by [email protected]
on 6 Dec 2007 at 1:52
I was playing with the Criminal(West) example and the new fol_bc_ask()
stuff, couldn't get it to work unless I changed conjuncts() as follows:
def conjuncts(s):
if isinstance(s, Expr) and s.op == '&':
r = []
for arg in s.args:
r.extend (conjuncts (arg))
return r
else:
return [s]
Without this change, conjuncts() will do this:
>>> conjuncts (sar.args[0])
[((American(v_1) & Weapon(v_2)) & Sells(v_1, v_2, v_3)), Hostile(v_3)]
Original issue reported on code.google.com by [email protected]
on 2 Mar 2009 at 6:53
What steps will reproduce the problem?
1. Open file: http://aima.cs.berkeley.edu/python/csp.py
2. Look at data for NY: "NY: VT MA CA NJ"
3. Notice that the third neighbor should be CT, not CA
What is the expected output? What do you see instead?
As above.
What version of the product are you using? On what operating system?
Latest from web.
Please provide any additional information below.
N/A
Original issue reported on code.google.com by [email protected]
on 12 Nov 2007 at 9:47
What steps will reproduce the problem?
1. python doctests.py -v *.py
What is the expected output? What do you see instead?
Traceback (most recent call last):
File "doctests.py", line 42, in <module>
for name in sys.argv if name != "-v"]
ImportError: No module named *
What version of the product are you using? On what operating system?
python 2.5
OS: windows xp
Please provide any additional information below.
Original issue reported on code.google.com by [email protected]
on 18 Oct 2007 at 1:30
What steps will reproduce the problem?
1. $ cd aima-python
2. $ python
3. >>> import agents
4. >>> v = VacuumEnvironment()
5. >>> e = EnvGUI(v)
What is the expected output?
Some Tkinkter window with the Environment
What do you see instead?
An empty Tkinkter window and an error message at the repl:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Users/rickard/devel/ArtificialIntelligence/aima/aima-python/agents.py", line 617, in
__init__
canvas = EnvCanvas(self, env, cellwidth, n)
NameError: global name 'EnvCanvas' is not defined
What version of the product are you using? On what operating system?
Svn revision 29 from Google Code on Mac OS X 10.4.11
Please provide any additional information below.
The commentary at the top of the agents.py file mentions the EnvCanvas class
but the file
doesn't contain a definition of it. Perhaps it is left as an excercise for the
reader.. :-)
Original issue reported on code.google.com by [email protected]
on 29 Jan 2008 at 1:57
The constructor param "udpate_state" should be "update_state".
Original issue reported on code.google.com by [email protected]
on 17 Sep 2008 at 4:41
1) What steps will reproduce the problem?
$ python2.4 doctests.py -v utils.py
or
$ python2.5 doctests.py -v utils.py
2) What is the expected output? What do you see instead?
Failed example:
histogram(vals, 1)
Expected:
[(200, 3), (110, 2), (160, 2), (220, 1), (100, 1)]
Got:
[(200, 3), (160, 2), (110, 2), (100, 1), (220, 1)]
3) What version of the product are you using? On what operating system?
* Code from SVN repository.
* Debian GNU/Linux (Sid, up-to-date).
4) Please provide any additional information below.
It looks like python's sorted in 2.4 or 2.5 doesn't work exactly as the one
supplied (but I can't try that because I haven't got 2.3, and on 2.4 it
doesn't work).
I'm sure this is not a bug, but maybe you're interested in having
successful tests also on python >= 2.4.
Sorry for such a useless report, otherwise. :-)
Original issue reported on code.google.com by [email protected]
on 1 Oct 2007 at 2:23
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.