You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/UserGuide/Master/Table/Deployment-and-Maintenance/AINode_Deployment_apache.md
+45-81Lines changed: 45 additions & 81 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -24,10 +24,10 @@
24
24
25
25
### 1.1 Capability Introduction
26
26
27
-
AINode is the third type of endogenous node provided by IoTDB after the Configurable Node and DataNode. This node extends its ability to perform machine learning analysis on time series by interacting with the DataNode and Configurable Node of the IoTDB cluster. It supports the introduction of existing machine learning models from external sources for registration and the use of registered models to complete time series analysis tasks on specified time series data through simple SQL statements. The creation, management, and inference of models are integrated into the database engine. Currently, machine learning algorithms or self-developed models are available for common time series analysis scenarios, such as prediction and anomaly detection.
27
+
AINode is the third type of endogenous node provided by IoTDB after the Configurable Node and DataNode. This node extends its ability to perform machine learning analysis on time series by interacting with the DataNode and Configurable Node of the IoTDB cluster. It supports the introduction of existing machine learning models from external sources for registration and the use of registered models to complete time series analysis tasks on specified time series data through simple SQL statements. The creation, management, and inference of models are integrated into the database engine. Currently, machine learning algorithms or self-developed models are available for common time series analysis scenarios, such as prediction and anomaly detection.
28
28
29
29
### 1.2 Delivery Method
30
-
It is an additional package outside the IoTDB cluster, with independent installation.
30
+
AINode is an additional package outside the IoTDB cluster, with independent installation.
31
31
32
32
### 1.3 Deployment mode
33
33
<div >
@@ -39,62 +39,47 @@
39
39
40
40
### 2.1 Get installation package
41
41
42
-
Unzip and install the package
43
-
`(apache-iotdb-<version>-ainode-bin.zip)`, The directory structure after unpacking the installation package is as follows:
- Python version between 3.9 and 3.12, with pip and venv tools installed;
60
+
- Python version between 3.9 and 3.12, with pip and venv tools installed;
60
61
61
62
## 3. Installation steps
62
63
63
64
### 3.1 Install AINode
64
65
65
66
66
-
1. Ensure Python version is between 3.9 and 3.12:
67
+
1. Ensure Python version is between 3.9 and 3.12:
67
68
```shell
68
-
python --version
69
+
python --version
69
70
# or
70
71
python3 --version
71
72
```
72
73
73
-
2. Download and import AINode into a dedicated folder, switch to the folder, and unzip the package:
74
+
2. Download and import AINode into a dedicated folder, switch to the folder, and unzip the package:
74
75
```shell
75
-
unzip timechodb-2.0.5.1-ainode-bin.zip
76
-
```
77
-
3. Create a virtual environment (execute in the ainode directory):
78
-
79
-
```shell
80
-
python3 -m venv venv
81
-
```
82
-
83
-
4. Activate the virtual environment:
84
-
85
-
```shell
86
-
source venv/bin/activate
87
-
```
88
-
5. Update pip and install AINode dependencies:
89
-
```shell
90
-
python -m pip install --upgrade pip
91
-
poetry lock
92
-
poetry install
93
-
```
76
+
unzip apache-iotdb-<version>-ainode-bin.zip
77
+
```
94
78
95
79
### 3.2 Configuration item modification
96
80
97
81
AINode supports modifying some necessary parameters. You can find the following parameters in the `conf/iotdb-ainode.properties` file and make persistent modifications to them:
| cluster_name | Identifier of the cluster AINode joins | string | defaultCluster |
@@ -110,13 +95,19 @@ AINode supports modifying some necessary parameters. You can find the following
110
95
| ain_models_dir | Path to store model files for AINode (relative path starts from OS-dependent directory; absolute path is recommended) | String | data/AINode/models |
111
96
| ain_thrift_compression_enabled | Whether to enable Thrift compression for AINode (0=disabled, 1=enabled) | Boolean | 0 |
112
97
113
-
### 3.3 Start AINode
98
+
### 3.3 Importing Weight Files
99
+
100
+
> Offline environment only (Online environments can skip this step)
101
+
>
102
+
Contact Timecho team to obtain the model weight files, then place them in the /IOTDB_AINODE_HOME/data/ainode/models/weights/ directory.
103
+
104
+
### 3.4 Start AINode
114
105
115
-
After completing the deployment of Seed Config Node, the registration and inference functions of the model can be supported by adding AINode nodes. After specifying the information of the IoTDB cluster in the configuration file, the corresponding instruction can be executed to start AINode and join the IoTDB cluster。
106
+
After completing the deployment of Seed Config Node, the registration and inference functions of the model can be supported by adding AINode nodes. After specifying the information of the IoTDB cluster in the configuration file, the corresponding instruction can be executed to start AINode and join the IoTDB cluster。
116
107
117
-
####Networking environment startup
108
+
- Networking environment startup
118
109
119
-
##### Start command
110
+
Start command
120
111
121
112
```shell
122
113
# Start command
@@ -134,25 +125,7 @@ AINode supports modifying some necessary parameters. You can find the following
During the startup process of AINode, the new AINode will be automatically added to the IoTDB cluster. After starting AINode, you can enter SQL in the command line to query. If you see an AINode node in the cluster and its running status is Running (as shown below), it indicates successful joining.
If you need to stop a running AINode node, execute the corresponding shutdown script.
174
147
175
-
#### Stop command
148
+
Stop command
176
149
177
150
```shell
178
151
# Linux / MacOS
@@ -182,15 +155,6 @@ If you need to stop a running AINode node, execute the corresponding shutdown sc
182
155
sbin\stop-ainode.bat
183
156
```
184
157
185
-
#### Example
186
-
187
-
```shell
188
-
# Linux / MacOS
189
-
bash sbin/stop-ainode.sh
190
-
191
-
# Windows
192
-
sbin\stop-ainode.bat
193
-
```
194
158
After stopping AINode, you can still see AINode nodes in the cluster, whose running status is UNKNOWN (as shown below), and the AINode function cannot be used at this time.
195
159
196
160
```shell
@@ -209,9 +173,9 @@ If you need to restart the node, you need to execute the startup script again.
209
173
210
174
### 4.1 An error occurs when starting AINode stating that the venv module cannot be found
211
175
212
-
When starting AINode using the default method, a Python virtual environment will be created in the installation package directory and dependencies will be installed, so it is required to install the venv module. Generally speaking, Python 3.10 and above versions come with built-in VenV, but for some systems with built-in Python environments, this requirement may not be met. There are two solutions when this error occurs (choose one or the other):
176
+
When starting AINode using the default method, a Python virtual environment will be created in the installation package directory and dependencies will be installed, so it is required to install the venv module. Generally speaking, Python 3.10 and above versions come with built-in VenV, but for some systems with built-in Python environments, this requirement may not be met. There are two solutions when this error occurs (choose one or the other):
213
177
214
-
To install the Venv module locally, taking Ubuntu as an example, you can run the following command to install the built-in Venv module in Python. Or install a Python version with built-in Venv from the Python official website.
178
+
To install the Venv module locally, taking Ubuntu as an example, you can run the following command to install the built-in Venv module in Python. Or install a Python version with built-in Venv from the Python official website.
215
179
216
180
```shell
217
181
apt-get install python3.10-venv
@@ -221,14 +185,14 @@ Install version 3.10.0 of venv into AINode in the AINode path.
221
185
```shell
222
186
../Python-3.10.0/python -m venv venv(Folder Name)
223
187
```
224
-
When running the startup script, use ` -i ` to specify an existing Python interpreter path as the running environment for AINode, eliminating the need to create a new virtual environment.
188
+
When running the startup script, use ` -i ` to specify an existing Python interpreter path as the running environment for AINode, eliminating the need to create a new virtual environment.
225
189
226
-
### 4.2 The SSL module in Python is not properly installed and configured to handle HTTPS resources
190
+
### 4.2 The SSL module in Python is not properly installed and configured to handle HTTPS resources
227
191
WARNING: pip is configured with locations that require TLS/SSL, however the ssl module in Python is not available.
228
192
You can install OpenSSLS and then rebuild Python to solve this problem
229
193
> Currently Python versions 3.6 to 3.9 are compatible with OpenSSL 1.0.2, 1.1.0, and 1.1.1.
230
194
231
-
Python requires OpenSSL to be installed on our system, the specific installation method can be found in [link](https://stackoverflow.com/questions/56552390/how-to-fix-ssl-module-in-python-is-not-available-in-centos)
195
+
Python requires OpenSSL to be installed on our system, the specific installation method can be found in [link](https://stackoverflow.com/questions/56552390/how-to-fix-ssl-module-in-python-is-not-available-in-centos)
0 commit comments