code: def _fix_scalar_values_for_json(scalar_data):
      for scalar in scalar_data:
          for summary, val in scalar.items():
              if _is_special_float_for_json(val):
                  scalar[summary] = str(json.dumps(val))
  
imports: import json
  import logging
  import math
  import os
  import socket
  import subprocess
  import sys
  import threading
  import time
  from werkzeug.exceptions import NotFound
  from werkzeug.utils import redirect
  from guild import serving_util
  from guild import util
  from guild import var
label_desc: Use image node_id 8 for calling a global function with example usage: _fix_scalar_values_for_json(scalar_data) without return types