TensorRT  7.2.1.6
NVIDIA TensorRT
Looking for a C++ dev who knows TensorRT?
I'm looking for work. Hire me!
BatchStream Class Reference

Custom BatchStream class for Faster-RCNN because we use variable input dimensions and different image preprocessing. More...

Inheritance diagram for BatchStream:
Collaboration diagram for BatchStream:

Public Member Functions

 BatchStream (int batchSize, int maxBatches, std::string prefix, std::string suffix, std::vector< std::string > directories)
 
 BatchStream (int batchSize, int maxBatches, std::string prefix, std::vector< std::string > directories)
 
 BatchStream (int batchSize, int maxBatches, nvinfer1::Dims dims, std::string listFile, std::vector< std::string > directories)
 
void reset (int firstBatch) override
 
bool next () override
 
void skip (int skipCount) override
 
float * getBatch () override
 
float * getLabels () override
 
int getBatchesRead () const override
 
int getBatchSize () const override
 
nvinfer1::Dims getDims () const override
 
 BatchStream (int batchSize, int maxBatches, const std::string &prefix, const std::string &suffix, const std::vector< std::string > &directories)
 
 BatchStream (int batchSize, int maxBatches, const std::string &prefix, const std::vector< std::string > &directories)
 
 BatchStream (int batchSize, int maxBatches, const nvinfer1::Dims &dims, const std::string &listFile, const std::vector< std::string > &directories)
 
void reset (int firstBatch)
 
bool next ()
 
void skip (int skipCount)
 
float * getBatch ()
 
float * getLabels ()
 
int getBatchesRead () const
 
int getBatchSize () const
 
nvinfer1::Dims getDims () const
 

Private Member Functions

float * getFileBatch ()
 
float * getFileLabels ()
 
bool update ()
 
float * getFileBatch ()
 
float * getFileLabels ()
 
bool update ()
 

Private Attributes

int mBatchSize {0}
 
int mMaxBatches {0}
 
int mBatchCount {0}
 
int mFileCount {0}
 
int mFileBatchPos {0}
 
int mImageSize {0}
 
std::vector< float > mBatch
 Data for the batch. More...
 
std::vector< float > mLabels
 Labels for the batch. More...
 
std::vector< float > mFileBatch
 List of image files. More...
 
std::vector< float > mFileLabels
 List of label files. More...
 
std::string mPrefix
 Batch file name prefix. More...
 
std::string mSuffix
 Batch file name suffix. More...
 
nvinfer1::Dims mDims
 Input dimensions. More...
 
std::string mListFile
 File name of the list of image names. More...
 
std::vector< std::string > mDataDir
 Directories where the files can be found. More...
 

Detailed Description

Custom BatchStream class for Faster-RCNN because we use variable input dimensions and different image preprocessing.

Constructor & Destructor Documentation

◆ BatchStream() [1/6]

BatchStream::BatchStream ( int  batchSize,
int  maxBatches,
std::string  prefix,
std::string  suffix,
std::vector< std::string >  directories 
)
inline
Here is the call graph for this function:

◆ BatchStream() [2/6]

BatchStream::BatchStream ( int  batchSize,
int  maxBatches,
std::string  prefix,
std::vector< std::string >  directories 
)
inline

◆ BatchStream() [3/6]

BatchStream::BatchStream ( int  batchSize,
int  maxBatches,
nvinfer1::Dims  dims,
std::string  listFile,
std::vector< std::string >  directories 
)
inline
Here is the call graph for this function:

◆ BatchStream() [4/6]

BatchStream::BatchStream ( int  batchSize,
int  maxBatches,
const std::string &  prefix,
const std::string &  suffix,
const std::vector< std::string > &  directories 
)
inline

◆ BatchStream() [5/6]

BatchStream::BatchStream ( int  batchSize,
int  maxBatches,
const std::string &  prefix,
const std::vector< std::string > &  directories 
)
inline

◆ BatchStream() [6/6]

BatchStream::BatchStream ( int  batchSize,
int  maxBatches,
const nvinfer1::Dims dims,
const std::string &  listFile,
const std::vector< std::string > &  directories 
)
inline

Member Function Documentation

◆ reset() [1/2]

