code: def on_trial_result(
      self,
      iteration: int,
      trials: List["Trial"],
      trial: "Trial",
      result: Dict,
      **info,
  ):
      self._trial_iterations[trial.trial_id].append(
          result["training_iteration"]
      )
  
imports: import collections
  import json
  import os
  from pathlib import Path
  import random
  import time
  from typing import Dict, List, Optional
  import ray
  from ray import train, tune
  from ray.train.data_parallel_trainer import DataParallelTrainer
  from ray.tune.experiment import Trial
  from ray.train.tests.util import create_dict_checkpoint, load_dict_checkpoint
label_desc: Use image node_id 2 for calling the StatefulCallback obj's underlying member method code with example usage: obj.on_trial_result(iteration, trials, trial, result) without return types