Go to the documentation of this file.
50 #ifndef NV_CAFFE_PARSER_H
51 #define NV_CAFFE_PARSER_H
107 virtual const void* getData() TRTNOEXCEPT = 0;
110 virtual void destroy() TRTNOEXCEPT = 0;
129 virtual bool isPlugin(
const char* layerName) TRTNOEXCEPT = 0;
151 virtual int getVersion()
const TRTNOEXCEPT
153 return NV_TENSORRT_VERSION;
161 virtual bool isPluginExt(
const char* layerName) TRTNOEXCEPT = 0;
177 virtual bool isPluginV2(
const char* layerName) TRTNOEXCEPT = 0;
237 std::size_t deployLength,
238 const char* modelBuffer,
239 std::size_t modelLength,
283 virtual void destroy() TRTNOEXCEPT = 0;
349 extern "C" TENSORRTAPI
void* createNvCaffeParser_INTERNAL();
virtual const IBlobNameToTensor * parseBuffers(const char *deployBuffer, std::size_t deployLength, const char *modelBuffer, std::size_t modelLength, nvinfer1::INetworkDefinition &network, nvinfer1::DataType weightType)=0
Parse a deploy prototxt a binaryproto Caffe model from memory buffers to extract network definition a...
virtual void destroy()=0
Destroy this ICaffeParser object.
Class used for parsing Caffe models.
Definition: NvCaffeParser.h:200
A network definition for input to the builder.
Definition: NvInfer.h:4838
An array of weights used as a layer parameter.
Definition: NvInferRuntime.h:107
void shutdownProtobufLibrary()
Shuts down protocol buffers library.
virtual void setPluginNamespace(const char *libNamespace)=0
Set the namespace used to lookup and create plugins in the network.
Plugin class for user-implemented layers.
Definition: NvInferRuntimeCommon.h:371
virtual void setPluginFactory(IPluginFactory *factory)=0
Set the IPluginFactory used to create the user defined plugins.
virtual bool isPluginExt(const char *layerName)=0
A user implemented function that determines if a layer configuration is provided by an IPluginExt.
virtual void setPluginFactoryV2(IPluginFactoryV2 *factory)=0
Set the IPluginFactoryV2 used to create the user defined pluginV2 objects.
virtual nvinfer1::IPlugin * createPlugin(const char *layerName, const nvinfer1::Weights *weights, int nbWeights)=0
Creates a plugin.
virtual IBinaryProtoBlob * parseBinaryProto(const char *fileName)=0
Parse and extract data stored in binaryproto file.
virtual nvinfer1::ITensor * find(const char *name) const =0
Given a blob name, returns a pointer to a ITensor object.
The TensorRT Caffe parser API namespace.
Plugin factory used to configure plugins.
Definition: NvCaffeParser.h:121
DataType
The type of weights and tensors.
Definition: NvInferRuntimeCommon.h:163
ICaffeParser * createCaffeParser()
Creates a ICaffeParser object.
Plugin factory used to configure plugins.
Definition: NvCaffeParser.h:169
Descriptor for data with one index dimension, one channel dimension and two spatial dimensions.
Definition: NvInfer.h:316
A tensor in a network definition.
Definition: NvInfer.h:467
virtual nvinfer1::IPluginV2 * createPlugin(const char *layerName, const nvinfer1::Weights *weights, int nbWeights, const char *libNamespace="")=0
Creates a plugin.
Reference counted application-implemented error reporting interface for TensorRT objects.
Definition: NvInferRuntimeCommon.h:1175
virtual bool isPluginV2(const char *layerName)=0
A user implemented function that determines if a layer configuration is provided by an IPluginV2.
virtual const IBlobNameToTensor * parse(const char *deploy, const char *model, nvinfer1::INetworkDefinition &network, nvinfer1::DataType weightType)=0
Parse a prototxt file and a binaryproto Caffe model to extract network definition and weights associa...
virtual bool isPlugin(const char *layerName)=0
A user implemented function that determines if a layer configuration is provided by an IPlugin.
virtual nvinfer1::IErrorRecorder * getErrorRecorder() const =0
get the ErrorRecorder assigned to this interface.
virtual void setErrorRecorder(nvinfer1::IErrorRecorder *recorder)=0
Set the ErrorRecorder for this interface.
Plugin factory used to configure plugins with added support for TRT versioning.
Definition: NvCaffeParser.h:148
Object used to store and query Tensors after they have been extracted from a Caffe model using the IC...
Definition: NvCaffeParser.h:80
virtual void setPluginFactoryExt(IPluginFactoryExt *factory)=0
Set the IPluginFactoryExt used to create the user defined pluginExts.
Plugin class for user-implemented layers.
Definition: NvInferRuntime.h:143
Object used to store and query data extracted from a binaryproto file using the ICaffeParser.
Definition: NvCaffeParser.h:104
virtual void setProtobufBufferSize(size_t size)=0
Set buffer size for the parsing and storage of the learned model.