apps_conda tested, tensowflow in userspace added "setup_tensorflow_conda.sh"
This commit is contained in:
parent
e4f762a08e
commit
03a8ba8366
|
@ -1,6 +1,6 @@
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
|
||||||
#variant to use conda insted of pip, not tested
|
#variant to use conda insted of pip, tested
|
||||||
|
|
||||||
#Src: https://medium.com/swlh/how-to-install-jupyterhub-using-conda-without-runing-as-root-and-make-it-a-service-59b843fead12
|
#Src: https://medium.com/swlh/how-to-install-jupyterhub-using-conda-without-runing-as-root-and-make-it-a-service-59b843fead12
|
||||||
# https://jupyterhub.readthedocs.io/en/1.2.1/installation-guide-hard.html
|
# https://jupyterhub.readthedocs.io/en/1.2.1/installation-guide-hard.html
|
||||||
|
@ -86,14 +86,16 @@ ln -s /opt/conda/etc/profile.d/conda.sh /etc/profile.d/conda.sh
|
||||||
|
|
||||||
mkdir -p /opt/conda/envs/
|
mkdir -p /opt/conda/envs/
|
||||||
|
|
||||||
/opt/conda/bin/conda create --prefix /opt/conda/envs/python python=3.7 ipykernel
|
/opt/conda/bin/conda create --prefix /opt/conda/envs/default_python python=3.7 ipykernel --yes
|
||||||
/opt/conda/envs/python/bin/python -m ipykernel install --prefix /usr/local/ --name 'python' --display-name "Python (default)"
|
/opt/conda/envs/python/bin/python -m ipykernel install --prefix /usr/local/ --name 'default_python' --display-name "Python (default)"
|
||||||
#/opt/conda/envs/python/bin/python -m ipykernel install --prefix=/opt/jupyterhub/ --name 'python' --display-name "Python (default)"
|
#/opt/conda/envs/python/bin/python -m ipykernel install --prefix=/opt/jupyterhub/ --name 'python' --display-name "Python (default)"
|
||||||
|
|
||||||
#install ofen used python packages for default environment
|
#install ofen used python packages for default environment
|
||||||
/opt/conda/bin/conda install h5py tqdm pandas pillow matplotlib ipympl opencv-python --yes --name python
|
/opt/conda/bin/conda install h5py tqdm pandas pillow matplotlib ipympl matplotlib --yes -n default_python
|
||||||
/opt/conda/bin/conda install cantera --channel cantera --yes --name python
|
/opt/conda/bin/conda install cantera --channel cantera --yes -n default_python
|
||||||
|
|
||||||
|
#remove ipykernel for base enviroment:
|
||||||
|
#jupyter kernelspec remove python3
|
||||||
|
|
||||||
|
|
||||||
#users have to setup there kernel like this:
|
#users have to setup there kernel like this:
|
||||||
|
@ -106,10 +108,7 @@ mkdir -p /opt/conda/envs/
|
||||||
#jupyter labextension install jupyter-matplotlib
|
#jupyter labextension install jupyter-matplotlib
|
||||||
|
|
||||||
#echo "Install Tensorflow..."
|
#echo "Install Tensorflow..."
|
||||||
#conda install --yes tensorflow-gpu
|
#conda install --yes tensorflow-gpu -c conda-forge
|
||||||
|
|
||||||
#echo "Install cantera..."
|
|
||||||
#conda install --yes --channel cantera cantera
|
|
||||||
|
|
||||||
#echo "Install common Python libs..."
|
#echo "Install common Python libs..."
|
||||||
#conda install --yes h5py tqdm pandas ipywidgets pillow matplotlib ipympl opencv-python
|
#conda install --yes h5py tqdm pandas ipywidgets pillow matplotlib ipympl opencv-python
|
||||||
|
|
|
@ -0,0 +1,12 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
if [ "$EUID" -eq 0 ]
|
||||||
|
then echo "Please run not as root"
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
|
||||||
|
conda create ipykernel --name tensorflow -c conda-forge
|
||||||
|
conda install --yes --name tensorflow tensorflow-gpu tensorboard -c conda-forge
|
||||||
|
python -m ipykernel install --user --name tensorflow --display-name "Python (Tensorflow)"
|
Loading…
Reference in New Issue