1

I am following some tutorials for the implementation of TICA, to do a dimension reduction, but I have the following problem;

AttributeError: module 'numpy' has no attribute 'bool'. np.bool was a deprecated alias for the builtin bool. To avoid this error in existing code, use bool by itself. Doing this will not modify any behavior and is safe. If you specifically wanted the numpy scalar type, use np.bool_ here. The aliases was originally deprecated in NumPy 1.20; for more details and guidance see the original release note at: https://numpy.org/devdocs/release/1.20.0-notes.html#deprecations

I've already updated numpy, but I still get the same error.

What could I do?

I've already updated numpy, and I have create a entorn in conda, but I still get the same error.

What could I do?

5
  • Don't use np.bool, just use regular Python bool Commented Sep 8, 2023 at 14:20
  • I only imported numpy as np, but within the code I have not used np.bool. Commented Sep 8, 2023 at 22:38
  • Then you might need to downgrade NumPy as it seems one of the other libraries is using this. Try installing an old version of NumPy Commented Sep 10, 2023 at 12:47
  • Please provide enough code so others can better understand or reproduce the problem. Commented Sep 10, 2023 at 14:56
  • This is my code : tica = pyemma.coordinates.tica(data, dim=1, lag=1) tica_output = tica.get_output() print(tica_output) Commented Sep 11, 2023 at 14:43

1 Answer 1

0

Solution for this is to downgrade numpy, this worked for me

python -m pip install numpy==1.23.1
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.