语言识别之IPP简介
来源:互联网 发布:淘宝ceo 编辑:程序博客网 时间:2024/06/06 08:28
IPP使用入门
1、Exmaple
IPP入门的话,直接看example就好,快准狠!看完直接开始写代码。
2、Special
对于IPP里面的东西做一些特别的说明。
数据类型:
原语细节:
描述语言:
依赖范围:
链接选择:
我们经常看到动态链接和静态链接,what 是动态链接和静态链接?
3、Function
Init/InitCpu(初始化CPU)
The ippInit function detects the processor type and sets the dispatcher to use the processor-specific code of the Intel® IPP library corresponding to the instruction set capabilities available.
In some cases like debugging and performance analysis, you may want to get the data on the difference between various processor-specific codes on the same machine. Use the ippInitCpu function for this. This function sets the dispatcher to use the processor-specific code according to the specified processor type without querying the system.
The ippInit and ippInitCpu functions are a part of the ippCore library.
GetStatusString(直接将语音转化为文本)
The ippGetStatusString function decodes the numeric status return value of Intel® IPP functions and converts them to a human readable text:
status= ippInit(); if( status != ippStsNoErr ) { printf("IppInit() Error:\n"); printf("%s\n", ippGetStatusString(status) ); return -1; }
The ippGetStatusString function is a part of the ippCore library.
GetLibVersion(获取库的版本)
Each domain has its own GetLibVersion function that returns information about the library layer in use from the dispatcher. The code snippet below demonstrates the usage of the ippiGetLibVersion from the image processing domain:
const IppLibraryVersion* lib = ippiGetLibVersion();printf(“%s %s %d.%d.%d.%d\n”, lib->Name, lib->Version,lib->major, lib->minor, lib->majorBuild, lib->build);
Use this function in combination with ippInitCpu to compare the output of different implementations on the same machine.
Malloc/Free(内存申请和释放)
Intel IPP functions provide better performance if they process data with aligned pointers. Intel IPP provides the following functions to ensure that data is 32-byte aligned:
void* ippMalloc(int length)void ippFree(void* ptr)
The ippMalloc function provides a 32-byte aligned buffer, and the ippFree function frees it.
The signal and image processing libraries provide ippsMalloc and ippiMalloc functions, respectively, to allocate a 32-byte aligned buffer that can be freed by the ippsFree and ippiFree functions.
- Compute the size of the required buffer using the <operation function>GetSize function.
- Set up any buffers needed for initialization.
- Initialize the specification structure for the operation.
- Free the buffers need for initialization only.
- Set up working buffers for the main operation.
- Do the main operation.
- Free the specification and working buffers.
Thread Managing(调用几个线程)
By default, the number of threads for Intel IPP threaded libraries follows the OpenMP* default, which is the number of logical processors visible to the operating system. If the value of the OMP_NUM_THREADS environment variable is less than the number of processors, then the number of threads for Intel IPP threaded libraries equals the value of the OMP_NUM_THREADS environment variable.
To configure the number of threads used by Intel IPP internally, at the very beginning of an application call the ippSetNumThreads(n) function, where n is the desired number of threads (1, ...). To disable internal parallelization, call the ippSetNumThreads(1) function.
Getting Information on Number of Threads(获取线程数目)
To find the number of threads created by the Intel IPP, call the ippGetNumThreads function.
到目前为止估计你已经对于IPP有那么多多少少一点认识,接下来就去看example吧!或者直接百度,我只是闲的蛋疼才看这些的
PS:如果你想进行自动补全的话,按Alt + RIGHT ARROW or Ctrl + SPACEBAR。
- 语言识别之IPP简介
- 语音识别之IPP使用教程以及vs上配置IPP
- IPP库简介
- Intel ipp 之图像变换
- Intel IPP 之图像处理
- Intel IPP之IPP图像处理编程基础
- Intel IPP 之 视觉计算概述
- Intel IPP 之图像压缩编码
- R语言学习之简介
- IOS之OC语言简介
- 语言识别之DTW算法及其源码
- Intel IPP 之软件开发与优化基础
- Intel ipp 之视觉计算软件开发平台
- 语言识别
- 学习IPP
- 《C语言参悟之旅》简介
- 《C语言参悟之旅》简介
- JavaSE基础之Java语言(命令行简介)
- Is It A Tree?
- 人生百味,浓缩到最后就是一个淡字
- 环状序列,ACM/ICPC,UVa1584
- hdu 2896 病毒侵袭( AC自动机模板题)
- HDU 5188 zhx and contest(有限制01背包)
- 语言识别之IPP简介
- Temporary-Post-Used-For-Style-Detection-Title-1099924566
- Js实现无刷新添加新层,拖动DIV层可互换位置
- Java的入门基本语法-笔记
- 在 Ubuntu 中手动安装任何版本的 Firefox
- ZOJ 3201解题报告
- 关于Lucene断点续索引和增量索引的问题
- 有利益,就有纷争
- Java的对象和类-笔记