SqueezeBrains SDK 1.18
deep_cortex_detect.c File Reference

Tutorial 14 - Deep Cortex - How to elaborate images. More...

#include "../common/common.h"
Include dependency graph for deep_cortex_detect.c:

Go to the source code of this file.

Functions

int main (void)
 

Detailed Description

Tutorial 14 - Deep Cortex - How to elaborate images.

Attention
To execute this tutorial you need:
  • to have installed the SB Deep Learning Framework
  • to ensure that path to SB Deep Learning Framework is included in the PATH enviroment variable (LD_LIBRARY_PATH in Linux) or in any case to be visible by the program. In Windows it is possible to specify additional paths as argument to the sb_init_dl function.

In this tutorial you can find what do you need to elaborate images in your system with a minimal integration of SB library. To elaborate an image you have to call the function sb_project_detection and get the results with the function sb_project_get_res .
In a deep cortex project, the function sb_project_detection requires the following arguments at input:

  1. a SB_HANDLE of the Deep Cortex project.
    You can load the handle of the deep cortex project with the function sb_project_load .
  2. a sb_t_image, the image to be processed.
    To create the image you can choose between two different modes depending if you already have the raw image in the memory or not:
  3. a sb_t_samples list, that specify the ground truth of the image, i.e. the model associated to the image. The samples list must contain at most one sample. This information is not mandatory. If no samples list is passed to the function the result of the detection is not compared to the ground truth and the found model sample is classified as SB_TRUTH_UNDEFINED .
    See also
    sb_init
    sb_init_dl
    sb_release
    sb_get_info
    sb_license_get_info
    sb_folder_load
    sb_folder_destroy
    sb_image_load
    sb_image_destroy
    sb_image_create_header
    sb_image_set_data
    sb_solution_get_info
    sb_solution_destroy_info
    sb_project_load
    sb_project_destroy
    sb_project_get_par
    sb_project_set_par
    sb_project_detection
    sb_project_get_res
    sb_res_destroy

Definition in file deep_cortex_detect.c.

Function Documentation

◆ main()

int main ( void  )

In the following the list of the program steps:

  1. Initialization of the SqueezeBrains library.
  2. Initialization of the Squeezebrains deep learning modules.
  3. Wait until the license is active.
  4. Get the solution information.
  5. Load the Deep Cortex project from solution file.
  6. Set parameters
    • set device for elaboration
  7. Load the image from file.
  8. Elaborate the image.
  9. Get the results.
  10. Destroy the handles.
  11. Release the library.

Definition at line 49 of file deep_cortex_detect.c.

Here is the call graph for this function: