GithubHelp home page GithubHelp logo

Comments (4)

superbobry avatar superbobry commented on July 17, 2024 1

I cannot reproduce this in a fresh virtualenv. Can you confirm that doing

python -m venv env
source env/bin/activate
pip install jax==0.4.27 jaxlib==0.4.27 numpy==2.0
python -c "import jax"

reproduces the issue for you?

from jax.

superbobry avatar superbobry commented on July 17, 2024 1

It look like the jaxlib package in Conda was compiled for NumPy 1.X? I would recommend to either install JAX from PyPI via pip or open an issue in https://github.com/conda-forge/jaxlib-feedstock.

from jax.

hawkinsp avatar hawkinsp commented on July 17, 2024 1

Closing. We don't provide the conda packages for JAX: please file issues for those against the conda-forge feedstock linked above. The pip packages we ship will work with NumPy 2.0, and we recommend you use those if you want NumPy 2.0 support, even if you're otherwise using conda-forge.

from jax.

WhiteSymmetry avatar WhiteSymmetry commented on July 17, 2024

Since my computer only supports the CPU feature, I can install jaxlib's conda and mamba. I tried again today, and it gave the same error.

A module that was compiled using NumPy 1.x cannot be run in
NumPy 2.0.0 as it may crash. To support both 1.x and 2.x
versions of NumPy, modules must be compiled with NumPy 2.0.
Some module may need to rebuild instead e.g. with 'pybind11>=2.12'.

If you are a user of the module, the easiest solution will be to
downgrade to 'numpy<2' or try to upgrade the affected module.
We expect that some modules will need time to support NumPy 2.

Traceback (most recent call last): File "", line 1, in
File "/home//miniconda3/envs/x11/lib/python3.11/site-packages/jax/init.py", line 37, in
import jax.core as _core
File "/home/
/miniconda3/envs/x11/lib/python3.11/site-packages/jax/core.py", line 18, in
from jax._src.core import (
File "/home//miniconda3/envs/x11/lib/python3.11/site-packages/jax/_src/core.py", line 39, in
from jax._src import dtypes
File "/home/
/miniconda3/envs/x11/lib/python3.11/site-packages/jax/_src/dtypes.py", line 33, in
from jax._src import config
File "/home//miniconda3/envs/x11/lib/python3.11/site-packages/jax/_src/config.py", line 27, in
from jax._src import lib
File "/home/
/miniconda3/envs/x11/lib/python3.11/site-packages/jax/_src/lib/init.py", line 87, in
import jaxlib.xla_client as xla_client
File "/home/*/miniconda3/envs/x11/lib/python3.11/site-packages/jaxlib/xla_client.py", line 32, in
from . import xla_extension as _xla
AttributeError: _ARRAY_API not found
Screenshot from 2024-06-18 14-12-57

from jax.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.