code: def __init__(
      self, log_dir: Path, sync_every_n_seconds: int = 5
  ) -> None:
      super().__init__(
          cloud_build_config=BuildConfig(requirements=["tensorboard"])
      )
      self.log_dir = log_dir
      self._sync_every_n_seconds = sync_every_n_seconds
  
file_path: pytorch-lightning/src/lightning/app/cli/pl-app-template/core/components/logger/tensorboard.py
imports: import subprocess
  import time
  from typing import Dict, List
  from lightning.app import BuildConfig, LightningFlow, LightningWork
  from lightning.app.storage.path import Path
label_desc: Use image node_id 1 to create a new TensorBoardWorker object from inherited base classes: LightningWork with example: obj = TensorBoardWorker(log_dir, sync_every_n_seconds)