Skip to content

Add self as parameter to all methods of class Feature#93

Merged
pavanky merged 1 commit into
arrayfire:develfrom
lukasbindreiter:features-fix
Sep 9, 2016
Merged

Add self as parameter to all methods of class Feature#93
pavanky merged 1 commit into
arrayfire:develfrom
lukasbindreiter:features-fix

Conversation

@lukasbindreiter
Copy link
Copy Markdown

In features.py all the methods of the Feature class have zero parameters, which makes them unusable since python requires self to be passed as first parameter.

Therefore

class Features(object):
    ...

    def num_features():
        ...

needs to be changed to

class Features(object):
    ...

    def num_features(self):
        ...

otherwise you receive an error: TypeError: get_xpos() takes 0 positional arguments but 1 was given

@pavanky pavanky merged commit af52c64 into arrayfire:devel Sep 9, 2016
@lukasbindreiter lukasbindreiter deleted the features-fix branch September 9, 2016 16:20
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.

2 participants