class_docstr: A progress bar which logs upon completion of the item
  
  Note that there is also :func:`~datalad.log.log_progress` which can be used
  to get progress bars when attached to a tty but incremental log messages
  otherwise (as opposed to just the final log message provided by
  `LogProgressBar`).
class_docstr_tok: ["A","progress","bar","which","logs","upon","completion","of","the","item","Note","that","there","is","also",":","func",":","`","~datalad.log.log_progress","`","which","can","be","used","to","get","progress","bars","when","attached","to","a","tty","but","incremental","log","messages","otherwise","(","as","opposed","to","just","the","final","log","message","provided","by","`","LogProgressBar","`",")","."]
code: def finish(self, partial=False):
      msg, args = " %s ", [self.label]
  
      if partial:
          # that is the best we know so far:
          amount = self.current
          if self.total is not None:
              if amount != self.total:
                  perc_done = 100.0 * amount / self.total
                  if perc_done <= 100:
                      msg += "partially (%.2f%% of %s) "
                      args += [perc_done, self._naturalsize(self.total)]
                  else:
                      # well well -- we still probably have some issue with
                      # over-reporting when getting data from datalad-archives
                      # Instead of providing non-sense % here, just report
                      # our best guess
                      msg += "possibly partially "
              else:
                  # well -- that means that we did manage to get all of it
                  pass
          else:
              msg += "possibly partially "
          msg += "done"
      else:
          # Are we "finish"ed because interrupted or done?
          amount = self.total
          if amount:
              msg += "%s done"
              args += [self._naturalsize(amount)]
          else:
              msg += "done"
  
      dt = float(time.time() - self._start_time)
  
      if dt:
          msg += " in %s"
          args += [self._naturaldelta(dt)]
  
          if amount:
              speed = amount / dt
              msg += " at %s/sec"
              args += [self._naturalsize(speed)]
  
      lgr.info(msg, *args)
  
imports: import humanize
  import sys
  import time
  from ..None import lgr
label_desc: Use image node_id 6 for calling the LogProgressBar obj's underlying member method code with example usage: obj.finish(partial) without return types