-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild-env.sh
executable file
·54 lines (45 loc) · 1.71 KB
/
build-env.sh
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
#!/bin/bash
if [ ! -f env_faro/bin/activate ]; then
echo "Creating env_faro..."
virtualenv -p python3 env_faro
echo "export PYTHONPATH=`pwd`/src" >> env_faro/bin/activate
echo "export PATH=`pwd`/bin:\$PATH" >> env_faro/bin/activate
source env_faro/bin/activate
pip install -U protobuf grpcio grpcio.tools pyvision_toolkit
fi
if [ ! -f env_faro_server/bin/activate ]; then
echo "Creating env_faro_server..."
virtualenv -p python3 env_faro_server
echo "export PYTHONPATH=`pwd`/src" >> env_faro_server/bin/activate
echo "export PATH=`pwd`/bin:\$PATH" >> env_faro_server/bin/activate
source env_faro_server/bin/activate
pip install -U protobuf grpcio grpcio.tools pyvision_toolkit
pip install -U keras_vggface
# Test for an nvidia gpu
pip uninstall -y tensorflow-gpu tensorflow # this is installed by keras_vggface but we want the gpu version
if which nvidia-smi; then
pip install -U tensorflow-gpu
else
pip install -U tensorflow
fi
pip install -U keras # The newer versions have a bug
pip install -U dlib
fi
if [ ! -f env_faro_server2/bin/activate ]; then
echo "Creating env_faro_server..."
virtualenv -p python2 env_faro_server2
echo "export PYTHONPATH=`pwd`/src" >> env_faro_server2/bin/activate
echo "export PATH=`pwd`/bin:\$PATH" >> env_faro_server2/bin/activate
source env_faro_server2/bin/activate
pip install -U protobuf grpcio grpcio.tools pyvision_toolkit
pip install -U keras_vggface
# Test for an nvidia gpu
pip uninstall -y tensorflow-gpu tensorflow # this is installed by keras_vggface but we want the gpu version
if which nvidia-smi; then
pip install -U tensorflow-gpu
else
pip install -U tensorflow
fi
pip install -U keras==2.2.0 # The newer versions have a bug
pip install -U dlib
fi