wrf-python installed from conda-forge produces import error
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 25/100
- Issue 类型
- 缺陷
- 描述清晰度
- 需要澄清
- 活跃度
- 停滞
- 技术栈
- python
- 领域
- build-system
调研方向
在 Windows 7 上使用报告中的 python -c "import wrf" 命令重现 conda-forge 安装。阅读 _wrffortran 导入附近的 wrf/__init__.py 和 wrf/config.py,然后将 conda 软件包与可正常工作的 wheel 进行比较;完成的标准是 conda 安装能够成功导入,并且无需 DLL 故障即可读取 wrfout NetCDF 文件。
由索引模型根据 Issue 内容生成。
描述
Installed wrf-pyhton through conda-forge on windows 7 64 bit. Post installation, checked if the package is installed correctly using following command:-
python -c "import wrf"
and it worked without an error. However, when I ran the script the following error is produced:-
Python 3.7.6 (default, Jan 8 2020, 20:23:39) [MSC v.1916 64 bit (AMD64)] :: Anaconda, Inc. on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import wrf
Traceback (most recent call last):
File "C:\Users\Sundar\miniconda3\envs\insdvp\lib\site-packages\wrf\__init__.py", line 6, in <module>
from . import api
File "C:\Users\Sundar\miniconda3\envs\insdvp\lib\site-packages\wrf\api.py", line 1, in <module>
from .config import (xarray_enabled, disable_xarray, enable_xarray,
File "C:\Users\Sundar\miniconda3\envs\insdvp\lib\site-packages\wrf\config.py", line 6, in <module>
from ._wrffortran import (fomp_enabled, fomp_set_num_threads,
ImportError: DLL load failed: The specified path is invalid.
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Users\Sundar\miniconda3\envs\insdvp\lib\site-packages\wrf\__init__.py", line 18, in <module>
from . import api
File "C:\Users\Sundar\miniconda3\envs\insdvp\lib\site-packages\wrf\api.py", line 1, in <module>
from .config import (xarray_enabled, disable_xarray, enable_xarray,
File "C:\Users\Sundar\miniconda3\envs\insdvp\lib\site-packages\wrf\config.py", line 6, in <module>
from ._wrffortran import (fomp_enabled, fomp_set_num_threads,
ImportError: DLL load failed: The specified path is invalid.
I am not sure what causes the problem. Could someone help on this t rectify...
Edit:-
Just to clarify that the same works on Linux version of miniconda.
Edit-2
Uninstalled latest version of wrf-python and installed older version (1.3.0). This time I am getting following error:-
Traceback (most recent call last):
File "insdvp_app.py", line 30, in <module>
import utils
File "Y:\project\insdvpgit\insdvp\utils.py", line 34, in <module>
from wrf import interplevel
File "C:\Users\Sundar\miniconda3\envs\insdvp\lib\site-packages\wrf\__init__.py", line 16, in <module>
from . import api
File "C:\Users\Sundar\miniconda3\envs\insdvp\lib\site-packages\wrf\api.py", line 1, in <module>
from .config import (xarray_enabled, disable_xarray, enable_xarray,
File "C:\Users\Sundar\miniconda3\envs\insdvp\lib\site-packages\wrf\config.py", line 6, in <module>
from ._wrffortran import (fomp_enabled, fomp_set_num_threads,
ImportError: DLL load failed: The specified path is invalid.
Edit-3
Fiddled around with package from https://www.lfd.uci.edu/~gohlke/pythonlibs/. This time it successfully installed (version 1.2.0 as it was the latest at that point of time) and imported without an error. However, while reading the wrfout file, the script closed without producing an error.
To check if the problem exist in window 10, I installed the module on a freshly installed miniconda. This time it did not show any error as I have observed in windows 7. However, It simply closes without producing any error when reading a wrfout netcdf file as seen in latest try on windows 7.
Edit-4
Checked the wheel package today again at https://www.lfd.uci.edu/~gohlke/pythonlibs/#wrf_python and found the latest version 1.3.2. Uninstalled the conda version and installed whell package from link. Finally, It worked :-)
Something is wrong with conda install on windows. You guys may want to chack it out...
- 主要语言
- Python
- 星标
- 498
- 派生
- 178
- PR 合并指标
- 30 天内没有已合并 PR
贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
NCAR/wrf-python 的其他 Issue
-
NCAR/wrf-python#309 · 已指派 1 人 ·
-
难度 4/5 3-5 天 新手友好度 38/100
NCAR/wrf-python#307 · 5 条评论 ·
-
难度 4/5 3-5 天 新手友好度 35/100
NCAR/wrf-python#286 · 3 条评论 ·
-
难度 5/5 一周以上 新手友好度 25/100
NCAR/wrf-python#282 · 1 条评论 ·
-
PyPI releases 未关闭
NCAR/wrf-python#274 · 5 条评论 · 1 个 reaction · 已指派 1 人 ·
相似的 Issue
-
bug
难度 2/5 1-3 小时 新手友好度 75/100
stephrobert/dsoxlab#238 ·
-
难度 2/5 1-3 小时 新手友好度 75/100
-
难度 2/5 1-3 小时 新手友好度 75/100
sublimehq/package_control#1780 ·
-
难度 2/5 1-3 小时 新手友好度 65/100
-
难度 2/5 1-3 小时 新手友好度 70/100
nwg-piotr/nwg-displays#145 ·