class_docstr: This profiler uses Python's cProfiler to record more detailed information about time spent in each function call
  recorded during a given action.
  
  The output is quite verbose and you should only use this if you want very detailed reports.
code: def summary(self) -> str:
      recorded_stats = {}
      for action_name, pr in self.profiled_actions.items():
          s = io.StringIO()
          ps = (
              pstats.Stats(pr, stream=s)
              .strip_dirs()
              .sort_stats("cumulative")
          )
          ps.print_stats(self.line_count_restriction)
          recorded_stats[action_name] = s.getvalue()
      return self._stats_to_str(recorded_stats)
  
file_path: pytorch-lightning/src/lightning/pytorch/profilers/advanced.py
imports: import cProfile
  import io
  import logging
  import pstats
  from pathlib import Path
  from typing import Dict, Optional, Tuple, Union
  from typing_extensions import override
  from lightning.pytorch.profilers.profiler import Profiler
label_desc: Use image node_id 4 for calling the AdvancedProfiler obj's underlying member method code with example usage: obj.summary() and returns: self