Prints the estimated time left.
358183
def _cache_eta(self):
        
        self._calc_eta()
        self._cached_output += ' | ETA: ' + self._get_time(self.eta)
565619
@Trivial
    protected void endTimings() {
        endTime = getTime();

        if (tc.isDebugEnabled()) {
            Tr.debug(tc, MessageFormat.format("Start time:  [ {0} ]", Long.valueOf(startTime)));
            Tr.debug(tc, MessageFormat.format("End time:    [ {0} ]", Long.valueOf(endTime)));
            Tr.debug(tc, MessageFormat.format("Delta time:  [ {0} ]", Long.valueOf(endTime - startTime)));
            Tr.debug(tc, MessageFormat.format("Stream time: [ {0} ]", Long.valueOf(streamTime)));
        }
    }
216497
def elapsed_time_s(self):
        
        if self._start_time:
            return (datetime.datetime.now() - self._start_time).total_seconds()
        else:
            return 0
1357723
def _display(self, sent, now, chunk, mbps):
        
        if self.parent is not None:
            self.parent._display(self.parent.offset + sent, now, chunk, mbps)
            return

        elapsed = now - self.startTime

        if sent > 0 and self.total is not None and sent <= self.total:
            eta = (self.total - sent) * elapsed.total_seconds() / sent
            eta = datetime.timedelta(seconds=eta)
        else:
            eta = None

        self.output.write(
            "\r %s: Sent %s%s%s ETA: %s (%s) %s%20s\r" % (
                elapsed,
                util.humanize(sent),
                "" if self.total is None else " of %s" % (util.humanize(self.total),),
                "" if self.total is None else " (%d%%)" % (int(100 * sent / self.total),),
                eta,
                "" if not mbps else "%.3g Mbps " % (mbps,),
                chunk or "",
                " ",
            )
        )

        self.output.flush()
1306730
def expiration_time(self):
        
        logging_forgotten_time = configuration.behavior.login_forgotten_seconds

        if logging_forgotten_time <= 0:
            return None

        now = timezone.now()
        delta = now - self.modified
        time_remaining = logging_forgotten_time - delta.seconds

        return time_remaining
1182103
def print_and_exit(results):
    """"""
    for success, value in results:
        if success:
            print value.encode(locale.getpreferredencoding())
        else:
            value.printTraceback()
1176654
public void printData(PrintWriter pw)
   {
      long lmin = min.get();
      if (lmin == Long.MAX_VALUE)
      {
         lmin = -1;
      }
      long lmax = max.get();
      long ltotal = total.get();
      long ltimes = times.get();
      float favg = ltimes == 0 ? 0f : (float)ltotal / ltimes;
      pw.print(lmin);
      pw.print(',');
      pw.print(lmax);
      pw.print(',');
      pw.print(ltotal);
      pw.print(',');
      pw.print(favg);
      pw.print(',');
      pw.print(ltimes);
   }
672588
def print_progress(self, i, current_params):
        
        for split in range(1,11):
            if i == (round(self.iterations/10*split)-1):
                post = -self.full_neg_posterior(current_params)
                approx = self.create_normal_logq(current_params)
                diff = post - approx
                if not self.quiet_progress:
                    print(str(split) + "0% done : ELBO is " + str(diff) + ", p(y,z) is " + str(post) + ", q(z) is " + str(approx))
548104
def eta
      if @current == 0
        "ETA:  --:--:--"
      else
        elapsed_time = Time.now - @start_time
        estimated_time = elapsed_time * @total / @current - elapsed_time
        sprintf("ETA:  %s", format_time(estimated_time))
      end
    end
468156
function(string, t0)
	{
		if (mxLog.TRACE)
		{
			var dt = (t0 != 0) ? ' ('+(new Date().getTime() - t0)+' ms)' : '';
			mxLog.writeln('Leaving '+string+dt);
		}
	}
1333247
public String print(TemporalFormatter<Moment> printer) {

        return printer.withTimezone(this.getTimezone()).print(this.moment);

    }
42234
def capture_print(file_dest_maybe: Optional[IO] = None):
    """"""
    file_dest: IO = file_dest_maybe or sys.stderr

    def _print_progress(progress_min: float, rt_remaining: float, _mc: MeasureComparison) -> None:
        nonlocal file_dest
        percent_progress = progress_min * 100.0
        time_remaining, unit = _display_time(rt_remaining)
        print(
            f"Progress: {percent_progress:.1f}% -- Time remaining: {time_remaining} {unit}          ",
            end="\r",
            file=file_dest
        )

    return _print_progress
1080438
def get_remaining_time(program):
    '''
    
    '''
    now = datetime.datetime.now()
    program_start = program.get('start_time')
    program_end = program.get('end_time')
    if not program_start or not program_end:
        _LOGGER.error('Could not determine program start and/or end times.')
        _LOGGER.debug('Program data: %s', program)
        return
    if now > program_end:
        _LOGGER.error('The provided program has already ended.')
        _LOGGER.debug('Program data: %s', program)
        return 0
    progress = now - program_start
    return progress.seconds
7477
def logEndTime():
    """"""
    logger.info('\n' + '#' * 70)
    logger.info('Complete')
    logger.info(datetime.today().strftime("%A, %d %B %Y %I:%M%p"))
    logger.info('#' * 70 + '\n')
1088844
def print_last_values():
    """"""
    iterable = archive.list_parameter_values('/YSS/SIMULATOR/BatteryVoltage1',
                                             descending=True)
    for pval in islice(iterable, 0, 10):
        print(pval)
396829
def _print(self, force_flush=False):
        
        self._stream_flush()
        next_perc = self._calc_percent()
        if self.update_interval:
            do_update = time.time() - self.last_time >= self.update_interval
        elif force_flush:
            do_update = True
        else:
            do_update = next_perc > self.last_progress

        if do_update and self.active:
            self.last_progress = next_perc
            self._cache_percent_indicator(self.last_progress)
            if self.track:
                self._cached_output += ' Time elapsed: ' + \
                                       self._get_time(self._elapsed())
                self._cache_eta()
            if self.item_id:
                self._cache_item_id()
            self._stream_out('\r%s' % self._cached_output)
            self._stream_flush()
            self._cached_output = ''
38743
def print_time(self, message="Time is now: ", print_frame_info=True):
        
        if print_frame_info:
            frame_info = inspect.getouterframes(inspect.currentframe())[1]
            print(message, (datetime.now() - self.start_time), frame_info)
        else:
            print(message, (datetime.now() - self.start_time))