Enable ONNX Runtime Profiling
Closed this issue · 2 comments
theonewolf commented
@sdcb is it easy to enable ONNX runtime profiling with your API here?
Or do we need to expose more APIs to get this done?
theonewolf commented
@sdcb I took a wrapping approach, customizing things the way I need doing this:
private static Action<PaddleConfig> CreateOnnxConfig(int cpuMathThreadCount = 1, bool profiling = true) {
var configurator = PaddleDevice.Onnx(cpuMathThreadCount);
return cfg =>
{
configurator(cfg);
// Activate profiling
cfg.ProfileEnabled = profiling;
};
}
theonewolf commented
This works for me, closing the ticket.