code: def generation_time(self):
          
          timestamp = struct.unpack(">I", self.__id[0:4])[0]
          return datetime.datetime.fromtimestamp(timestamp, utc)
docs: A :class:`datetime.datetime` instance representing the time of
          generation for this :class:`ObjectId`.
  
          The :class:`datetime.datetime` is timezone aware, and
          represents the generation time in UTC. It is precise to the
          second.