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

AttributeError: module 'cflearn' has no attribute 'Auto' #10

Closed
Vaunorage opened this issue Oct 20, 2020 · 2 comments
Closed

AttributeError: module 'cflearn' has no attribute 'Auto' #10

Vaunorage opened this issue Oct 20, 2020 · 2 comments

Comments

@Vaunorage
Copy link

when running turorial code :

import cflearn

from cfdata.tabular import *

# prepare iris dataset
iris = TabularDataset.iris()
iris = TabularData.from_dataset(iris)
# split 10% of the data as validation data
split = iris.split(0.1)
train, valid = split.remained, split.split
x_tr, y_tr = train.processed.xy
x_cv, y_cv = valid.processed.xy
data = x_tr, y_tr, x_cv, y_cv

#%%
fcnn = cflearn.make().fit(*data)

# 'overfit' validation set
auto = cflearn.Auto(TaskTypes.CLASSIFICATION).fit(*data, num_jobs=2)

# estimate manually
predictions = auto.predict(x_cv)
print("accuracy:", (y_cv == predictions).mean())

# estimate with `cflearn`
cflearn.estimate(
    x_cv,
    y_cv,
    pipelines=fcnn,
    other_patterns={"auto": auto.pattern},
)

Get this error :

File "C:\ProgramData\miniconda\lib\site-packages\IPython\core\interactiveshell.py", line 3331, in run_code
exec(code_obj, self.user_global_ns, self.user_ns)
File "", line 4, in
auto = cflearn.Auto(TaskTypes.CLASSIFICATION).fit(*data, num_jobs=2)
AttributeError: module 'cflearn' has no attribute 'Auto'

@carefree0910
Copy link
Owner

Hi! It's my bad for not clarifying that the AutoML usage is only available through pip installing from source 😢 I'll update the README.md ASAP!

@carefree0910
Copy link
Owner

I've updated the README.md, hiding oridinary pip install method 😅

I know this is something bad but I'm busy working on new features, after which I'll release a new version! 🤣

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

2 participants