docs: def save_task_info(self, res, mem_gb=0):
      """
      :param self: an object with attributes .hdf5, .argnames, .sent
      :parent res: a :class:`Result` object
      :param mem_gb: memory consumption at the saving time (optional)
      """
      mon = res.mon
      name = mon.operation[6:]  # strip 'total '
      if self.hdf5:
          mon.hdf5 = self.hdf5  # needed for the flush below
          t = (mon.task_no, mon.weight, mon.duration, len(res.pik), mem_gb)
          data = numpy.array([t], task_info_dt)
          hdf5.extend3(self.hdf5.filename, 'task_info/' + name, data,
                       argnames=self.argnames, sent=self.sent)
      mon.flush()