-
Notifications
You must be signed in to change notification settings - Fork 3
/
modulesettings.json
252 lines (239 loc) · 13.4 KB
/
modulesettings.json
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
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
{
"Modules": {
"ALPR": {
"Name": "License Plate Reader",
"Version": "3.3.4",
"PublishingInfo" : {
"Description": "Detects and readers single-line and multi-line license plates using YOLO object detection and the PaddleOCR toolkit",
"IconURL": null,
"Category": "Computer Vision",
"Stack": "Python, PaddlePaddle",
"License": "SSPL",
"LicenseUrl": "https://www.mongodb.com/licensing/server-side-public-license",
"Author": "Mike Lud",
"Homepage": null,
"BasedOn": null,
"BasedOnUrl": null
},
"LaunchSettings": {
"AutoStart": true,
"FilePath": "ALPR_adapter.py",
"Runtime": "python3.8",
"RuntimeLocation": "Local", // Can be Local, Shared or System
"Queue": "alpr_queue", // default is lower(module_id) + '_queue'
"Parallelism": 0 // 0 = Default = number of CPUs / 2
},
"EnvironmentVariables": {
"MIN_COMPUTE_CAPABILITY": "6",
"MIN_CUDNN_VERSION": "7",
"PLATE_CONFIDENCE": 0.7, // Confidence required in detecting a plate in the first place
"PLATE_ROTATE_DEG": 0, // If non-zero, rotate plate before OCR (+ve = counterclockwise)
"AUTO_PLATE_ROTATE": true,
"PLATE_RESCALE_FACTOR": 2,
"OCR_OPTIMIZATION": true,
"OCR_OPTIMAL_CHARACTER_HEIGHT": 60,
"OCR_OPTIMAL_CHARACTER_WIDTH": 30,
"REMOVE_SPACES": false,
"SAVE_CROPPED_PLATE": false,
"ROOT_PATH": "%ROOT_PATH%",
"CROPPED_PLATE_DIR": "%ROOT_PATH%/Server/wwwroot"
},
"GpuOptions" : {
"InstallGPU": false, // PaddlePaddle-GPU only installs easily on Windows (though with issues on older cards)
"EnableGPU": true, // Will be coerced to false if InstallGPU = false
"AcceleratorDeviceName": null, // = default
"HalfPrecision": "enable", // 'Force', 'Enable', 'Disable': whether to force on, allow, or disable half-precision ops
"PostStartPauseSecs": 1 // Generally 1 if using GPU, 0 for CPU
},
"InstallOptions" : {
"Platforms": [ "all", "!windows-arm64" ], // The platforms this module can and cannot be installed on
"ModuleReleases": [ // Which server version is compatible with each version of this module.
{ "ModuleVersion": "1.0", "ServerVersionRange": [ "1.0", "2.0.8" ], "ReleaseDate": "2022-11-01" },
{ "ModuleVersion": "2.1", "ServerVersionRange": [ "2.0.9", "2.0.9" ], "ReleaseDate": "2022-12-01" },
{ "ModuleVersion": "2.2", "ServerVersionRange": [ "2.1", "2.1.12" ], "ReleaseDate": "2023-03-20" },
{ "ModuleVersion": "2.3", "ServerVersionRange": [ "2.1", "2.1.12" ], "ReleaseDate": "2023-04-20", "ReleaseNotes": "Updated module settings", "Importance": "Minor" },
{ "ModuleVersion": "2.4", "ServerVersionRange": [ "2.1", "2.1.12" ], "ReleaseDate": "2023-05-10", "ReleaseNotes": "PaddlePaddle install more reliable", "Importance": "Minor" },
{ "ModuleVersion": "2.5", "ServerVersionRange": [ "2.1", "2.1.12" ], "ReleaseDate": "2023-06-04", "ReleaseNotes": "Updated PaddlePaddle" },
{ "ModuleVersion": "2.6", "ServerVersionRange": [ "2.2", "2.2.4" ], "ReleaseDate": "2023-09-09", "ReleaseNotes": "Updated installer" },
{ "ModuleVersion": "2.7", "ServerVersionRange": [ "2.3.0", "2.3.0" ], "ReleaseDate": "2023-10-01", "ReleaseNotes": "Updated to match new installer SDK. Now works on Raspberry Pi." },
{ "ModuleVersion": "2.7.1", "ServerVersionRange": [ "2.3.1", "2.3.5" ], "ReleaseDate": "2023-10-10", "ReleaseNotes": "Updated to match new installer SDK." },
{ "ModuleVersion": "2.7.2", "ServerVersionRange": [ "2.3.1", "2.4.0" ], "ReleaseDate": "2023-10-10", "ReleaseNotes": "LibSSL install correction." },
{ "ModuleVersion": "2.7.3", "ServerVersionRange": [ "2.3.5", "2.4.0" ], "ReleaseDate": "2023-11-06", "ReleaseNotes": "Installer updates", "Importance": "Minor" },
{ "ModuleVersion": "2.7.4", "ServerVersionRange": [ "2.4.1", "2.4.1" ], "ReleaseDate": "2023-12-06", "ReleaseNotes": "Updated modulesettings schema, new route", "Importance": "Minor" },
{ "ModuleVersion": "2.7.5", "ServerVersionRange": [ "2.4.2", "2.4.7" ], "ReleaseDate": "2023-12-09", "ReleaseNotes": "Installer updates", "Importance": "Minor" },
{ "ModuleVersion": "2.8.0", "ServerVersionRange": [ "2.5.0-RC1", "2.5.0-RC5" ], "ReleaseDate": "2024-01-06", "ReleaseNotes": "Additions for dynamic explorer UI" },
{ "ModuleVersion": "2.8.1", "ServerVersionRange": [ "2.5.0-RC1", "2.5.0-RC5" ], "ReleaseDate": "2024-01-13", "ReleaseNotes": "Changes to SDK" },
{ "ModuleVersion": "2.8.2", "ServerVersionRange": [ "2.5.0-RC6", "2.7.0" ], "ReleaseDate": "2024-01-16", "ReleaseNotes": "Updated modulesettings schema" },
{ "ModuleVersion": "2.8.3", "ServerVersionRange": [ "2.5.0-RC6", "2.7.0" ], "ReleaseDate": "2024-01-18", "ReleaseNotes": "Updated explorer" },
{ "ModuleVersion": "2.9.0", "ServerVersionRange": [ "2.5.0-RC6", "2.7.0" ], "ReleaseDate": "2024-01-21", "ReleaseNotes": "Module performance statistics added" },
{ "ModuleVersion": "2.9.1", "ServerVersionRange": [ "2.5.2", "2.7.0" ], "ReleaseDate": "2024-02-08", "ReleaseNotes": "Support for CodeProject.AI Server 2.5.2+" },
{ "ModuleVersion": "3.0.0", "ServerVersionRange": [ "2.5.2", "2.7.0" ], "ReleaseDate": "2024-02-11", "ReleaseNotes": "Updated text recognition model to PP-OCRv4 and added AI auto rotation" },
{ "ModuleVersion": "3.0.1", "ServerVersionRange": [ "2.5.2", "2.7.0" ], "ReleaseDate": "2024-02-13", "ReleaseNotes": "Corrected NoneType error when auto-rotating plates" },
{ "ModuleVersion": "3.0.2", "ServerVersionRange": [ "2.5.2", "2.7.0" ], "ReleaseDate": "2024-02-18", "ReleaseNotes": "Added dashboard menu to set plate confidence, auto-rotate and OCR optimisation", "Importance": "Minor" },
{ "ModuleVersion": "3.0.3", "ServerVersionRange": [ "2.5.2", "2.7.0" ], "ReleaseDate": "2024-02-28", "ReleaseNotes": "Added dashboard menu to set remove spaces and save cropped plate", "Importance": "Minor" },
{ "ModuleVersion": "3.1.0", "ServerVersionRange": [ "2.5.2", "2.7.0" ], "ReleaseDate": "2024-02-28", "ReleaseNotes": "Updated for server 2.6" },
{ "ModuleVersion": "3.2.0", "ServerVersionRange": [ "2.6.5", "2.7.0" ], "ReleaseDate": "2024-04-25", "ReleaseNotes": "Updated to CodeProject.AI Server 2.6.5" }, // was 2.7
{ "ModuleVersion": "3.2.1", "ServerVersionRange": [ "2.6.5", "2.7.0" ], "ReleaseDate": "2024-06-21", "ReleaseNotes": "Corrected Numpy 2.0 issue" },
{ "ModuleVersion": "3.2.2", "ServerVersionRange": [ "2.6.5", "2.7.0" ], "ReleaseDate": "2024-06-26", "ReleaseNotes": "Corrections to compatibility settings" },
{ "ModuleVersion": "3.3.0", "ServerVersionRange": [ "2.8.0", "2.9.0" ], "ReleaseDate": "2024-08-02", "ReleaseNotes": "Updated for server 2.8" },
{ "ModuleVersion": "3.3.1", "ServerVersionRange": [ "2.8.0", "2.9.3" ], "ReleaseDate": "2024-11-23", "ReleaseNotes": "Improved cuDNN check" },
{ "ModuleVersion": "3.3.2", "ServerVersionRange": [ "2.9.4", "" ], "ReleaseDate": "2024-11-26", "ReleaseNotes": "Support for dual Ubuntu/Debian install" },
{ "ModuleVersion": "3.3.3", "ServerVersionRange": [ "2.9.4", "" ], "ReleaseDate": "2024-11-29", "ReleaseNotes": "Corrections for CUDA 11.8" },
{ "ModuleVersion": "3.3.4", "ServerVersionRange": [ "2.9.4", "" ], "ReleaseDate": "2024-12-11", "ReleaseNotes": "Corrections for Linux arm64" }
]
},
"ModelRequirements" : [{
"Task": "OCR",
"Architecture": "PP-OCRv3",
"Format": "PaddlePaddle"
}],
"UIElements" : {
"Menus": [
{
"Label": "Plate Confidence",
"Options": [
{ "Label": "50%", "Setting": "PLATE_CONFIDENCE", "Value": "0.50" },
{ "Label": "55%", "Setting": "PLATE_CONFIDENCE", "Value": "0.55" },
{ "Label": "60%", "Setting": "PLATE_CONFIDENCE", "Value": "0.60" },
{ "Label": "65%", "Setting": "PLATE_CONFIDENCE", "Value": "0.65" },
{ "Label": "70% (Default)", "Setting": "PLATE_CONFIDENCE", "Value": "0.70" },
{ "Label": "75%", "Setting": "PLATE_CONFIDENCE", "Value": "0.75" },
{ "Label": "80%", "Setting": "PLATE_CONFIDENCE", "Value": "0.80" }
]
},
{
"Label": "Auto Plate Rotation",
"Options": [
{ "Label": "Enable (Default)", "Setting": "AUTO_PLATE_ROTATE", "Value": "true" },
{ "Label": "Disable", "Setting": "AUTO_PLATE_ROTATE", "Value": "false" }
]
},
{
"Label": "OCR Optimization",
"Options": [
{ "Label": "Enable (Default)", "Setting": "OCR_OPTIMIZATION", "Value": "true" },
{ "Label": "Disable", "Setting": "OCR_OPTIMIZATION", "Value": "false" }
]
},
{
"Label": "Save Cropped Plate",
"Options": [
{ "Label": "Enable", "Setting": "SAVE_CROPPED_PLATE", "Value": "true" },
{ "Label": "Disable (Default)", "Setting": "SAVE_CROPPED_PLATE", "Value": "false" }
]
},
{
"Label": "Remove Spaces",
"Options": [
{ "Label": "Enable", "Setting": "REMOVE_SPACES", "Value": "true" },
{ "Label": "Disable (Default)", "Setting": "REMOVE_SPACES", "Value": "false" }
]
}]
},
"RouteMaps": [
{
"Name": "License Plate Reader",
"Route": "vision/alpr",
"Method": "POST",
"Command": "alpr",
"Description": "Detects and reads the characters in license plates detected within an image",
"Inputs": [
{
"Name": "upload",
"Type": "File",
"Description": "The image to ALPR."
}
],
"Outputs": [
{
"Name": "success",
"Type": "Boolean",
"Description": "True if successful."
},
{
"Name": "message",
"Type": "String",
"Description": "A summary of the inference operation."
},
{
"Name": "error",
"Type": "String",
"Description": "(Optional) An description of the error if success was false."
},
{
"Name": "predictions",
"Type": "Object[]",
"Description": "An array of objects with the x_max, x_min, max, y_min bounds of the plate, label, the plate chars and confidence."
},
{
"Name": "count",
"Type": "Integer",
"Description": "The number of objects found."
},
{
"Name": "inferenceMs",
"Type": "Integer",
"Description": "The time (ms) to perform the AI inference."
},
{
"Name": "processMs",
"Type": "Integer",
"Description": "The time (ms) to process the image (includes inference and image manipulation operations)."
}
]
},
{
"Name": "License Plate Reader, Legacy route",
"Route": "image/alpr",
"Method": "POST",
"Command": "alpr",
"Description": "Detects the characters in license plates detected within an image",
"Inputs": [
{
"Name": "upload",
"Type": "File",
"Description": "The image to ALPR."
}
],
"Outputs": [
{
"Name": "success",
"Type": "Boolean",
"Description": "True if successful."
},
{
"Name": "message",
"Type": "String",
"Description": "A summary of the inference operation."
},
{
"Name": "error",
"Type": "String",
"Description": "(Optional) An description of the error if success was false."
},
{
"Name": "predictions",
"Type": "Object[]",
"Description": "An array of objects with the x_max, x_min, max, y_min bounds of the plate, label, the plate chars and confidence."
},
{
"Name": "count",
"Type": "Integer",
"Description": "The number of objects found."
},
{
"Name": "inferenceMs",
"Type": "Integer",
"Description": "The time (ms) to perform the AI inference."
},
{
"Name": "processMs",
"Type": "Integer",
"Description": "The time (ms) to process the image (includes inference and image manipulation operations)."
}
]
}
]
}
}
}