Closed lionkunonly closed 3 years ago
Th investigation on Python API is based on OpenVINO 2020.3.
I investigate the Python APIs by viewing the file at path <openvino_dir>inference engine\ie_bridges\python\src\openvino\ inference_engine\ie_api_impl.hpp
. And I ingvestigate the Node.js API by viewing files at path <inference_engine_node_dir>\src\
.
Python API (struct IECore ) |
Node.js API (class Core ) |
---|---|
getVersions( ) | getVersions( ) |
readNetwork( ) ( From path ) | readNetwork( ) |
readNetwork( ) ( From Data) | readNetworkFromData( ) |
loadNetwork( ) | loadNetwork( ) |
getAvailableDevices( ) | getAvailableDevices( ) |
setConfig( ) | setConfig( ) (On the way) |
addExtension( ) | addExtension( ) (On the way) |
importNetwork( ) | - |
queryNetwork( ) | - |
registerPlugin( ) | - |
unregisterPlugin( ) | - |
registerPlugins( ) | - |
getMetric( ) | - |
getConfig( ) | - |
Python API (struct IENetwork ) |
Node.js API class Network |
---|---|
setBatch( ) | - |
getBatch( ) | - |
addOutput( ) | - |
getLayers( ) | - |
getInputs( ) | getInputsInfo( ) |
getOutputs( ) | getgetOutputsInfo( ) |
- | getName( ) |
reshape( ) | - |
serialize( ) | - |
setStats( ) | - |
getStats( ) | - |
load_from_buffer( ) | - |
Python API (struct IEExecNetwork ) |
Node.js API (class ExecutableNetwork ) |
---|---|
createInferRequests( ) | createInferRequest( ) |
GetExecGraphInfo( ) | - |
infer( ) | - |
exportNetwork( ) | - |
getInputs( ) | - |
getOutputs( ) | - |
getMetric( ) | - |
getConfig( ) | - |
wait( ) | - |
getIdleRequestId( ) | - |
Python API (struct InferRequestWrap ) |
Node.js API (class InferRequest ) |
---|---|
infer( ) | infer( ) |
infer_async( ) | startAsync( ) |
wait( ) | - |
setCyCallback( ) | - |
getBlobPtr( ) | getBlob( ) |
setBatch( ) | - |
getPerformanceCounts() | - |
Python API (struct IEPlugin ) |
Node.js API (- ) |
---|---|
load( ) | - |
setConfig( ) | - |
addCpuExtension( ) | - |
setInitialAffinity( ) | - |
queryNetwork( ) | - |
I do not find corresponding class in Node.js API for the struct IEPlugin
.
There are some classes in Node.js API that do not have corresponding API in Python.
The class Blob is used to help user operate the class Blob in OpenVINO. |
Node.js API (class Blob ) |
---|---|
ByteSize( ) | |
Size( ) | |
Rwmap( ) | |
Rmap( ) | |
Wmap( ) | |
Unmap( ) | |
Memmap( ) |
The class InputInfo and class OutputInfo are used to support operations of the Inputinfo and Outputinfo respectively. |
Node.js API (class InputInfo ) |
Node.js API (class OutputInfo ) |
---|---|---|
name( ) | name( ) | |
getPrecision( ) | getPrecision( ) | |
setPrecision( ) | setPrecision( ) | |
getLayout( ) | getLayout( ) | |
setLayout( ) | - | |
getDims( ) | getDims( ) | |
getPreProcess( ) | - |
The class PreProcessInfo is developing. It is used to support PreProcessInfo in OpenVINO. |
Node.js API (class PreProcessInfo ) |
---|---|
getColorFormat( ) | |
setColorFormat( ) | |
getResizeAlgorithm( ) | |
setResizeAlgorithm( ) | |
getMeanVariant( ) | |
setVariant( ) | |
getPreProcessChannel( ) (On the way) | |
setPreProcessChannel( ) (On the way) |
That is all at this time.
@artyomtugaryov please help review the comparison table.
The comparison is done, let's close this issue.
The gaps bettwen Node.js API vs Python IE API will be recorded here.