SOD C/C++ API - RealNet Architecture


int sod_realnet_load_model_from_mem(sod_realnet *pNet, const void * pModel, unsigned int nBytes, sod_realnet_model_handle *pOutHandle);


Register & Load a RealNet model form memory. After successful registration, the model is ready for detection and prediction tasks for example via sod_realnet_detect(). Pre-trained RealNet models can be downloaded from or trained via the RealNet training interfaces.


sod_realnet    *pNet

A pointer to a valid sod_realnet object obtained from a prior successful call to sod_realnet_create().

const void    *pModel

Memory buffer holding the target model to load.

unsigned int    nBytes

Size of the memory buffer.

sod_realnet_model_handle    *pOutHandle

OUT/Optional: Unique ID assigned by the RealNet container to identify this model on successful registration. This handle is required by the sod_realnet_model_config() interface to alter the model default configuration. Learn more about this handle here.

Return Value

SOD_OK is returned on success. Any other code indicates failure.


Checkout the introduction course, the C/C++ samples on the download page or refer to the SOD Github Repository.

See also