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

Cannot install with Macbook air m1 chips #93

Closed
lamlam3041 opened this issue Oct 6, 2021 · 7 comments
Closed

Cannot install with Macbook air m1 chips #93

lamlam3041 opened this issue Oct 6, 2021 · 7 comments

Comments

@lamlam3041
Copy link

Hello. I have an issue on the installation of earthquake transformer in macbook air m1 chips.
I've tried several times and seems the problem is related to the tensorflow problem. The tensorflow in m1 chips is the version of 2.5 and the required version of eq transformer is 2.0.
The error shows that "Illegal hardware instruction python"

@lamlam3041 lamlam3041 changed the title Cannot install with Macbook air mq chips Cannot install with Macbook air m1 chips Oct 6, 2021
@smousavi05
Copy link
Owner

@lamlam3041 have you tried the EqT version on Github repository? that version uses TF 2.5

@lamlam3041
Copy link
Author

Yes! I have tried this version but the problem still appears.

@smousavi05
Copy link
Owner

@lamlam3041 could you send me the error messages?

@lamlam3041
Copy link
Author

lamlam3041 commented Nov 2, 2021 via email

@RunningXinLiu
Copy link

@lamlam3041 could you send me the error messages?

Hi Seyed, I have the same problem with my mac os M1 laptop. I am trying to install eq transformer in my tensorflow env with python=3.9.

First I tried "conda install -c smousavi05 eqtransformer", the errors is

> (tensorflow) liuxin@liuxindeMBP eq_transformer % conda install -c smousavi05 eqtransformer
> Collecting package metadata (current_repodata.json): done
> Solving environment: failed with initial frozen solve. Retrying with flexible solve.
> Collecting package metadata (repodata.json): done
> Solving environment: failed with initial frozen solve. Retrying with flexible solve.
> 
> PackagesNotFoundError: The following packages are not available from current channels:
> 
>   - eqtransformer
> 
> Current channels:
> 
>   - https://conda.anaconda.org/smousavi05/osx-arm64
>   - https://conda.anaconda.org/smousavi05/noarch
>   - https://conda.anaconda.org/conda-forge/osx-arm64
>   - https://conda.anaconda.org/conda-forge/noarch
>   - https://repo.anaconda.com/pkgs/main/osx-arm64
>   - https://repo.anaconda.com/pkgs/main/noarch
>   - https://repo.anaconda.com/pkgs/r/osx-arm64
>   - https://repo.anaconda.com/pkgs/r/noarch
> 
> To search for alternate channels that may provide the conda package you're
> looking for, navigate to
> 
>     https://anaconda.org
> 
> and use the search bar at the top of the page.
> 

I searched in anaconda and I could find eq transformer so I dont understand why it say can not find it from these channels.

Second, I tried "pip install EQTransformer". The error is

> Collecting EQTransformer
>   Using cached EQTransformer-0.1.59-py3-none-any.whl (78 kB)
> Collecting scipy==1.4.1
>   Using cached scipy-1.4.1.tar.gz (24.6 MB)
>   Installing build dependencies ... error
>   error: subprocess-exited-with-error
>   
>   × pip subprocess to install build dependencies did not run successfully.
>   │ exit code: 1
>   ╰─> [3664 lines of output]
......
  × Encountered error while trying to install package.
  ╰─> numpy
  
  note: This is an issue with the package mentioned above, not pip.
  hint: See above for output from the failure.
  [end of output]

note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error

× pip subprocess to install build dependencies did not run successfully.
│ exit code: 1
╰─> See above for output.

note: This error originates from a subprocess, and is likely not a problem with pip.

My numpy version is "numpy 1.19.5 py39h1f3b974_2 conda-forge" and my python version is 3.9.

Then I tried to clone your source code, the error is:

> (tensorflow) liuxin@liuxindeMBP eq_transformer % git clone git://github.com/smousavi05/EQTransformer
> Cloning into 'EQTransformer'...
> fatal: remote error: 
>   The unauthenticated git protocol on port 9418 is no longer supported.
> Please see https://github.blog/2021-09-01-improving-git-protocol-security-github/ for more information.

Finally, I git cloned your repo with "git clone https://github.com/smousavi05/EQTransformer.git" then use "python setup.py install". I got those error:

> Searching for tensorflow~=2.5.0
> Reading https://pypi.org/simple/tensorflow/
> No local packages or working download links found for tensorflow~=2.5.0
> error: Could not find suitable distribution for Requirement.parse('tensorflow~=2.5.0')

However, on my M1 chip, tensorflow is installed as

tensorflow-deps 2.5.0 1 apple
tensorflow-estimator 2.5.0 pypi_0 pypi
tensorflow-macos 2.5.0 pypi_0 pypi
tensorflow-metal 0.1.2 pypi_0 pypi

I think the name difference leads to the issue.

Do you know is there any way to change those package names?

best,
Xin

@RunningXinLiu
Copy link

Sorry for replying late. My error is " zsh: illegal hardware instruction ipython". I have tried several times to install the tensorflow and the earthquake transformer. I can import the tensorflow alone without the installation of EQT. This error messgae appears when I installed EQT. Regards, Zoe S.Mostafa Mousavi @.***> 於 2021年10月31日週日 下午12:40寫道:

@lamlam3041 https://github.com/lamlam3041 could you send me the error messages? — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub <#93 (comment)>, or unsubscribe https://github.com/notifications/unsubscribe-auth/APXGPOB4J3VVCBWGC722CFDUJTCDLANCNFSM5FN5OGKQ . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

Hi,

I managed to install EQ transformer on my mac os M1 device using the source code. I made some modifications to the setup.py: tensorflow ~= 2.5.0 ---> tensorflow-maco ~= 2.5.0.

Hope this could help you.

Best,
Xin

@smousavi05
Copy link
Owner

smousavi05 commented Mar 29, 2022 via email

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

3 participants