Skip to content
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

Fix 'NonHierarchicalClustering' object has no attribute 'ranges' ch5 #23

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Fix 'NonHierarchicalClustering' object has no attribute 'ranges' ch5 #23

wants to merge 1 commit into from

Conversation

Dantali0n
Copy link

In chapter 5 method compute_distance_matrix_instances the attribute self.ranges
is accessed but this is unset. The cause is that ranges above is set as variable
within the scope of the current method but since this is not the constructor of
the class it does not actually set self.ranges. This in turn causes the
subsequent access to result in an AttributeError.

This pull request resolves the aforementioned issues above.

In chapter 5 method compute_distance_matrix_instances the attribute self.ranges
is accessed but this is unset. The cause is that ranges above is set as variable
within the scope of the current method but since this is not the constructor of
the class it does not actually set self.ranges. This in turn causes the
subsequent access to result in an AttributeError.
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.

1 participant