code: def stop(self):
      time_taken = time.perf_counter() - self._start_time
      with open(os.path.join(self._save_dir, "profile.log"), "w+") as f:
          f.write(f"took {time_taken} seconds to complete")
  
imports: import os
  import paddle
  from typing import Optional, Union
  import time
  import ivy
  from ivy.functional.ivy.device import _shift_native_arrays_on_default_device, Profiler
  from paddle.device import core
label_desc: Use image node_id 3 for calling the Profiler obj's underlying member method code with example usage: obj.stop() without return types