void BatchStream::reset ( int  firstBatch)
inlineoverridevirtual

Implements IBatchStream.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ next() [1/2]

bool BatchStream::next ( )
inlineoverridevirtual

Implements IBatchStream.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ skip() [1/2]

void BatchStream::skip ( int  skipCount)
inlineoverridevirtual

Implements IBatchStream.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getBatch() [1/2]

float* BatchStream::getBatch ( )
inlineoverridevirtual

Implements IBatchStream.

Here is the caller graph for this function:

◆ getLabels() [1/2]

float* BatchStream::getLabels ( )
inlineoverridevirtual

Implements IBatchStream.

Here is the caller graph for this function:

◆ getBatchesRead() [1/2]

int BatchStream::getBatchesRead ( ) const
inlineoverridevirtual

Implements IBatchStream.

◆ getBatchSize() [1/2]

int BatchStream::getBatchSize ( ) const
inlineoverridevirtual

Implements IBatchStream.

◆ getDims() [1/2]

nvinfer1::Dims BatchStream::getDims ( ) const
inlineoverridevirtual

Implements IBatchStream.

◆ getFileBatch() [1/2]

float* BatchStream::getFileBatch ( )
inlineprivate
Here is the caller graph for this function:

◆ getFileLabels() [1/2]

float* BatchStream::getFileLabels ( )
inlineprivate
Here is the caller graph for this function:

◆ update() [1/2]

bool BatchStream::update ( )
inlineprivate
Here is the call graph for this function:
Here is the caller graph for this function:

◆ reset() [2/2]

void BatchStream::reset ( int  firstBatch)
inlinevirtual

Implements IBatchStream.

◆ next() [2/2]

bool BatchStream::next ( )
inlinevirtual

Implements IBatchStream.

◆ skip() [2/2]

void BatchStream::skip ( int  skipCount)
inlinevirtual

Implements IBatchStream.

◆ getBatch() [2/2]

float* BatchStream::getBatch ( )
inlinevirtual

Implements IBatchStream.

◆ getLabels() [2/2]

float* BatchStream::getLabels ( )
inlinevirtual

Implements IBatchStream.

◆ getBatchesRead() [2/2]

int BatchStream::getBatchesRead ( ) const
inlinevirtual

Implements IBatchStream.

◆ getBatchSize() [2/2]

int BatchStream::getBatchSize ( ) const
inlinevirtual

Implements IBatchStream.

◆ getDims() [2/2]

nvinfer1::Dims BatchStream::getDims ( ) const
inlinevirtual

Implements IBatchStream.

◆ getFileBatch() [2/2]

float* BatchStream::getFileBatch ( )
inlineprivate

◆ getFileLabels() [2/2]

float* BatchStream::getFileLabels ( )
inlineprivate

◆ update() [2/2]

bool BatchStream::update ( )
inlineprivate
Here is the call graph for this function:

Member Data Documentation

◆ mBatchSize

int BatchStream::mBatchSize {0}
private

◆ mMaxBatches

int BatchStream::mMaxBatches {0}
private

◆ mBatchCount

int BatchStream::mBatchCount {0}
private

◆ mFileCount

int BatchStream::mFileCount {0}
private

◆ mFileBatchPos

int BatchStream::mFileBatchPos {0}
private

◆ mImageSize

int BatchStream::mImageSize {0}
private

◆ mBatch

std::vector< float > BatchStream::mBatch
private

Data for the batch.

◆ mLabels

std::vector< float > BatchStream::mLabels
private

Labels for the batch.

◆ mFileBatch

std::vector< float > BatchStream::mFileBatch
private

List of image files.

◆ mFileLabels

std::vector< float > BatchStream::mFileLabels
private

List of label files.

◆ mPrefix

std::string BatchStream::mPrefix
private

Batch file name prefix.

◆ mSuffix

std::string BatchStream::mSuffix
private

Batch file name suffix.

◆ mDims

nvinfer1::Dims BatchStream::mDims
private

Input dimensions.

◆ mListFile

std::string BatchStream::mListFile
private

File name of the list of image names.

◆ mDataDir

std::vector< std::string > BatchStream::mDataDir
private

Directories where the files can be found.


The documentation for this class was generated from the following files: