diff --git a/include/tkDNN/Int8BatchStream.h b/include/tkDNN/Int8BatchStream.h index 028f75d..c39a11c 100644 --- a/include/tkDNN/Int8BatchStream.h +++ b/include/tkDNN/Int8BatchStream.h @@ -39,7 +39,7 @@ public: float *getLabels() { return mLabels.data(); } int getBatchesRead() const { return mBatchCount; } int getBatchSize() const { return mBatchSize; } - nvinfer1::Dims4 getDims() const { return mDims; } + nvinfer1::DimsNCHW getDims() const { return mDims; } float* getFileBatch() { return &mFileBatch[0]; } float* getFileLabels() { return &mFileLabels[0]; } void readInListFile(const std::string& dataFilePath, std::vector& mListIn); @@ -55,7 +55,7 @@ private: int mFileBatchPos{ 0 }; int mImageSize{ 0 }; - nvinfer1::Dims4 mDims; + nvinfer1::DimsNCHW mDims; std::vector mBatch; std::vector mLabels; std::vector mFileBatch; diff --git a/include/tkDNN/Int8Calibrator.h b/include/tkDNN/Int8Calibrator.h index c7a7d97..4a0ea47 100644 --- a/include/tkDNN/Int8Calibrator.h +++ b/include/tkDNN/Int8Calibrator.h @@ -30,10 +30,10 @@ public: Int8EntropyCalibrator(BatchStream& stream, int firstBatch, const std::string& calibTableFilePath, const std::string& inputBlobName, bool readCache = true); virtual ~Int8EntropyCalibrator() { checkCuda(cudaFree(mDeviceInput)); } - int getBatchSize() const NOEXCEPT override { return mStream.getBatchSize(); } - bool getBatch(void* bindings[], const char* names[], int nbBindings) NOEXCEPT override; - const void* readCalibrationCache(size_t& length) NOEXCEPT override; - void writeCalibrationCache(const void* cache, size_t length) NOEXCEPT override; + int getBatchSize() const override { return mStream.getBatchSize(); } + bool getBatch(void* bindings[], const char* names[], int nbBindings) override; + const void* readCalibrationCache(size_t& length) override; + void writeCalibrationCache(const void* cache, size_t length) override; private: BatchStream mStream; diff --git a/include/tkDNN/NetworkRT.h b/include/tkDNN/NetworkRT.h index a7e67c2..d0f7a6a 100644 --- a/include/tkDNN/NetworkRT.h +++ b/include/tkDNN/NetworkRT.h @@ -33,7 +33,6 @@ namespace tk { namespace dnn { using namespace nvinfer1; - class NetworkRT { public: @@ -57,6 +56,7 @@ public: dnnType *output; cudaStream_t stream; + PluginFactory *pluginFactory; NetworkRT(Network *net, const char *name); virtual ~NetworkRT(); diff --git a/include/tkDNN/pluginsRT/ActivationReLUCeilingRT.h b/include/tkDNN/pluginsRT/ActivationReLUCeilingRT.h index 1830945..dc8fcd6 100644 --- a/include/tkDNN/pluginsRT/ActivationReLUCeilingRT.h +++ b/include/tkDNN/pluginsRT/ActivationReLUCeilingRT.h @@ -78,4 +78,4 @@ namespace nvinfer1 { }; REGISTER_TENSORRT_PLUGIN(ActivationReLUCeilingPluginCreator); -}; \ No newline at end of file +}; diff --git a/include/tkDNN/pluginsRT/RegionRT.h b/include/tkDNN/pluginsRT/RegionRT.h index 7f7157c..07f7996 100644 --- a/include/tkDNN/pluginsRT/RegionRT.h +++ b/include/tkDNN/pluginsRT/RegionRT.h @@ -107,4 +107,4 @@ namespace nvinfer1 { REGISTER_TENSORRT_PLUGIN(RegionRTPluginCreator); }; -#endif +#endif \ No newline at end of file diff --git a/include/tkDNN/pluginsRT/ReorgRT.h b/include/tkDNN/pluginsRT/ReorgRT.h index be163a5..98a098e 100644 --- a/include/tkDNN/pluginsRT/ReorgRT.h +++ b/include/tkDNN/pluginsRT/ReorgRT.h @@ -94,5 +94,4 @@ namespace nvinfer1 { }; REGISTER_TENSORRT_PLUGIN(ReorgRTPluginCreator); -}; - +}; \ No newline at end of file diff --git a/include/tkDNN/pluginsRT/ReshapeRT.h b/include/tkDNN/pluginsRT/ReshapeRT.h index e56c79c..f4a47eb 100644 --- a/include/tkDNN/pluginsRT/ReshapeRT.h +++ b/include/tkDNN/pluginsRT/ReshapeRT.h @@ -99,4 +99,4 @@ namespace nvinfer1 { REGISTER_TENSORRT_PLUGIN(ReshapeRTPluginCreator); }; -#endif \ No newline at end of file +#endif diff --git a/include/tkDNN/pluginsRT/ResizeLayerRT.h b/include/tkDNN/pluginsRT/ResizeLayerRT.h index 750057e..b904d57 100644 --- a/include/tkDNN/pluginsRT/ResizeLayerRT.h +++ b/include/tkDNN/pluginsRT/ResizeLayerRT.h @@ -101,4 +101,3 @@ namespace nvinfer1 { REGISTER_TENSORRT_PLUGIN(ResizeLayerRTPluginCreator); }; - diff --git a/include/tkDNN/pluginsRT/YoloRT.h b/include/tkDNN/pluginsRT/YoloRT.h index 352a0cb..db7c065 100644 --- a/include/tkDNN/pluginsRT/YoloRT.h +++ b/include/tkDNN/pluginsRT/YoloRT.h @@ -121,4 +121,4 @@ namespace nvinfer1 { REGISTER_TENSORRT_PLUGIN(YoloRTPluginCreator); }; -#endif \ No newline at end of file +#endif diff --git a/include/tkDNN/utils.h b/include/tkDNN/utils.h index a1a1f1c..7432d14 100644 --- a/include/tkDNN/utils.h +++ b/include/tkDNN/utils.h @@ -13,7 +13,6 @@ #include "cuda_runtime_api.h" #include #include -#include #ifdef __linux__ @@ -24,15 +23,6 @@ #include - - -#if NV_TENSORRT_MAJOR > 7 -#define NOEXCEPT noexcept -#else -#define NOEXCEPT -#endif - - #define dnnType float template void writeBUF(char*& buffer, const T& val)