code: def pkt2uptime(pkt, HZ=100):
      
      if not isinstance(pkt, Packet):
          raise TypeError("Not a TCP packet")
      if isinstance(pkt, NoPayload):
          raise TypeError("Not a TCP packet")
      if not isinstance(pkt, TCP):
          return pkt2uptime(pkt.payload)
      for opt in pkt.options:
          if opt[0] == "Timestamp":
              # t = pkt.time - opt[1][0] * 1.0/HZ
              # return time.ctime(t)
              t = opt[1][0] / HZ
              return t
      raise TypeError("No timestamp option")
docs: Calculate the date the machine which emitted the packet booted using TCP timestamp  # noqa: E501
  pkt2uptime(pkt, [HZ=100])