wrf-python icon indicating copy to clipboard operation
wrf-python copied to clipboard

WRF-Python Install - Mac M3

Open wreed1989 opened this issue 1 year ago • 14 comments

Hello!

I'm wanting to set-up and run WRF on my M3 (if possible) and reading through the documentation it sounds like the easiest way to do this is via 'conda forge'. However, I'm running into an issue when I attempt to install the program (see below).

Is the platform not quite suitable with an M3 chip or are there additional instructions that need to be done to ensure the package and its dependencies are installed appropriately?

I appreciate the assistance!

############################################################################################### (WRF-Python) Billiam@Williams-MacBook-Pro ~ % conda install -c conda-forge wrf-python Channels:

  • conda-forge
  • defaults Platform: osx-arm64 Collecting package metadata (repodata.json): done Solving environment: failed

PackagesNotFoundError: The following packages are not available from current channels:

  • wrf-python

Current channels:

  • https://conda.anaconda.org/conda-forge
  • defaults

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. ###############################################################################################

wreed1989 avatar Apr 16 '24 23:04 wreed1989

Hi, thanks very much for reaching out! Currently, WRF-Python shouldn't have support for Apple's ARM-based chips (M1-3), but we'd like to look into this as soon as we can. I am assigning this to myself and will keep you updated.

erogluorhan avatar Apr 25 '24 16:04 erogluorhan

you can install via source code. I have successfully installed it.

phalucy avatar Apr 28 '24 01:04 phalucy

Did you happen to create a workflow when you did that? I'm guessing not but if you did, I'd love to see it to help me install it.

wreed1989 avatar Apr 28 '24 17:04 wreed1989

Sorry, I didn't. I just followed the steps showed in the online document using gfortran/gcc.

Only one issue should be aware. Although I successfully installed the wrf-python with openmpi option on my M3 macbook pro and most functions works fine , but it fails when I tried to use mpi functions. I'm not familiar with the options/compilers, but it maybe related to the M series chips (arm64) only allow mcmodel=small.

phalucy avatar Apr 29 '24 06:04 phalucy

@wreed1989 , please see this from our team to get a working source-code build for yourself. If you encounter issues, we are here for help!

FYI: We will be looking into creating a conda release for this soon so that you can install the package from conda-forge, too, in the future.

erogluorhan avatar May 08 '24 15:05 erogluorhan

@erogluorhan Appreciate you sending that over. I'm a little unfamiliar with installing via source code so I'll likely have to wait until the conda-forge option is available - or until I can track down additional instructions on how to install via source code.

I'm looking forward to the conda-forge release!

wreed1989 avatar May 08 '24 23:05 wreed1989

Thanks @wreed1989 ! We are currently working on the conda release and hoping to get it soon!

erogluorhan avatar May 14 '24 17:05 erogluorhan

Please let me know when it's ready to roll out! I appreciate it!

wreed1989 avatar May 14 '24 21:05 wreed1989

@erogluorhan Hi, I am also working in Apple M3 Max, and installed (via conda, from source) wrf_python. However it is not working. Apparently there is an issue with netcdf4 (which was installed). Please see the error below: Traceback (most recent call last): File "precipitacao_acumulada.py", line 8, in from netCDF4 import Dataset ModuleNotFoundError: No module named 'netCDF4'

any suggestion? Cheers,

lppezzi avatar Sep 18 '24 17:09 lppezzi