JacksonWuxs / DaPy

Easy-to-use data analysis / manipulation framework for humans
http://dapy.kitgram.cn
592 stars 48 forks source link

Latest DaPy fails to load pageranker #10

Closed alaskamike closed 5 years ago

alaskamike commented 5 years ago

I just did a clean reinstall of DaPy on Python 3.7.4.

When I tried to load methods (from DaPy import methods) I got the following error:

print pageranker(initial, weight) ^ SyntaxError: invalid syntax

JacksonWuxs commented 5 years ago

Well, I just found that error few days ago and I remembered I have updated DaPy already. This error was raised because I develop this module on Python2 and I forgot to remove this testing function. To solve this problem, you have two choices as following:

  1. update to latest DaPy: pip install -U DaPy ( I highly recommand it)
  2. remove this code in file: DaPy/methods/core/pagerank.py -> line: 56
alaskamike commented 5 years ago

Thanks, updating fixed the first issue. Now I'm getting and error when I try to create an MLP:

AttributeError: module 'DaPy.methods' has no attribute 'MLP'

JacksonWuxs commented 5 years ago

well, I am sure you are following the old-edition guide book. In new DaPy, I classify the models by your purposes. The original purpose of MLP is a classifier. Thus, the correct import statement is: from DaPy.methods.classifiers import MLPClassifier. There are other classifiers in DaPy, such as Decision Tree and Logistic Regression.

JacksonWuxs commented 5 years ago

I hope you can solve your real-world problem with DaPy. It is pretty kind of you if you can share your working experiment with our project.

alaskamike commented 5 years ago

Ok, I think you need to update your documentation. Every line of the tutorial leads to another error:

mlp.create(input_cell=13, output_cell=3) AttributeError: 'MLPClassifier' object has no attribute 'create'

I think your project has potential, but as of now I can't use it. I'm looking forward to seeing a new release in the future.

JacksonWuxs commented 5 years ago

I am very sorry for wasting your time on the useless introduction. I will try my best to make a novel introduction for a real-word task.