Skip to content

Added some tests in test_learning.py #293

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
May 31, 2017
Merged

Conversation

agarwl
Copy link

@agarwl agarwl commented Mar 1, 2017

Added tests for the error functions in learning.py as required by #286 .
@reachtarunhere, What kind of other tests can be added?

@@ -12,3 +12,31 @@ def test_weighted_mode():

def test_weighted_replicate():
assert weighted_replicate('ABC', [1, 2, 1], 4) == ['A', 'B', 'B', 'C']

Copy link
Contributor

@sampadsaha5 sampadsaha5 Mar 1, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I really appreciate your work. There is just a small mistake.
You are required to import rms_error(), manhattan_distance(), mean_boolean_error() and mean_error() from learning.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done!

@norvig
Copy link
Collaborator

norvig commented Mar 3, 2017

Now there is a conflict in learning.py

@agarwl
Copy link
Author

agarwl commented Mar 3, 2017

Actually I have already resolved the issue #295 in this pull request in addition to adding the tests. I referenced that commit in the issue too.

@vidursatija
Copy link
Contributor

I didn't know you resolved the issue #295 in your pull request. I independently resolved it. Sorry for any inconvenience caused.

@agarwl agarwl closed this Mar 3, 2017
@agarwl agarwl reopened this Mar 3, 2017
@agarwl agarwl force-pushed the patch-1 branch 2 times, most recently from 01700a5 to 6368474 Compare March 3, 2017 19:22
@agarwl agarwl changed the title Added some unittests in test_learning.py Added some tests in test_learning.py Mar 3, 2017
@Chipe1
Copy link
Contributor

Chipe1 commented Mar 8, 2017

@TheSPARTA Could you break this PR into 2 parts, 1 which resolves the mistake in count() and one which adds test cases after resolving the conflicts. You can aslo uncomment the mean_boolean_error() test cases as the bug seems to be fixed

@norvig norvig merged commit 2bba02e into aimacode:master May 31, 2017
dj5x5 pushed a commit to dj5x5/aima-python that referenced this pull request Jul 17, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy