2
2
Here is the detailed process of installation of VDMS dependencies.
3
3
4
4
## Dependencies
5
- To install VDMS, we must install the necessary dependencies via apt, github, and pip.
5
+ To install VDMS, we must install the necessary dependencies via apt, github, and pip (Python 3.9+) .
6
6
7
- ### Install Debian Packages
8
- Here we will install the Debian and Python3 packages.
7
+ ### Install Debian/Ubuntu Packages
8
+ Here we will install the Debian/Ubuntu packages.
9
9
``` bash
10
10
sudo apt-get update
11
11
sudo apt-get install -y --no-install-suggests --no-install-recommends \
12
12
apt-transport-https autoconf automake bison build-essential bzip2 ca-certificates \
13
13
curl ed flex g++-9 gcc-9 git gnupg-agent javacc libarchive-tools libatlas-base-dev \
14
14
libavcodec-dev libavformat-dev libboost-all-dev libbz2-dev libc-ares-dev libcurl4-openssl-dev \
15
- libdc1394-22-dev libgflags-dev libgoogle-glog-dev libgtest-dev libgtk-3-dev libgtk2.0-dev \
16
- libhdf5-dev libjpeg-dev libjpeg62-turbo-dev libjsoncpp-dev libleveldb-dev liblmdb-dev \
15
+ libdc1394-22-dev libgflags-dev libgoogle-glog-dev libgtk-3-dev libgtk2.0-dev \
16
+ libhdf5-dev libjpeg-dev libjsoncpp-dev libleveldb-dev liblmdb-dev \
17
17
liblz4-dev libopenblas-dev libopenmpi-dev libpng-dev librdkafka-dev libsnappy-dev libssl-dev \
18
- libswscale-dev libtbb-dev libtbb2 libtiff-dev libtiff5-dev libtool libzmq3-dev mpich \
18
+ libswscale-dev libtbb-dev libtbb2 libtiff-dev libtiff5-dev libtool libzmq3-dev linux-libc-dev mpich \
19
19
openjdk-11-jdk-headless pkg-config procps python3-dev python3-pip software-properties-common \
20
20
swig unzip uuid-dev
21
21
```
@@ -25,81 +25,110 @@ update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-9 1
25
25
update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-9 1
26
26
```
27
27
28
+ #### ** Install JPEG package**
29
+ Please install the JPEG package based on the OS platform being used:
30
+ * *** Debian 10+:*** ` sudo apt-get install -y libjpeg62-turbo-dev `
31
+ * *** Ubuntu 20.04+:*** ` sudo apt-get install -y libjpeg8-dev `
32
+ <br >
33
+
28
34
### Install Remaining Dependencies
29
35
Here we assume ` $VDMS_DEP_DIR ` is the directory for installing additional dependencies.
30
36
This directory is user-defined but here we use ` /dependencies ` .
31
37
These instructions assume you have full permissions to your system.
32
- If not running as root, add ` sudo ` where necessary .
38
+ *** NOTE: *** If running as *** root*** , remove ` sudo ` where applicable .
33
39
``` bash
34
40
VDMS_DEP_DIR=/dependencies # Set to any directory
35
41
BUILD_THREADS=" -j` nproc` "
36
42
mkdir -p $VDMS_DEP_DIR
37
43
```
38
44
45
+
39
46
#### Python3 Packages
40
- Here we will install the necessary Python3 packages Numpy and Protobuf 3.20.3.
47
+ Here we will install the necessary Python 3.9+ packages Numpy and Protobuf v24.2.
48
+ It is expected that you have Python3.9 or higher installed on your system.
49
+ All python calls will use Python3.9+; therefore you may find it convenient to set alias for python.
50
+ ``` bash
51
+ alias python=/usr/bin/python3
52
+ ```
53
+ *** NOTE:*** If multiple versions of Python 3 are present on your system, verify you are using Python3.9 or higher. You can specify the specific verison in above command and also set the following with your specific version: ` alias python3=/usr/bin/python3.x ` .
54
+
41
55
You can also install the coverage package if interested in running the Python unit tests.
42
56
``` bash
43
- PROTOBUF_VERSION= " 3.20.3 "
44
- pip3 install --no-cache-dir " numpy>=1.25.1" " protobuf== ${PROTOBUF_VERSION} " " coverage>=7.2.7"
57
+ python3 -m pip install --upgrade pip
58
+ python3 -m pip install --no-cache-dir " numpy>=1.25.1" " coverage>=7.2.7"
45
59
```
46
60
47
61
48
- #### CMAKE v3.26.4
49
- VDMS requires CMake v3.21+. Here we install CMake v3.26.4 .
62
+ #### ** CMAKE v3.27.2 **
63
+ VDMS requires CMake v3.21+. Here we install CMake v3.27.2 .
50
64
``` bash
51
- CMAKE_VERSION=" v3.26.4 "
65
+ CMAKE_VERSION=" v3.27.2 "
52
66
git clone --branch ${CMAKE_VERSION} https://github.com/Kitware/CMake.git $VDMS_DEP_DIR /CMake
53
67
cd $VDMS_DEP_DIR /CMake
54
68
./bootstrap
55
69
make ${BUILD_THREADS}
56
- make install
70
+ sudo make install
57
71
```
58
72
59
- ### gtest
60
- Unfortunately apt doesn't build gtest so you need to do the following:
61
- ``` bash
62
- cd /usr/src/gtest/
63
- cmake .
64
- make ${BUILD_THREADS}
65
- mv lib/libgtest* /usr/lib
66
- ```
67
73
68
- ### Faiss v1.7.3
74
+ #### ** Faiss v1.7.3**
75
+ Install the Faiss library for similarity search.
69
76
``` bash
70
77
FAISS_VERSION=" v1.7.3"
71
78
git clone --branch ${FAISS_VERSION} https://github.com/facebookresearch/faiss.git $VDMS_DEP_DIR /faiss
72
79
cd $VDMS_DEP_DIR /faiss
73
80
mkdir build && cd build
74
- cmake -DFAISS_ENABLE_GPU=OFF ..
81
+ cmake -DFAISS_ENABLE_GPU=OFF -DPython_EXECUTABLE=/usr/bin/python3 ..
75
82
make ${BUILD_THREADS}
76
- make install
83
+ sudo make install
77
84
```
78
85
79
- ### FLINNG
86
+
87
+ #### ** FLINNG**
88
+ Install the Filters to Identify Near-Neighbor Groups (FLINNG) library for similarity search.
80
89
``` bash
81
90
git clone https://github.com/tonyzhang617/FLINNG.git $VDMS_DEP_DIR /FLINNG
82
91
cd $VDMS_DEP_DIR /FLINNG
83
92
mkdir build && cd build
84
93
cmake ..
85
94
make ${BUILD_THREADS}
86
- make install
95
+ sudo make install
87
96
```
88
97
89
- ### Protobuf 3.20.3
98
+
99
+ #### ** Protobuf v24.2 (4.24.2)**
100
+ Install Protobuf (C++ and Python) which requires GoogleTest and Abseil C++ as dependencies.
90
101
``` bash
91
- PROTOBUF_VERSION=" 3.20.3"
92
- curl -L -o ${VDMS_DEP_DIR} /${PROTOBUF_VERSION} .tar.gz https://github.com/protocolbuffers/protobuf/archive/refs/tags/v${PROTOBUF_VERSION} .tar.gz
93
- cd ${VDMS_DEP_DIR} && tar -xvf ${PROTOBUF_VERSION} .tar.gz
94
- cd protobuf-${PROTOBUF_VERSION}
95
- ./autogen.sh
96
- ./configure
102
+ PROTOBUF_VERSION=" 24.2"
103
+ git clone -b v${PROTOBUF_VERSION} --recursive https://github.com/protocolbuffers/protobuf.git $VDMS_DEP_DIR /protobuf
104
+
105
+ cd $VDMS_DEP_DIR /protobuf/third_party/googletest
106
+ mkdir build && cd build
107
+ cmake -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr/local \
108
+ -DBUILD_GMOCK=ON -DCMAKE_CXX_STANDARD=17 ..
109
+ make ${BUILD_THREADS}
110
+ sudo make install
111
+ sudo ldconfig
112
+
113
+ cd $VDMS_DEP_DIR /protobuf/third_party/abseil-cpp
114
+ mkdir build && cd build
115
+ cmake -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_PREFIX_PATH=/usr/local/ -DCMAKE_INSTALL_PREFIX=/usr/local/ \
116
+ -DABSL_BUILD_TESTING=ON -DABSL_ENABLE_INSTALL=ON -DABSL_USE_EXTERNAL_GOOGLETEST=ON \
117
+ -DABSL_FIND_GOOGLETEST=ON -DCMAKE_CXX_STANDARD=17 ..
118
+ make ${BUILD_THREADS}
119
+ sudo make install
120
+
121
+ cd $VDMS_DEP_DIR /protobuf
122
+ cmake -DCMAKE_POSITION_INDEPENDENT_CODE=ON -DCMAKE_INSTALL_PREFIX=/usr/local -DCMAKE_CXX_STANDARD=17 \
123
+ -Dprotobuf_ABSL_PROVIDER=package -DCMAKE_PREFIX_PATH=/usr/local .
97
124
make ${BUILD_THREADS}
98
- make install
99
- ldconfig
125
+ sudo make install
126
+
127
+ python3 -m pip install --no-cache-dir " protobuf==4.${PROTOBUF_VERSION} "
100
128
```
101
129
102
- ### [ OpenCV] ( https://opencv.org/ ) 4.5.5
130
+
131
+ #### ** [ OpenCV] ( https://opencv.org/ ) 4.5.5**
103
132
Below are instructions for installing *** OpenCV v4.5.5*** .
104
133
``` bash
105
134
OPENCV_VERSION=" 4.5.5"
@@ -108,7 +137,7 @@ cd $VDMS_DEP_DIR/opencv
108
137
mkdir build && cd build
109
138
cmake -D BUILD_PERF_TESTS=OFF -D BUILD_TESTS=OFF ..
110
139
make ${BUILD_THREADS}
111
- make install
140
+ sudo make install
112
141
```
113
142
114
143
** Note** : When using videos, and getting the following error: "Unable to stop the stream: Inappropriate ioctl for device", you may need to include more flags when compiling OpenCV. Follow these instructions ([ source] ( https://stackoverflow.com/questions/41200201/opencv-unable-to-stop-the-stream-inappropriate-ioctl-for-device ) ):
@@ -121,20 +150,21 @@ cmake -D BUILD_PERF_TESTS=OFF -D BUILD_TESTS=OFF -D CMAKE_BUILD_TYPE=RELEASE -D
121
150
-D WITH_V4L=ON -D WITH_OPENGL=ON -D WITH_CUBLAS=ON \
122
151
-DWITH_QT=OFF -DCUDA_NVCC_FLAGS=" -D_FORCE_INLINES" ..
123
152
make ${BUILD_THREADS}
124
- make install
153
+ sudo make install
125
154
```
126
155
127
- ### Valijson v0.6
128
- This is a headers-only library, no compilation/installation necessary
156
+
157
+ #### ** Valijson v0.6**
158
+ This is a headers-only library, no compilation/installation necessary.
129
159
``` bash
130
160
VALIJSON_VERSION=" v0.6"
131
161
git clone --branch ${VALIJSON_VERSION} https://github.com/tristanpenman/valijson.git $VDMS_DEP_DIR /valijson
132
162
cd $VDMS_DEP_DIR /valijson
133
- cp -r include/* /usr/local/include/
163
+ sudo cp -r include/* /usr/local/include/
134
164
```
135
165
136
166
137
- ### [ TileDB] ( https://tiledb.io/ ) 2.14.1
167
+ #### ** [ TileDB] ( https://tiledb.io/ ) 2.14.1**
138
168
The directions below will help you install TileDB v2.14.1 from the source.
139
169
You can also follow the directions listed [ here] ( https://docs.tiledb.io/en/latest/installation.html ) .
140
170
``` bash
@@ -146,19 +176,22 @@ cd TileDB-${TILEDB_VERSION}
146
176
mkdir build && cd build
147
177
../bootstrap --prefix=/usr/local/
148
178
make ${BUILD_THREADS}
149
- make install-tiledb
179
+ sudo make install-tiledb
150
180
```
151
181
152
- ### AWS SDK CPP 1.11.0
182
+
183
+ #### ** AWS SDK CPP 1.11.0**
184
+ Use the following instructions to install AWS SDK for C++.
153
185
``` bash
154
186
AWS_SDK_VERSION=" 1.11.0"
155
187
git clone -b ${AWS_SDK_VERSION} --recurse-submodules https://github.com/aws/aws-sdk-cpp ${VDMS_DEP_DIR} /aws-sdk-cpp
156
188
mkdir -p ${VDMS_DEP_DIR} /aws-sdk-cpp/build
157
189
cd ${VDMS_DEP_DIR} /aws-sdk-cpp/build
158
190
cmake .. -DCMAKE_BUILD_TYPE=Debug -DCMAKE_PREFIX_PATH=/usr/local/ -DCMAKE_INSTALL_PREFIX=/usr/local/ -DBUILD_ONLY=" s3" -DCUSTOM_MEMORY_MANAGEMENT=OFF
159
191
make ${BUILD_THREADS}
160
- make install
192
+ sudo make install
161
193
```
194
+ <br >
162
195
163
196
## Install VDMS
164
197
This version of VDMS treats PMGD as a submodule so both libraries are compiled at one time. After entering the vdms directory, the command ` git submodule update --init --recursive ` will pull pmgd into the appropriate directory. Furthermore, Cmake is used to compile all directories.
0 commit comments