all it does is to measure the performance of sequence generation More...
Public Types | |
typedef std::shared_ptr< DataWriter > | ptr |
Public Member Functions | |
BenchmarkWriter () | |
void | write (const int *hOutputData, int actualOutputSequenceLength, int actualInputSequenceLength) override |
write the generated sequence More... | |
void | initialize () override |
it is called right before inference starts More... | |
void | finalize () override |
it is called right after inference ends More... | |
std::string | getInfo () override |
get the textual description of the component More... | |
~BenchmarkWriter () override=default | |
Static Protected Member Functions | |
static std::string | generateText (int sequenceLength, const int *currentOutputData, Vocabulary::ptr vocabulary) |
Private Attributes | |
int | mSampleCount |
int | mInputTokenCount |
int | mOutputTokenCount |
std::chrono::high_resolution_clock::time_point | mStartTS |
all it does is to measure the performance of sequence generation
|
inherited |
nmtSample::BenchmarkWriter::BenchmarkWriter | ( | ) |
|
overridedefault |
|
overridevirtual |
write the generated sequence
Implements nmtSample::DataWriter.
|
overridevirtual |
it is called right before inference starts
Implements nmtSample::DataWriter.
|
overridevirtual |
it is called right after inference ends
Implements nmtSample::DataWriter.
|
overridevirtual |
get the textual description of the component
Implements nmtSample::Component.
|
staticprotectedinherited |
|
private |
|
private |
|
private |
|
private |