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

difficulty installing climateplots #134

Closed
gaelforget opened this issue Feb 28, 2020 · 6 comments
Closed

difficulty installing climateplots #134

gaelforget opened this issue Feb 28, 2020 · 6 comments

Comments

@gaelforget
Copy link
Member

gaelforget commented Feb 28, 2020

I first installed ClimateTools via Pkg.add (got v0.14.5 somehow) then proceeded to install ClimatePlots as explained in the docs. But this approach lead to the error message below.

(v1.3) pkg> add ClimatePlots
 Resolving package versions...
ERROR: Unsatisfiable requirements detected for package ClimatePlots [b71d359b]:
 ClimatePlots [b71d359b] log:
 ├─possible versions are: [0.1.0, 0.2.0-0.2.2] or uninstalled
 ├─restricted to versions * by an explicit requirement, leaving only versions [0.1.0, 0.2.0-0.2.2]
 └─restricted by compatibility requirements with ClimateTools [4f4ee721] to versions: uninstalled — no versions left
   └─ClimateTools [4f4ee721] log:
     ├─possible versions are: [0.9.0, 0.10.0-0.10.1, 0.11.0-0.11.3, 0.12.0, 0.13.0, 0.14.0-0.14.5, 0.15.0, 0.16.0, 0.17.0, 0.18.0-0.18.1] or uninstalled
     └─restricted to versions 0.14.5 by an explicit requirement, leaving only versions 0.14.5

update:

I went back and, instead of using Pkg.add, I cloned the repo and used Pkg.dev. This resolved the above error and now I have both ClimateTools and ClimatePlots compiled. Maybe all that's needed is an update to the docs?

@Balinus
Copy link
Member

Balinus commented Feb 28, 2020

Well, the initial pkg.add should have installed 0.18.x. I'll look into that.

@Balinus
Copy link
Member

Balinus commented Feb 28, 2020

In a fresh environment, ClimateTools 0.18.1 and ClimatePlots 0.2.2 installs correctly.

Version 0.14.x from memory is before the migration. It should include ClimatePlots natively. Some other dependency is probably getting you back on ClimateTools.

@gaelforget
Copy link
Member Author

I just included a notebook draft into https://github.com/JuliaClimate/GlobalOceanNotebooks to demo climatetools and climateplots functionalites.

The notebook is a first cut that I intend to improve etc but the more immediate issue is that climatetools does not seem to compile in binder.

Would be great if you could take a look and / or advise

┌ Info: Precompiling ClimateTools [4f4ee721-4970-5af2-8560-6c1d960e3231]
└ @ Base loading.jl:1273
ERROR: LoadError: Failed to precompile Ipopt [b6b21f68-93f8-5de0-b562-5493be1d77c9] to /srv/julia/pkg/compiled/v1.3/Ipopt/yMQMo_kQr4m.ji.

@Balinus
Copy link
Member

Balinus commented Mar 9, 2020

Nice, thanks! :)

I'm also gonna try to improve the draft once I have some time. Seems like that when you load the precipitation dataset with data_units="mm" is not converted to mm (at least according to the contoured map. Will take a look.

Not sure about the binder issue about Ipopt. I'm gonna run the notebook on Binder and sees where it goes!

@Balinus
Copy link
Member

Balinus commented Mar 9, 2020

The installation of ClimateTools on Binder was OK. ClimatePlots failed because of python distribution where it could not find matplotlib. Perhaps it's simply a matter of specifying ENV["PYTHON"]="" so that it uses Julia's python instead of binder distribution and rebuild PyCall?

┌ Info: Precompiling ClimateTools [4f4ee721-4970-5af2-8560-6c1d960e3231]
└ @ Base loading.jl:1273
┌ Info: Precompiling ClimatePlots [b71d359b-899c-4fb1-b3ad-2de2d2cb8353]
└ @ Base loading.jl:1273
ERROR: LoadError: InitError: PyError (PyImport_ImportModule

The Python package matplotlib could not be found by pyimport. Usually this means
that you did not install matplotlib in the Python version being used by PyCall.

PyCall is currently configured to use the Python version at:

/srv/conda/envs/notebook/bin/python3

and you should use whatever mechanism you usually use (apt-get, pip, conda,
etcetera) to install the Python package containing the matplotlib module.

One alternative is to re-configure PyCall to use a different Python
version on your system: set ENV["PYTHON"] to the path/name of the python
executable you want to use, run Pkg.build("PyCall"), and re-launch Julia.

@Balinus
Copy link
Member

Balinus commented Jun 25, 2020

I think this was mostly a matter of updating Project.toml. Feel free to reopen if it does not work!

@Balinus Balinus closed this as completed Jun 25, 2020
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

2 participants