_object_detection = make_unique<MobilenetV1Ssd>(task_type);
else if (task_type == ObjectDetectionTaskType::MOBILENET_V2_SSD)
_object_detection = make_unique<MobilenetV2Ssd>(task_type);
- else if (task_type == ObjectDetectionTaskType::OD_PLUGIN)
+ else if (task_type == ObjectDetectionTaskType::OD_PLUGIN || task_type == ObjectDetectionTaskType::FD_PLUGIN)
_object_detection = make_unique<ObjectDetectionExternal>(task_type);
// TODO.
}
int model_type = 0;
- if (model_name_str == "OD_PLUGIN") {
- model_type = static_cast<int>(ObjectDetectionTaskType::OD_PLUGIN);
+ if (model_name_str == "OD_PLUGIN" || model_name_str == "FD_PLUGIN") {
+ if (model_name_str == "OD_PLUGIN")
+ model_type = static_cast<int>(ObjectDetectionTaskType::OD_PLUGIN);
+ if (model_name_str == "FD_PLUGIN")
+ model_type = static_cast<int>(ObjectDetectionTaskType::FD_PLUGIN);
// In case of using plugin module, model information will be managed by the plugin module.
// Therefore, create plugin instance now.
{
namespace machine_learning
{
-typedef IObjectDetection *create_t(void);
+typedef IObjectDetection *create_t(ObjectDetectionTaskType task_type);
typedef void destroy_t(IObjectDetection *);
ObjectDetectionExternal::ObjectDetectionExternal(ObjectDetectionTaskType task_type)
throw InvalidOperation("Fail to get symbol from plugin library.");
}
- _object_detection_plugin = createPlugin();
+ _object_detection_plugin = createPlugin(task_type);
if (_object_detection_plugin == NULL) {
dlclose(_plugin_handle);
_plugin_handle = NULL;