Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {
- "Modules": {
- "ObjectDetectionCoral": {
- "Name": "Object Detection (Coral)",
- "Version": "2.4.0",
- "PublishingInfo" : {
- "Description": "The object detection module uses the Coral TPU to locate and classify the objects the models have been trained on.",
- "IconURL": null,
- "Category": "Computer Vision",
- "Stack": "Python, TensorFlow-Lite",
- "License": "Apache-2.0",
- "LicenseUrl": "https://opensource.org/licenses/Apache-2.0",
- "Author": "Chris Maunder, Seth Price",
- "Homepage": "https://github.com/codeproject/CodeProject.AI-Server/",
- "BasedOn": "Coral.ai examples",
- "BasedOnUrl": "https://github.com/google-coral/pycoral/blob/master/examples/detect_image.py"
- },
- "LaunchSettings": {
- "AutoStart": true,
- "FilePath": "objectdetection_coral_adapter.py",
- "Runtime": "python3.9",
- "RuntimeLocation": "Local", // Can be Local, Shared or System
- "PostStartPauseSecs": 1, // Generally 1 if using GPU, 0 for CPU
- "Queue": "objectdetection_queue", // We make all Object detectors use the same queue.
- "Parallelism": 16 // Should probably be TPU count * 2; I don't see harm in overprovisioning threads
- },
- "ModelRequirements" : [{
- "Task": "Object Detection",
- "Architecture": "YOLOv5,YOLOv8,EfficientDet,MobileNet",
- "Format": "TensorFlow-Lite"
- }],
- "EnvironmentVariables": {
- "CPAI_CORAL_MULTI_TPU": "true",
- "CPAI_CORAL_MODEL_NAME": "MobileNet SSD", // "MobileNet SSD", "EfficientDet-Lite", "YOLOv5", "YOLOv8"
- "MODELS_DIR": "%CURRENT_MODULE_PATH%/assets",
- "MODEL_SIZE": "Small",
- "CUSTOM_MODELS_DIR": "%CURRENT_MODULE_PATH%/custom-models"
- },
- "GpuOptions" : {
- "InstallGPU": true,
- "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
- },
- "InstallOptions" : {
- "Platforms": [ "all" ], // 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": [ "2.1", "2.1.12" ], "ReleaseDate": "2023-07-11" },
- { "ModuleVersion": "1.1", "ServerVersionRange": [ "2.1", "2.1.12" ], "ReleaseDate": "2023-07-12" },
- { "ModuleVersion": "1.2", "ServerVersionRange": [ "2.1", "2.1.12" ], "ReleaseDate": "2023-07-12" },
- { "ModuleVersion": "1.3", "ServerVersionRange": [ "2.1", "2.1.12" ], "ReleaseDate": "2023-08-11", "ReleaseNotes": "installer corrections, macOS/Ubuntu support improved" },
- { "ModuleVersion": "1.4", "ServerVersionRange": [ "2.2", "2.2.4" ], "ReleaseDate": "2023-09-09", "ReleaseNotes": "Updated installer, updated TF-lite runtime" },
- { "ModuleVersion": "1.5", "ServerVersionRange": [ "2.2", "2.2.4" ], "ReleaseDate": "2023-09-16", "ReleaseNotes": "Updates to help Blue Iris users" },
- { "ModuleVersion": "1.5.1", "ServerVersionRange": [ "2.2", "2.2.4" ], "ReleaseDate": "2023-09-17", "ReleaseNotes": "Better checks for admin rights when installing" },
- { "ModuleVersion": "1.6", "ServerVersionRange": [ "2.3.0", "2.3.0" ], "ReleaseDate": "2023-10-01", "ReleaseNotes": "Updated to match new installer SDK." },
- { "ModuleVersion": "1.6.1", "ServerVersionRange": [ "2.3.1", "2.3.5" ], "ReleaseDate": "2023-10-10", "ReleaseNotes": "Updated to match new installer SDK." },
- { "ModuleVersion": "1.6.2", "ServerVersionRange": [ "2.3.1", "2.3.5" ], "ReleaseDate": "2023-10-28", "ReleaseNotes": "Improvements for situations where installer does not have admin rights." },
- { "ModuleVersion": "1.6.3", "ServerVersionRange": [ "2.3.1", "2.3.5" ], "ReleaseDate": "2023-10-28", "ReleaseNotes": "Corrections to requirements.txt for Raspberry Pi / Orange Pi." },
- { "ModuleVersion": "1.7", "ServerVersionRange": [ "2.3.5", "2.3.5" ], "ReleaseDate": "2023-11-10", "ReleaseNotes": "Improvements on the Raspberry Pi installer." },
- { "ModuleVersion": "1.7.1", "ServerVersionRange": [ "2.4.0", "2.4.0" ], "ReleaseDate": "2023-12-03", "ReleaseNotes": "Installer updates, Mesh support.", "Importance": "Minor" },
- { "ModuleVersion": "1.7.2", "ServerVersionRange": [ "2.4.1", "2.4.1" ], "ReleaseDate": "2023-12-06", "ReleaseNotes": "Updated modulesettings schema", "Importance": "Minor" },
- { "ModuleVersion": "1.7.3", "ServerVersionRange": [ "2.4.2", "2.4.7" ], "ReleaseDate": "2023-12-09", "ReleaseNotes": "Installer updates", "Importance": "Minor" },
- { "ModuleVersion": "1.7.4", "ServerVersionRange": [ "2.4.2", "2.4.7" ], "ReleaseDate": "2023-12-21", "ReleaseNotes": "Installer updates" },
- { "ModuleVersion": "1.7.5", "ServerVersionRange": [ "2.4.2", "2.4.7" ], "ReleaseDate": "2023-12-23", "ReleaseNotes": "Installer updates for Docker" },
- { "ModuleVersion": "1.8.0", "ServerVersionRange": [ "2.5.0-RC1", "2.5.0-RC5" ], "ReleaseDate": "2024-01-06", "ReleaseNotes": "Additions for dynamic explorer UI" },
- { "ModuleVersion": "2.0.0", "ServerVersionRange": [ "2.5.0-RC1", "2.5.0-RC5" ], "ReleaseDate": "2024-01-11", "ReleaseNotes": "Multi-TPU support" },
- { "ModuleVersion": "2.0.1", "ServerVersionRange": [ "2.5.0-RC1", "2.5.0-RC5" ], "ReleaseDate": "2024-01-13", "ReleaseNotes": "Changes to SDK" },
- { "ModuleVersion": "2.0.2", "ServerVersionRange": [ "2.5.0-RC6", "" ], "ReleaseDate": "2024-01-16", "ReleaseNotes": "Updated modulesettings schema" },
- { "ModuleVersion": "2.0.3", "ServerVersionRange": [ "2.5.0-RC6", "" ], "ReleaseDate": "2024-01-18", "ReleaseNotes": "Updated explorer" },
- { "ModuleVersion": "2.1.0", "ServerVersionRange": [ "2.5.0-RC6", "" ], "ReleaseDate": "2024-01-21", "ReleaseNotes": "Module performance statistics added" },
- { "ModuleVersion": "2.1.1", "ServerVersionRange": [ "2.5.0-RC6", "" ], "ReleaseDate": "2024-01-21", "ReleaseNotes": "Typo in the Linux installer corrected that was blocking installs" },
- { "ModuleVersion": "2.1.2", "ServerVersionRange": [ "2.5.0-RC6", "" ], "ReleaseDate": "2024-01-29", "ReleaseNotes": "Multi-TPU now falls back to CPU on edge library load failure" },
- { "ModuleVersion": "2.1.3", "ServerVersionRange": [ "2.5.2", "" ], "ReleaseDate": "2024-02-08", "ReleaseNotes": "Support for CodeProject.AI Server 2.5.2" },
- { "ModuleVersion": "2.1.4", "ServerVersionRange": [ "2.5.2", "" ], "ReleaseDate": "2024-02-18", "ReleaseNotes": "Added dashboard menu to allow model selection" },
- { "ModuleVersion": "2.1.5", "ServerVersionRange": [ "2.5.2", "" ], "ReleaseDate": "2024-03-12", "ReleaseNotes": "Bug fix for Multi-TPU." },
- { "ModuleVersion": "2.1.6", "ServerVersionRange": [ "2.5.2", "2.6.0" ], "ReleaseDate": "2024-03-12", "ReleaseNotes": "Improvements to Multi-TPU error handling, added YOLOv5 models." },
- { "ModuleVersion": "2.2.0", "ServerVersionRange": [ "2.6.1", "2.7.0" ], "ReleaseDate": "2024-04-01", "ReleaseNotes": "Improvements to pipelining and error handling" },
- { "ModuleVersion": "2.2.1", "ServerVersionRange": [ "2.6.1", "2.7.0" ], "ReleaseDate": "2024-04-01", "ReleaseNotes": "Improvements" },
- { "ModuleVersion": "2.2.2", "ServerVersionRange": [ "2.6.1", "2.7.0" ], "ReleaseDate": "2024-04-15", "ReleaseNotes": "Corrections to macOS 11/12 install, plus custom model list command added" },
- { "ModuleVersion": "2.3.0", "ServerVersionRange": [ "2.6.5", "2.7.0" ], "ReleaseDate": "2024-04-25", "ReleaseNotes": "Switched to CodeProject.AI 2.6.5 / CodeProject SDK" },
- { "ModuleVersion": "2.3.1", "ServerVersionRange": [ "2.6.5", "2.7.0" ], "ReleaseDate": "2024-06-21", "ReleaseNotes": "Corrected NumPy 2.0 issue" },
- { "ModuleVersion": "2.3.2", "ServerVersionRange": [ "2.6.5", "2.7.0" ], "ReleaseDate": "2024-06-26", "ReleaseNotes": "Corrections to compatibility settings" },
- { "ModuleVersion": "2.3.3", "ServerVersionRange": [ "2.6.5", "2.7.0" ], "ReleaseDate": "2024-06-26", "ReleaseNotes": "Further work on the NumPy issue" },
- { "ModuleVersion": "2.3.4", "ServerVersionRange": [ "2.6.5", "2.7.0" ], "ReleaseDate": "2024-06-26", "ReleaseNotes": "More work on the NumPy issue in RPi" },
- { "ModuleVersion": "2.4.0", "ServerVersionRange": [ "2.8.0", "" ], "ReleaseDate": "2024-08-02", "ReleaseNotes": "Updated for server 2.8" }
- ],
- "DownloadableModels":[
- { "Name": "MobileNet Large", "Filename": "objectdetection-mobilenet-large-edgetpu.zip", "Folder": "assets", "Description": "MobileNet object detection, Large", "FileSizeKb": 275800, "PreInstall": true },
- { "Name": "MobileNet Medium", "Filename": "objectdetection-mobilenet-medium-edgetpu.zip", "Folder": "assets", "Description": "MobileNet object detection, Medium", "FileSizeKb": 275800, "PreInstall": true },
- { "Name": "MobileNet Small", "Filename": "objectdetection-mobilenet-small-edgetpu.zip", "Folder": "assets", "Description": "MobileNet object detection, Small", "FileSizeKb": 275800, "PreInstall": true },
- { "Name": "MobileNet Tiny", "Filename": "objectdetection-mobilenet-tiny-edgetpu.zip", "Folder": "assets", "Description": "MobileNet object detection, Tiny", "FileSizeKb": 275800, "PreInstall": true },
- { "Name": "EfficientDet Large", "Filename": "objectdetection-efficientdet-large-edgetpu.zip", "Folder": "assets", "Description": "EfficientDet object detection, Large", "FileSizeKb": 275800, "PreInstall": false },
- { "Name": "EfficientDet Medium", "Filename": "objectdetection-efficientdet-medium-edgetpu.zip", "Folder": "assets", "Description": "EfficientDet object detection, Medium", "FileSizeKb": 275800, "PreInstall": false },
- { "Name": "EfficientDet Small", "Filename": "objectdetection-efficientdet-small-edgetpu.zip", "Folder": "assets", "Description": "EfficientDet object detection, Small", "FileSizeKb": 275800, "PreInstall": false },
- { "Name": "EfficientDet Tiny", "Filename": "objectdetection-efficientdet-tiny-edgetpu.zip", "Folder": "assets", "Description": "EfficientDet object detection, Tiny", "FileSizeKb": 275800, "PreInstall": false },
- { "Name": "YOLOv5 Large", "Filename": "objectdetection-yolov5-large-edgetpu.zip", "Folder": "assets", "Description": "YOLOv5 object detection, Large", "FileSizeKb": 275800, "PreInstall": false },
- { "Name": "YOLOv5 Medium", "Filename": "objectdetection-yolov5-medium-edgetpu.zip", "Folder": "assets", "Description": "YOLOv5 object detection, Medium", "FileSizeKb": 275800, "PreInstall": false },
- { "Name": "YOLOv5 Small", "Filename": "objectdetection-yolov5-small-edgetpu.zip", "Folder": "assets", "Description": "YOLOv5 object detection, Small", "FileSizeKb": 275800, "PreInstall": false },
- { "Name": "YOLOv5 Tiny", "Filename": "objectdetection-yolov5-tiny-edgetpu.zip", "Folder": "assets", "Description": "YOLOv5 object detection, Tiny", "FileSizeKb": 275800, "PreInstall": false },
- { "Name": "YOLOv8 Large", "Filename": "objectdetection-yolov8-large-edgetpu.zip", "Folder": "assets", "Description": "YOLOv8 object detection, Large", "FileSizeKb": 275800, "PreInstall": false },
- { "Name": "YOLOv8 Medium", "Filename": "objectdetection-yolov8-medium-edgetpu.zip", "Folder": "assets", "Description": "YOLOv8 object detection, Medium", "FileSizeKb": 275800, "PreInstall": false },
- { "Name": "YOLOv8 Small", "Filename": "objectdetection-yolov8-small-edgetpu.zip", "Folder": "assets", "Description": "YOLOv8 object detection, Small", "FileSizeKb": 275800, "PreInstall": false },
- { "Name": "YOLOv8 Tiny", "Filename": "objectdetection-yolov8-tiny-edgetpu.zip", "Folder": "assets", "Description": "YOLOv8 object detection, Tiny", "FileSizeKb": 275800, "PreInstall": false }
- ]
- },
- "UIElements" : {
- "Menus": [{
- "Label": "Model",
- "Options": [
- { "Label": "MobileNet SSD", "Setting": "CPAI_CORAL_MODEL_NAME", "Value": "MobileNet SSD" },
- { "Label": "EfficientDet Lite", "Setting": "CPAI_CORAL_MODEL_NAME", "Value": "EfficientDet-Lite" },
- { "Label": "YOLOv5", "Setting": "CPAI_CORAL_MODEL_NAME", "Value": "YOLOv5" },
- { "Label": "YOLOv8", "Setting": "CPAI_CORAL_MODEL_NAME", "Value": "YOLOv8" }
- ]
- },
- {
- "Label": "Model Size",
- "Options": [
- { "Label": "Tiny", "Setting": "MODEL_SIZE", "Value": "tiny" },
- { "Label": "Small", "Setting": "MODEL_SIZE", "Value": "small" },
- { "Label": "Medium", "Setting": "MODEL_SIZE", "Value": "medium" },
- { "Label": "Large", "Setting": "MODEL_SIZE", "Value": "large" }
- ]
- },
- {
- "Label": "Multi-TPU support",
- "Options": [
- { "Label": "Enable", "Setting": "CPAI_CORAL_MULTI_TPU", "Value": "True" },
- { "Label": "Disable", "Setting": "CPAI_CORAL_MULTI_TPU", "Value": "False" }
- ]
- }]
- },
- "RouteMaps": [
- {
- "Name": "Object Detector (Coral.AI)",
- "Route": "vision/detection",
- "Method": "POST",
- "Command": "detect",
- "Description": "Detects multiple objects in an image.",
- "Inputs": [
- {
- "Name": "image",
- "Type": "File",
- "Description": "The HTTP file object (image) to be analyzed."
- },
- {
- "Name": "min_confidence",
- "Type": "Float",
- "Description": "The minimum confidence level for an object will be detected. In the range 0.0 to 1.0. Default 0.4.",
- "DefaultValue": 0.4,
- "MinValue": 0.0,
- "MaxValue": 1.0
- }
- ],
- "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, label 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": "Custom Object Detector (Coral.AI)",
- "Route": "vision/custom",
- "Method": "POST",
- "Command": "custom",
- "Description": "Detects objects based on YOLO PyTorch models. Models are stored in the /ObjectDetectionCoral/assets directory, and to make a call to a specific model use /vision/custom/model-name, where 'model-name' is the name of the model's file",
- "Inputs": [
- {
- "Name": "image",
- "Type": "File",
- "Description": "The HTTP file object (image) to be analyzed."
- },
- {
- "Name": "min_confidence",
- "Type": "Float",
- "Description": "The minimum confidence level for an object will be detected. In the range 0.0 to 1.0. Default 0.4."
- }
- ],
- "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, label and confidence."
- },
- {
- "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": "Object Detector List Custom Models (Coral.AI)",
- "Route": "vision/custom/list",
- "Method": "POST",
- "Command": "list-custom",
- "Description": "Returns a list of models available.",
- "Inputs": [],
- "Outputs": [
- {
- "Name": "success",
- "Type": "Boolean",
- "Description": "True if successful."
- },
- {
- "Name": "models",
- "Type": "String",
- "Description": "An array of strings containing the names of the models installed."
- }
- ]
- }
- ]
- }
- }
- }
Add Comment
Please, Sign In to add comment