code: def transparency_hex(
      color: tuple[int, int, int], alpha: float
  ) -> str:
      """Apply alpha coefficient on hexadecimal color."""
      return "#{:02x}{:02x}{:02x}".format(
          *tuple(
              [
                  int(round(alpha * c + (1 - alpha) * 255, 0))
                  for c in color
              ]
          )
      )
  
imports: from __future__ import annotations
  import collections
  import functools
  import io
  import math
  from abc import ABC, abstractmethod
  from river import base
  from river.utils.norm import normalize_values_in_dict
  from .nodes.branch import DTBranch, NominalBinaryBranch, NominalMultiwayBranch, NumericBinaryBranch, NumericMultiwayBranch
  from .nodes.leaf import HTLeaf
  from .utils import calculate_object_size
label_desc: Use image node_id 2 for calling a global function with example usage: transparency_hex(color, alpha) and returns: str