code: def ended(self):
          
          self._end_time = time.time()
  
          if setting(key='memory_profile', expected_type=bool):
              self._end_memory = get_free_memory()
docs: We call this method when the function is finished.