tensorflow icon indicating copy to clipboard operation
tensorflow copied to clipboard

Enable C++ profiles to be exported to TensorBoard

Open nvkevihu opened this issue 2 years ago • 3 comments

Makes ExportToTensorBoard() publicly visibility to allow C++ applications to export profiles to TensorBoard. Also adds the symbol to libtensorflow_framework.so for C++ applications that link to the shared object.

  • Moves ExportToTensorBoard() to tensorboard_export.h and tensorboard_export.cc
  • Moves PopulateNewProfileSessionRequest(), PopulateProfileRequest(), and PopulateMonitorRequest() to populate_request.h, which is depended on by tensorboard_export and capture_profile

cc: @DEKHTIARJonathan @meena-at-work @bixia1

nvkevihu avatar Jul 29 '22 02:07 nvkevihu

Sorry, I don't have the expertise in the profiler to review this code. Perhaps @yisitu can recommend someone on the profiler team to review?

nfelt avatar Jul 29 '22 22:07 nfelt

We are currently reviewing the changes, and will provide updates soon.

cliveverghese avatar Aug 01 '22 17:08 cliveverghese

Hi @nvkevihu,

Thank you for the PR,

In order for tensorboard to view the data in the XSpace, you can save the XSpace to the logdir, and tensorboard would be able to generate the required dashboards from the XSpace directly. This is the workflow currently being used when running the tensorflow profiler, as can be seen in CollectDataToRepository.

The functionality that is required here, and in PR #299 is to be able to save the XSpace in a way that it can be analysed by tensorboard?.

cliveverghese avatar Aug 09 '22 19:08 cliveverghese

Hi @cliveverghese, thanks for the suggestion. Indeed, the intended functionality was to save the XSpace so that it could be analyzed in TensorBoard.

I've implemented your suggested workflow in PR #317, and it works well for our use case, so this PR seems to be redundant. Closing.

nvkevihu avatar Aug 12 '22 17:08 nvkevihu

+Sai Ganesh @.***> who took over the TensorFlow profiler.

On Fri, Jul 29, 2022 at 3:27 PM Nick Felt @.***> wrote:

Sorry, I don't have the expertise in the profiler to review this code. Perhaps @yisitu https://github.com/yisitu can recommend someone on the profiler team to review?

— Reply to this email directly, view it on GitHub https://github.com/tensorflow/tensorflow/pull/56941#issuecomment-1199992771, or unsubscribe https://github.com/notifications/unsubscribe-auth/AONQZYGNUIFY3BCGHII2W53VWRLE5ANCNFSM547GQ7EA . You are receiving this because you were mentioned.Message ID: @.***>

yisitu avatar Oct 11 '22 08:10 yisitu