class_docstr: Internal PBT state tracked per-trial.
class_docstr_tok: ["Internal","PBT","state","tracked","per-trial","."]
code: def __init__(self, trial: Trial):
      self.orig_tag = trial.experiment_tag
      self.last_score = None
      self.last_checkpoint = None
      self.last_perturbation_time = 0
      self.last_train_time = 0  # Used for synchronous mode.
      self.last_result = None
  
imports: import copy
  import json
  import logging
  import math
  import os
  import random
  import shutil
  import warnings
  from pathlib import Path
  from typing import Callable, Dict, List, Optional, Tuple, Union, TYPE_CHECKING
  from ray.air.constants import TRAINING_ITERATION
  from ray.train import Checkpoint
  from ray.train._internal.session import _TrainingResult, _FutureTrainingResult
  from ray.tune.error import TuneError
  from ray.tune.result import DEFAULT_METRIC
  from ray.tune.search import SearchGenerator
  from ray.tune.utils.util import SafeFallbackEncoder
  from ray.tune.search.sample import Domain, Function
  from ray.tune.schedulers import FIFOScheduler, TrialScheduler
  from ray.tune.search.variant_generator import format_vars
  from ray.tune.experiment import Trial
  from ray.util import PublicAPI
  from ray.util.debug import log_once
label_desc: Use image node_id 1 to create a new _PBTTrialState object  with example: obj = _PBTTrialState(trial)