-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsingularity_py3.def
83 lines (76 loc) · 2.12 KB
/
singularity_py3.def
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
Bootstrap: docker
From: ubuntu:18.04
%help
Singularity definition file that builds a container with Python3 and PyBDSF. Note that must use my forked PyBDSF repo (i have submitted a pull reques) with additional lines in the setup.py file that look for libboost_python3 files (from Alex Clarke).
%environment
%post
# Install common dependencies
export DEBIAN_FRONTEND=noninteractive
apt-get update \
&& apt-get --yes install --no-install-recommends \
bison \
build-essential \
cmake \
eog \
flex \
g++ \
gcc \
gettext-base \
gfortran \
git \
libarmadillo-dev \
libblas-dev \
libcfitsio-dev \
libfftw3-dev \
libgsl-dev \
libgtkmm-3.0-dev \
libhdf5-serial-dev \
liblapacke-dev \
liblog4cplus-1.1-9 \
liblog4cplus-dev \
libncurses5-dev \
libpng-dev \
libpython3-dev \
libreadline-dev \
libxml2-dev \
openssh-server \
python3.6 \
python3-pip \
python3-tk \
python3-setuptools \
subversion \
vim \
wcslib-dev \
wget \
screen \
# Install python3 packages
python3.6 -m pip install setuptools Cython
python3.6 -m pip install --upgrade \
wheel \
aplpy \
astropy \
numpy \
matplotlib \
scipy \
wcsaxes \
scikit-learn \
umap-learn \
datashader \
memory_profiler \
# Install boost python 1.63 with python 3
cd / \
&& wget https://dl.bintray.com/boostorg/release/1.63.0/source/boost_1_63_0.tar.bz2 \
&& tar xvf boost_1_63_0.tar.bz2 \
&& cd boost_1_63_0 \
&& ./bootstrap.sh \
--with-python=/usr/bin/python3.6 \
--with-libraries=python,date_time,filesystem,system,program_options,test \
&& ./b2 install \
&& cd / && rm -r boost_1_63_0*
# Install pyBDSF
git clone https://github.com/informationcake/PyBDSF.git \
&& cd PyBDSF \
&& python3.6 -m pip install . \
&& cd .. \
&& rm -rf PyBDSF \
&& echo 'export LD_LIBRARY_PATH=${LD_LIBRARY_PATH}/usr/local/lib' >>$SINGULARITY_ENVIRONMENT