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

No module named 'regression' #10

Open
dealdata opened this issue Sep 14, 2019 · 12 comments
Open

No module named 'regression' #10

dealdata opened this issue Sep 14, 2019 · 12 comments

Comments

@dealdata
Copy link

Hi,
I am getting below error while initializing. Please advise the solution

FYI - All libraries are updated with latest version


ModuleNotFoundError Traceback (most recent call last)
in ()
----> 1 from hunga_bunga import HungaBungaClassifier, HungaBungaRegressor, HungaBungaZeroKnowledge

~\Anaconda3\lib\site-packages\hunga_bunga_init_.py in ()
4 from multiprocessing import cpu_count
5 from sklearn.base import BaseEstimator
----> 6 from regression import HungaBungaRegressor
7 from classification import HungaBungaClassifier
8

ModuleNotFoundError: No module named 'regression'

@AbdullahKeteldijk
Copy link

AbdullahKeteldijk commented Sep 18, 2019

You should change the line to:

from hunga_bunga.regression import HungaBungaRegressor

You should repeat that multiple times for all occurrences of that error and you should probably also pip install tabulate.

@veshitala
Copy link

It's still not working

@AbdullahKeteldijk
Copy link

AbdullahKeteldijk commented Sep 19, 2019

what error are you getting? Remember you should add hunga_bunga. before any python file that is imported in this package, but only those that throw this same error.

@Veritas-Solutions
Copy link

Capture

@kpei
Copy link

kpei commented Sep 30, 2019

Having this same issue as well installing from pip on a kaggle kernel

edit: installing @danpol's PR worked

@ngupta23
Copy link

I am having the same issue. @kpei - How did you resolve it exactly. I don't see that PR

@Davisy
Copy link

Davisy commented Oct 12, 2019

I have the same issue, and I don't know how to solve it. If you were able to find the solution please let me know

@maxlamberti
Copy link

maxlamberti commented Oct 19, 2019

Looks like the init file isn't finding the files in the package. For anyone interested in an immediate quick and dirty fix, to get it running on your machine add the hunga-bunga module to your sys path before calling from hunga_bunga import .... Obviously needs to be fixed in the package still.

General Example:

import sys
sys.path.append('PATH-TO-YOUR-HUNGABUNGA')
from hunga_bunga import HungaBungaClassifier

Specific Example:

import sys
sys.path.append('~/anaconda3/envs/ENV/lib/python3.6/site-packages/hunga_bunga')
from hunga_bunga import HungaBungaClassifier

@jamespreed
Copy link

jamespreed commented Mar 4, 2020

The relative import path in the module are missing

To fix, modify the following files in the follow ways:

init.py

Add a . before the module names on lines 6 and 7:

from .regression import HungaBungaRegressor
from .classification import HungaBungaClassifier

classifiction.py

Add a . before the module names on lines 26 and 27:

from .core import *
from .params import *

regression.py

Add a . before the module names on lines 22 and 23:

from .core import *
from .params import *

@srulikbd
Copy link

srulikbd commented Apr 17, 2020

I had a similar problem-
couldn't import:
"from hunga_bunga import HungaBungaClassifier"
so I just open the hunga bunga lib as a new project in PyCharm, and it fixed it.
so just click file>>open "C:\Users\user\PycharmProjects\TensorFlow_GPU\Lib\site-packages\hunga_bunga"
and then
from hunga_bunga import HungaBungaClassifier
should work. (the others import still make some problems)

@raghavgupta84
Copy link

I followed steps suggested by jamespreed and installed tabulate using pip install tabulate.

Then I was able to import using following commands :-
from hunga_bunga import HungaBungaClassifier, HungaBungaRegressor

@Krystalz2018
Copy link

i think you can try:
pip install regression
the problem may be that you didn't install the related package in python

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

No branches or pull requests