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

Problem with installation of PyGnome #123

Open
rsbragio opened this issue Jun 24, 2022 · 6 comments
Open

Problem with installation of PyGnome #123

rsbragio opened this issue Jun 24, 2022 · 6 comments

Comments

@rsbragio
Copy link

Hi, I am trying to install PyGnome model and, although it seems to complete the installation, I had the following errors when running the script from Spyder:

c:\users\rs\pygnome\py_gnome\gnome_init_.py:62: UserWarning: ERROR: The gridded package, version >= 0.3.0 needs to be installed:
warnings.warn(msg)
Traceback (most recent call last):
File "C:\Users\RS\anaconda3\envs\gnome\lib\site-packages\spyder_kernels\py3compat.py", line 356, in compat_exec
exec(code, globals, locals)
File "c:\users\rs\documents\usp-posdoc\costabrasil\run_pygnome.py", line 9, in
import gnome.scripting as gs
File "c:\users\rs\pygnome\py_gnome\gnome_init_.py", line 136, in
from . import (environment,
File "c:\users\rs\pygnome\py_gnome\gnome\environment_init_.py", line 5, in
from .environment import Environment, env_from_netCDF, ice_env_from_netCDF
File "c:\users\rs\pygnome\py_gnome\gnome\environment\environment.py", line 17, in
from gnome.persist import base_schema
File "c:\users\rs\pygnome\py_gnome\gnome\persist_init_.py", line 19, in
from .extend_colander import (TupleSchema, SequenceSchema, SchemaNode,
File "c:\users\rs\pygnome\py_gnome\gnome\persist\extend_colander.py", line 14, in
import gnome.basic_types
File "c:\users\rs\pygnome\py_gnome\gnome\basic_types.py", line 24, in
from .cy_gnome import cy_basic_types as cbt
ImportError: DLL load failed while importing cy_basic_types: The specified procedure could not be found.

When running directly using the command "python name_of_script.py", the following error message came:
from gnome.spill import point_line_release_spill
ModuleNotFoundError: No module named 'gnome.spill'

I am following the installation procedure from https://gnome.orr.noaa.gov/doc/pygnome/installing.html#building-installing-pygnome-with-the-conda-package-manager, but it seems that some packages are not being installed correctly.

I would like to ask for your help in this issue.

Thanks.

@jay-hennen
Copy link
Contributor

Just to verify, are you in the 'gnome' environment you created in those instructions? Usually these sort of 'not found' problems after installation are due to either your terminal or your installation not being in the correct environment.

@rsbragio
Copy link
Author

Hi Jay,
Yes. In both trials, I ran the script from inside the Gnome environment.

@AmyMacFadyen
Copy link
Contributor

gnome.spill was renamed to gnome.spills for consistency. sorry, for that inconvenience and lack of backwards compatibility with existing scripts.

@rsbragio
Copy link
Author

Hy Amy,
Thanks very much for the information. I tried renaming gnome.spills to gnome.spill, but the error continues. Shall I wait for some correction on the installation files, or shall I try something else to correct?

@AmyMacFadyen
Copy link
Contributor

A few more questions. What branch of PyGNOME are you working in? Default is "main". Also, if you are in the environment you set up for GNOME, in Python are you able to do "import gnome" successfully?

@rsbragio
Copy link
Author

I am not sure about what branch I am working in. I followed the instructions from https://gnome.orr.noaa.gov/doc/pygnome/installing.html.

During installation, I have not seen any option about using any other branch. In fact, I do not know what a branch is. The command I have used for importing gnome was:
git clone https://github.com/NOAA-ORR-ERD/PyGnome.git

After cloning the directory, I created the PyGnome environment using:
conda create -n gnome --file conda_requirements.txt

It seems that all files were downloaded correctly.

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