Layer Profiler#

class LayerProfiler : public nvinfer1::IProfiler#

Stage-specific layer profiler.

Public Functions

LayerProfiler(LayerProfiler const&) = delete#
LayerProfiler &operator=(LayerProfiler const&) = delete#
~LayerProfiler() noexcept override = default#
void setEnabled(bool enabled) noexcept#

Enable or disable layer profiling recording.

bool isEnabled() const noexcept#
void reset() noexcept#

Reset all profiling data.

void reportLayerTime(
char const *layerName,
float timeMs
) noexcept override#

TensorRT IProfiler interface implementation.

LayerProfilerMetrics getMetrics() const#

Get metrics.

Public Static Functions

static LayerProfiler &getInstance()#

Get the singleton instance.

struct LayerProfile#

Layer profile information - pure data structure.

Public Functions

LayerProfile() = default#

Public Members

std::string name#
std::string stageName#
std::vector<float> timeMs#
struct LayerProfilerMetrics#

Layer profiler metrics.

Public Members

std::string stageName#
std::vector<LayerProfile> layers#
int32_t iterationCount = {0}#
bool enabled = {false}#
void trt_edgellm::layerProfiler::enableLayerProfilers()#

Enable all layer profilers.

void trt_edgellm::layerProfiler::disableLayerProfilers()#

Disable all layer profilers.