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 'numpy' has no attribute 'float128' #1127

Closed
hjort opened this issue Apr 14, 2021 · 2 comments
Closed

AttributeError: module 'numpy' has no attribute 'float128' #1127

hjort opened this issue Apr 14, 2021 · 2 comments
Labels

Comments

@hjort
Copy link

hjort commented Apr 14, 2021

Describe the bug

Got the following issue:

/opt/anaconda3/lib/python3.6/site-packages/autosklearn/automl.py in subsample_if_too_large(X, y, logger, seed, memory_limit, task)
820 elif X.dtype in (np.float64, np.float):
821 multiplier = 8
--> 822 elif X.dtype == np.float128:
823 multiplier = 16
824 else:
AttributeError: module 'numpy' has no attribute 'float128'

To Reproduce

  1. On a Debian Linux 32-bit, with Python 3.6.7 (Anaconda 32-bit)
    Linux 3.13.0-170-generic Error on Refit with ProjLogit #220-Ubuntu SMP Thu May 9 12:41:17 UTC 2019 i686 athlon i686 GNU/Linux
  2. The following code:
    import autosklearn.classification
    automl = autosklearn.classification.AutoSklearnClassifier(
    time_left_for_this_task=2060,
    per_run_time_limit=2
    60,
    n_jobs=2,
    memory_limit=1024,
    seed=42,
    include_preprocessors=["no_preprocessing"]
    )
    automl.fit(X_train, y_train)

Expected behavior

The code should work regardless of 32 or 64-bit architectures, as Scikit-Learn does.

Environment and installation:

Please give details about your installation:

  • OS: Ubuntu 32-bit
  • Is your installation in a virtual environment or conda environment? Anaconda
  • Python version: 3.6.7
  • Auto-sklearn version: 0.12.5
@mfeurer
Copy link
Contributor

mfeurer commented Apr 14, 2021

Thanks for reporting this issue @hjort. Sorry for the trouble, I was not aware of the fact that np.float128 is not available on 32 bit systems. We would appreciate a PR fixing this issue.

@mfeurer
Copy link
Contributor

mfeurer commented Jun 25, 2021

Hey @hjort we just merged a fix to the development branch. Please reopen this issue if the bug persists with that cange.

@mfeurer mfeurer closed this as completed Jun 25, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants