Comments (9)
We can't diagnose what might be going wrong with Jupyter, but I'd try something like conda create -c conda-forge -c nodefaults -n calliope calliope jupyter notebook python=3.9
- that ought to get you an environment with a working Jupyter installation.
from calliope.
We can't diagnose what might be going wrong with Jupyter, but I'd try something like
conda create -c conda-forge -c nodefaults -n calliope calliope jupyter notebook python=3.9
- that ought to get you an environment with a working Jupyter installation.
Magic! It worked, you were very kind. Thanks a lot!
from calliope.
Could you try it with mamba? I find it resolves packages a lot more successfully.
Also, you should try and stop the default
conda channel from being included. This can slow things down as it has more channels to download and then resolve (a view recommended by mamba devs). Adding -c nodefaults
should do the trick.
from calliope.
I already found a workaround by installing from pip:
conda create -n calliope pip
conda activate calliope
pip install calliope
Nodefaults was not faster either (I stopped after 5 minutes):
~ conda create -c conda-forge -c nodefaults -n calliope calliope
Collecting package metadata (current_repodata.json): done
Solving environment: unsuccessful attempt using repodata from current_repodata.json, retrying with next repodata source.
Collecting package metadata (repodata.json): | failed
I just want to state, that the "Quickstart" instructions, weren't so quick at all ;)
which is quite weird as I am creating a new env with only one selected package...
from calliope.
Ok, good to know RE nodefaults. Can you try with mamba? I would highly recommend it as your go-to instead of conda (and we will update our installation instructions accordingly). I also would recommend not mixing conda and pip packages where possible. It might work fine initially but then the environments can become very messy very quickly.
from calliope.
Also, you could try forcing the python version to the highest calliope can be built with: conda create -c conda-forge -c nodefaults -n calliope calliope python=3.9
This should be done by conda by default, but maybe it helps speed things up to pin it explictly.
from calliope.
I heard promising things about mamba, but it is not available as a .deb package, and I don't feel like installing it with sudo tee :D
For my needs I more and more find pip sufficient, as it has binary packages (psycopg2-binary
, pytorch
and so on) as well - reducing the usefulness of conda..?
I am therefore mostly using conda as venv alternative which is globally usable
Setting the python version explicitly did not speed things up for me. How long does this command take on your computer? Maybe this could also be a problem which is only reproducible on Debian12?
EDIT: i could install it after like 10 Minutes - so it has a deterministic end at least :D
from calliope.
It takes less than a minute, but then I have most dependencies cached. It could be a Debian12 thing. I think @sjpfenninger had similar issues on a remote machine recently too, but don't know what distro he was using.
If pip works for you then I would suggest continuing with that as your workaround, but would advise keeping your conda env python version to <=3.9 to ensure you don't accidentally trip up on issues that have led to us choosing this upper limit for now.
from calliope.
Also, you could try forcing the python version to the highest calliope can be built with:
conda create -c conda-forge -c nodefaults -n calliope calliope python=3.9
This should be done by conda by default, but maybe it helps speed things up to pin it explictly.
I tried to install Calliope through this procedure, and it worked, as well as it worked through Mamba. Unfortunately, I encountered the same error when launching the Jupyter Notebook.
First, the Jupyter Notebook is not installed, then I installed it in the Calliope environment just created. Then, when launching it, i get the following error, as if smth got lost during the "easy way to install":
Traceback (most recent call last):
File "C:\Users\Tommaso\anaconda3\envs\calliope\lib\site-packages\notebook\traittypes.py", line 235, in _resolve_classes
klass = self._resolve_string(klass)
File "C:\Users\Tommaso\anaconda3\envs\calliope\lib\site-packages\traitlets\traitlets.py", line 2025, in _resolve_string
return import_item(string)
File "C:\Users\Tommaso\anaconda3\envs\calliope\lib\site-packages\traitlets\utils\importstring.py", line 31, in import_item
module = __import__(package, fromlist=[obj])
ModuleNotFoundError: No module named 'jupyter_server.contents'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "C:\Users\Tommaso\anaconda3\envs\calliope\Scripts\jupyter-notebook-script.py", line 10, in <module>
sys.exit(main())
File "C:\Users\Tommaso\anaconda3\envs\calliope\lib\site-packages\jupyter_core\application.py", line 280, in launch_instance
super().launch_instance(argv=argv, **kwargs)
File "C:\Users\Tommaso\anaconda3\envs\calliope\lib\site-packages\traitlets\config\application.py", line 1051, in launch_instance
app = cls.instance(**kwargs)
File "C:\Users\Tommaso\anaconda3\envs\calliope\lib\site-packages\traitlets\config\configurable.py", line 575, in instance
inst = cls(*args, **kwargs)
File "C:\Users\Tommaso\anaconda3\envs\calliope\lib\site-packages\traitlets\traitlets.py", line 1311, in __new__
inst.setup_instance(*args, **kwargs)
File "C:\Users\Tommaso\anaconda3\envs\calliope\lib\site-packages\traitlets\traitlets.py", line 1354, in setup_instance
super(HasTraits, self).setup_instance(*args, **kwargs)
File "C:\Users\Tommaso\anaconda3\envs\calliope\lib\site-packages\traitlets\traitlets.py", line 1330, in setup_instance
init(self)
File "C:\Users\Tommaso\anaconda3\envs\calliope\lib\site-packages\notebook\traittypes.py", line 226, in instance_init
self._resolve_classes()
File "C:\Users\Tommaso\anaconda3\envs\calliope\lib\site-packages\notebook\traittypes.py", line 238, in _resolve_classes
warn(f"{klass} is not importable. Is it installed?", ImportWarning)
TypeError: warn() missing 1 required keyword-only argument: 'stacklevel'
from calliope.
Related Issues (20)
- Documentation not clear: time series data import from pandas DataFrame HOT 1
- relax_constraint not working, python output saying it's unrecognized HOT 3
- Store example notebooks as plain text
- Document AttrDict `_REPLACE_ ` HOT 1
- Requesting v0.7 documentation improvements/fixes HOT 3
- Cannot use IDE schema validator with Calliope model YAML files HOT 1
- `purchased` binary variable isn't linked to `energy_cap` if `energy_cap_max`/`_min`/`_equals` isn't defined
- Cannot define numeric index items when loading tabular data
- Multiple rows and columns introduce false index items HOT 7
- AttrDict sorts keys on union
- Default installation does not have optional dependencies HOT 2
- Allow setting saving of shadow prices for constraints in YAML HOT 2
- Add `title` or `long-name` parameter to math syntax
- Store start and stop time stamps in model results
- Better document and test `operate` mode
- Custom constraints sum() slicing seems to fail inconsistently HOT 1
- adding scenarios and overrides HOT 1
- Run Calliope multiple times with historic data before generating results HOT 1
- Pyomo v6.7.2 regression: Gurobi Python interface not found HOT 2
- Improve package/version management by moving to pixi
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from calliope.