JeVois  1.20
JeVois Smart Embedded Machine Vision Toolkit
Share this page:
jevois::dnn Namespace Reference

Namespaces

 network
 
 pipeline
 
 postprocessor
 
 preprocessor
 
 yunet
 

Classes

class  Network
 Abstract class to represent a neural network. More...
 
class  NetworkHailo
 Wrapper around an DNN neural network running on the Hailo8 neural accelerator. More...
 
class  NetworkNPU
 Wrapper around a DNN neural network running on Amlogic A311D NPU accelerator (Verisilicon) More...
 
class  NetworkONNX
 Wrapper around an ONNX-Runtime neural network. More...
 
class  NetworkOpenCV
 Wrapper around an OpenCV DNN neural network. More...
 
class  NetworkPython
 Wrapper around an DNN neural network invoked through python. More...
 
class  NetworkPythonImpl
 
class  NetworkTPU
 Wrapper around a Coral TPU neural network. More...
 
class  Pipeline
 Neural processing pipeline. More...
 
class  PostProcessor
 Post-Processor for neural network pipeline. More...
 
class  PostProcessorClassify
 Post-Processor for neural network pipeline. More...
 
class  PostProcessorDetect
 Post-Processor for neural network pipeline. More...
 
class  PostProcessorDetectYOLO
 Post-Processor sub-component for raw YOLO decoding. More...
 
class  PostProcessorDetectYOLOforPython
 YOLO post-processor exposed to python. More...
 
class  PostProcessorPython
 Post-Processor for neural network pipeline. More...
 
class  PostProcessorPythonImpl
 
class  PostProcessorSegment
 Post-Processor for neural network pipeline. More...
 
class  PostProcessorStub
 Post-Processor for neural network pipeline. More...
 
class  PostProcessorYuNet
 Post-Processor for YuNet face landmarks detector. More...
 
class  PreProcessor
 Pre-Processor for neural network pipeline. More...
 
class  PreProcessorBlob
 Pre-Processor for neural network pipeline. More...
 
class  PreProcessorForPython
 Pre-Processor interface exposed to the python side. More...
 
class  PreProcessorPython
 Pre-Processor for neural network pipeline written in python. More...
 
class  PreProcessorPythonImpl
 

Functions

std::map< int, std::string > readLabelsFile (std::string const &fname)
 Read a label file. More...
 
std::string getLabel (std::map< int, std::string > const &labels, int id)
 Get a label from an id. More...
 
int stringToRGBA (std::string const &label, unsigned char alpha=128)
 Compute a color from a label name. More...
 
void topK (float const *pfProb, float *pfMaxProb, uint32_t *pMaxClass, uint32_t outputCount, uint32_t topNum)
 Get top-k entries and their indices. More...
 
std::string shapestr (cv::Mat const &m)
 Get a string of the form: "nD AxBxC... TYPE" from an n-dimensional cv::Mat with data type TYPE. More...
 
std::string shapestr (TfLiteTensor const *t)
 Get a string of the form: "nD AxBxC... TYPE" from an n-dimensional TfLiteTensor with data type TYPE. More...
 
std::string shapestr (vsi_nn_tensor_attr_t const &attr)
 Get a string of the form: "nD AxBxC... TYPE" from an n-dimensional NPU tensor with data type TYPE. More...
 
std::vector< size_t > strshape (std::string const &str)
 Get a vector of size_t from a string containing AxBxC... More...
 
int tf2cv (TfLiteType t)
 Convert from TensorFlow data type to OpenCV. More...
 
vsi_nn_type_e tf2vsi (TfLiteType t)
 Convert from TensorFlow data type to vsi_nn. More...
 
int vsi2cv (vsi_nn_type_e t)
 Convert from NPU data type to OpenCV. More...
 
void clamp (cv::Rect &r, int width, int height)
 Clamp a rectangle to within given image width and height. More...
 
void clamp (cv::Rect2f &r, float width, float height)
 Clamp a rectangle to within given image width and height. More...
 
std::vector< vsi_nn_tensor_attr_t > parseTensorSpecs (std::string const &specs)
 Parse tensor specification. More...
 
cv::Mat attrmat (vsi_nn_tensor_attr_t const &attr, void *dataptr=nullptr)
 Construct a cv::Mat from attr and possibly data pointer. More...
 
std::vector< int > attrdims (vsi_nn_tensor_attr_t const &attr)
 Get a tensor dims as a vector of int, useful to construct a matching cv::Mat. More...
 
cv::Size attrsize (vsi_nn_tensor_attr_t const &attr)
 Get a tensor's (width, height) size in cv::Size format, skipping over other dimensions. More...
 
std::string attrstr (vsi_nn_tensor_attr_t const &attr)
 Get a string describing the specs of a tensor, including quantification specs (not provided by shapestr()) More...
 
bool attrmatch (vsi_nn_tensor_attr_t const &attr, cv::Mat const &blob)
 Check that a cv::Mat blob matches exactly the spec of an attr. More...
 
vsi_nn_tensor_attr_t tensorattr (TfLiteTensor const *t)
 Get tensor shape and type attributes for a TensorFlow Lite tensor. More...
 
size_t softmax (float const *input, size_t const n, size_t const stride, float const fac, float *output, bool maxonly)
 Apply softmax to a float vector. More...
 
cv::Mat quantize (cv::Mat const &m, vsi_nn_tensor_attr_t const &attr)
 Quantize from float32 to fixed-point according to the quantization spec in attr. More...
 
cv::Mat dequantize (cv::Mat const &m, vsi_nn_tensor_attr_t const &attr)
 Dequantize an output to float32 according to the quantization spec in attr. More...
 
size_t effectiveDims (cv::Mat const &m)
 Returns the number of non-unit dims in a cv::Mat. More...
 
std::string shapestr (hailo_vstream_info_t const &vi)
 Get a string of the form: "nD AxBxC... TYPE" from an n-dimensional Hailo tensor with data type TYPE. More...
 
vsi_nn_tensor_attr_t tensorattr (hailo_vstream_info_t const &vi)
 Get tensor shape and type attributes for a Hailo tensor. More...
 
vsi_nn_type_e hailo2vsi (hailo_format_type_t t)
 Convert from Hailo data type to vsi_nn. More...
 
vsi_nn_type_e onnx2vsi (ONNXTensorElementDataType t)
 Convert from ONNX-Runtime data type to vsi_nn. More...
 
std::string shapestr (Ort::ConstTensorTypeAndShapeInfo const &ti)
 Get a string of the form: "nD AxBxC... TYPE" from an n-dimensional ONNX tensor with data type TYPE. More...
 
vsi_nn_tensor_attr_t tensorattr (Ort::ConstTensorTypeAndShapeInfo const &ti)
 Get tensor shape and type attributes for an ONNX-runtime tensor. More...