code: def int_gps_time_to_str(t):
      
  
      if isinstance(t, int):
          return str(t)
      elif isinstance(t, float):
          # Wouldn't this just work generically?
          int_t = int(t)
          if abs(t - int_t) > 0.:
              raise ValueError('Need an integer GPS time, got %s' % str(t))
          return str(int_t)
      elif isinstance(t, lal.LIGOTimeGPS):
          if t.gpsNanoSeconds == 0:
              return str(t.gpsSeconds)
          else:
              raise ValueError('Need an integer GPS time, got %s' % str(t))
      else:
          err_msg = "Didn't understand input type {}".format(type(t))
          raise ValueError(err_msg)
docs: Takes an integer GPS time, either given as int or lal.LIGOTimeGPS, and
      converts it to a string. If a LIGOTimeGPS with nonzero decimal part is
      given, raises a ValueError.