Print a summary of the environment definitions.
486411
public function printSummary() {
    drush_print();

    // Print env files used for this definition.
    drush_print($this->formatHeading('Environment Definitions Found'));
    foreach ($this->loadedEnvs as $filename) {
      drush_print("{$filename}", 1);
    }

    drush_print();
    drush_print($this->formatHeading(dt("CONFIGURATION SUMMARY")));

    // We want to make sure they are printed in the same order as they will run.
    foreach ($this->getActiveDefinition() as $group => $options) {
      // Print a nice heading.
      $heading = $this->formatHeading($group);

      switch (strtolower($group)) {
        case 'modules':
          $this->printModuleSummary($options, $heading);
          break;

        case 'variables':
          $this->printVariableSummary($options, $heading);
          break;

        case 'permissions':
          $this->printPermissionSummary($options, $heading);
          break;

        case 'commands':
          $this->printCommandSummary($options, $heading);
          break;

        default:
          drush_print($this->formatHeading($group));
          drush_log(dt("I'm not sure what to do with '@group'.", ['@group' => $group]), 'warning');
          break;
      }
    }
  }
314417
def _summaries(self):
        
        for var in tf.trainable_variables():
            tf.summary.histogram(var.name, var)
            print(var.name)
307005
def summary( self ):
        
        child_text = []
        
        for c in range(self.childCount()):
            child = self.child(c)
            text = [child.text(0), child.text(1), child.text(2), child.text(3)]
            text = map(str, text)
            
            while ( '' in text ):
                text.remove('')
            
            child_text.append( ' '.join(text) )
        
        return ' '.join(child_text)
718388
def summary(self):
        """"""

        res = ("nlive: {:d}\n"
               "niter: {:d}\n"
               "ncall: {:d}\n"
               "eff(%): {:6.3f}\n"
               "logz: {:6.3f} +/- {:6.3f}"
               .format(self.nlive, self.niter, sum(self.ncall),
                       self.eff, self.logz[-1], self.logzerr[-1]))

        print('Summary\n=======\n'+res)
216199
def summary(logfile, time_format):
  ""

  def output(summary):
    width = max([len(p[0]) for p in summary]) + 3
    print '\n'.join([
      "%s%s%s" % (p[0], ' ' * (width - len(p[0])),
        colored(minutes_to_txt(p[1]), 'red')) for p in summary])

  output(server.summarize(read(logfile, time_format, only_elapsed=True)))
648654
def summarize(self, file: Optional[TextIO] = None) -> None:
        """"""
        print(self.summary_str(), file=file)
152305
def info():
    
    print()
    print('root directory         :', tasks.conf.APE_ROOT)
    print()
    print('active container       :', os.environ.get('CONTAINER_NAME', ''))
    print()
    print('active product         :', os.environ.get('PRODUCT_NAME', ''))
    print()
    print('ape feature selection  :', tasks.FEATURE_SELECTION)
    print()
    print('containers and products:')
    print('-' * 30)
    print()
    for container_name in tasks.get_containers():
        print(container_name)
        for product_name in tasks.get_products(container_name):
            print('    ' + product_name)
    print()
277706
def print_app_info (out=stderr):
    """"""
    print(_("System info:"), file=out)
    print(configuration.App, file=out)
    print(_("Released on:"), configuration.ReleaseDate, file=out)
    print(_("Python %(version)s on %(platform)s") %
                    {"version": sys.version, "platform": sys.platform}, file=out)
    for key in PYTHON_ENV_VARS:
        print_env_info(key, out=out)
    print(configuration.get_modules_info(), file=out)
    stime = strformat.strtime(time.time())
    print(_("Local time:"), stime, file=out)
    print(_("sys.argv:"), sys.argv, file=out)
93818
def print_summary(self) -> None:
        
        print("Tasks execution time summary:")
        for mon_task in self._monitor_tasks:
            print("%s:\t%.4f (sec)" % (mon_task.task_name, mon_task.total_time))
62299
def print_summary(self, verbose=False, no_color=False):
        ''

        types = {0: 'Unknown',
                 1: 'Extension/Multi-Extension',
                 2: 'Full Theme',
                 3: 'Dictionary',
                 4: 'Language Pack',
                 5: 'Search Provider',
                 7: 'Subpackage',
                 8: 'App'}
        detected_type = types[self.detected_type]

        buffer = StringIO()
        self.handler = OutputHandler(buffer, no_color)

        # Make a neat little printout.
        self.handler.write('\n<<GREEN>>Summary:') \
            .write('-' * 30) \
            .write('Detected type: <<BLUE>>%s' % detected_type) \
            .write('-' * 30)

        if self.failed():
            self.handler.write('<<BLUE>>Test failed! Errors:')

            # Print out all the errors/warnings:
            for error in self.errors:
                self._print_message('<<RED>>Error:<<NORMAL>>\t',
                                    error, verbose)
            for warning in self.warnings:
                self._print_message('<<YELLOW>>Warning:<<NORMAL>> ',
                                    warning, verbose)
        else:
            self.handler.write('<<GREEN>>All tests succeeded!')

        if self.notices:
            for notice in self.notices:
                self._print_message(prefix='<<WHITE>>Notice:<<NORMAL>>\t',
                                    message=notice,
                                    verbose=verbose)

        if 'is_jetpack' in self.metadata and verbose:
            self.handler.write('\n')
            self.handler.write('<<GREEN>>Jetpack add-on detected.<<NORMAL>>\n'
                               'Identified files:')
            if 'jetpack_identified_files' in self.metadata:
                for filename, data in \
                        self.metadata['jetpack_identified_files'].items():
                    self.handler.write((' %s\n' % filename) +
                                       ('  %s : %s' % data))

            if 'jetpack_unknown_files' in self.metadata:
                self.handler.write('Unknown files:')
                for filename in self.metadata['jetpack_unknown_files']:
                    self.handler.write(' %s' % filename)

        self.handler.write('\n')
        if self.unfinished:
            self.handler.write('<<RED>>Validation terminated early')
            self.handler.write('Errors during validation are preventing '
                               'the validation process from completing.')
            self.handler.write('Use the <<YELLOW>>--determined<<NORMAL>> '
                               'flag to ignore these errors.')
            self.handler.write('\n')

        return buffer.getvalue()
226533
def _printDescription(self, hrlinetop=True):
        """"""
        if hrlinetop:
            self._print("----------------")
        NOTFOUND = "[not found]"
        if self.currentEntity:
            obj = self.currentEntity['object']
            label = obj.bestLabel() or NOTFOUND
            description = obj.bestDescription() or NOTFOUND
            print(Style.BRIGHT + "OBJECT TYPE: " + Style.RESET_ALL +
                  Fore.BLACK + uri2niceString(obj.rdftype) + Style.RESET_ALL)
            print(Style.BRIGHT + "URI        : " + Style.RESET_ALL +
                  Fore.GREEN + "<" + unicode(obj.uri) + ">" + Style.RESET_ALL)
            print(Style.BRIGHT + "TITLE      : " + Style.RESET_ALL +
                  Fore.BLACK + label + Style.RESET_ALL)
            print(Style.BRIGHT + "DESCRIPTION: " + Style.RESET_ALL +
                  Fore.BLACK + description + Style.RESET_ALL)

        else:
            self._clear_screen()
            self._print("Graph: <" + self.current['fullpath'] + ">", 'TIP')
            self._print("----------------", "TIP")
            self._printStats(self.current['graph'])
            for obj in self.current['graph'].all_ontologies:
                print(Style.BRIGHT + "Ontology URI: " + Style.RESET_ALL +
                      Fore.RED + "<%s>" % str(obj.uri) + Style.RESET_ALL)
                # self._print("==> Ontology URI: <%s>" % str(obj.uri), "IMPORTANT")
                # self._print("----------------", "TIP")
                label = obj.bestLabel() or NOTFOUND
                description = obj.bestDescription() or NOTFOUND
                print(Style.BRIGHT + "Title       : " + Style.RESET_ALL +
                      Fore.BLACK + label + Style.RESET_ALL)
                print(Style.BRIGHT + "Description : " + Style.RESET_ALL +
                      Fore.BLACK + description + Style.RESET_ALL)
        self._print("----------------", "TIP")
1286324
def export_env(print:)
      Docker::Compose::Mapper.map(host_env,
                                  session: @session,
                                  net_info: @net_info) do |k, v|
        ENV[k] = serialize_for_env(v)
        print_env(k, ENV[k]) if print
      end

      extra_host_env.each do |k, v|
        ENV[k] = serialize_for_env(v)
        print_env(k, ENV[k]) if print
      end
    end
1256302
def print_summary(graph, tails, node_id_map):
    """"""
    # Get comparison data
    heads = get_heads(tails)
    heights = get_heights(tails)
    max_height = max(heights)
    common_height, block_ids_at_common_height = get_common_height(tails)
    lags = get_lags(heights, max_height)
    common_ancestor = graph.root
    divergences = get_divergences(heights, graph.root)

    # Print summary info
    col_1 = 8
    col_n = 8
    format_str = '{:<' + str(col_1) + '} ' + ('{:<' + str(col_n) + '} ') * 2
    header = format_str.format("COMMON", "HEIGHT", "BLOCKS")
    print(header)
    print("-" * len(header))
    print(format_str.format(
        "ANCESTOR", common_ancestor.num, common_ancestor.ident[:col_n]))
    print(format_str.format(
        "HEIGHT", common_height, str(block_ids_at_common_height)))
    print()

    # Print per-node data
    node_col_width = get_col_width_for_num(len(tails), len("NODE"))
    num_col_width = get_col_width_for_num(max_height, len("HEIGHT"))
    lag_col_width = get_col_width_for_num(max(lags), len("LAG"))
    diverg_col_width = get_col_width_for_num(max(divergences), len("DIVERG"))

    format_str = (
        '{:<' + str(node_col_width) + '} '
        '{:<8} '
        '{:<' + str(num_col_width) + '} '
        '{:<' + str(lag_col_width) + '} '
        '{:<' + str(diverg_col_width) + '}'
    )

    header = format_str.format("NODE", "HEAD", "HEIGHT", "LAG", "DIVERG")
    print(header)
    print('-' * len(header))

    for i, _ in enumerate(tails):
        print(format_str.format(
            node_id_map[i],
            heads[i],
            heights[i],
            lags[i],
            divergences[i],
        ))
    print()
1002347
def load_env(print_vars=False):
    
    env_file = os.environ.get('ENV_FILE', '.env')
    try:
        variables = open(env_file).read().splitlines()
        for v in variables:
            if '=' in v:
                key, value = v.split('=', 1)
                if key.startswith('#'):
                    continue
                if key not in os.environ:
                    if value.startswith('"') and value.endswith('"') or \
                                    value.startswith("'") and value.endswith("'"):
                        os.environ[key] = ast.literal_eval(value)
                    else:
                        os.environ[key] = value
                    if print_vars:
                        print(key, os.environ[key])
    except IOError:
        pass
1143356
def print_stats(self, stream=None):
        
        if not stream: # pragma: no cover
            stream = sys.stdout
        self.metadata.sort(key=lambda x: -x.size)
        stream.write('%-10s %8s %-12s %-46s\n' % ('id', 'size', 'type', 'representation'))
        for g in self.metadata:
            stream.write('0x%08x %8d %-12s %-46s\n' % (g.id, g.size, trunc(g.type, 12),
                trunc(g.str, 46)))
        stream.write('Garbage: %8d collected objects (%s in cycles): %12s\n' % \
            (self.count, self.num_in_cycles, pp(self.total_size)))
708435
def _print_breakdown(cls, savedir, fname, data):
        """"""
        if not os.path.exists(savedir):
            os.makedirs(savedir)

        with open(os.path.join(savedir, fname), 'w') as fout:
            fout.write(data)
52323
def show_info(self):
        """"""

        deltas = self.__get_delta_files()

        table = [['Version', 'Name', 'Type', 'Status']]

        for dir_ in deltas:
            print('delta files in dir: ', dir_)

            for delta in deltas[dir_]:
                line = [delta.get_version(), delta.get_name()]
                if delta.get_type() == DeltaType.PRE_PYTHON:
                    line.append('pre py')
                elif delta.get_type() == DeltaType.PRE_SQL:
                    line.append('pre sql')
                elif delta.get_type() == DeltaType.PYTHON:
                    line.append('delta py')
                elif delta.get_type() == DeltaType.SQL:
                    line.append('delta sql')
                elif delta.get_type() == DeltaType.POST_PYTHON:
                    line.append('post py')
                elif delta.get_type() == DeltaType.POST_SQL:
                    line.append('post sql')

                if self.__is_applied(delta):
                    line.append('Applied')
                else:
                    line.append('Pending')

                table.append(line)

        self.__print_table(table)

        print('')
        print('Applied upgrades in database')

        query = """SELECT
                version,
                description,
                type,
                installed_by,
                installed_on,
                success
                FROM {}
                """.format(self.upgrades_table)

        self.cursor.execute(query)
        records = self.cursor.fetchall()

        table = [['Version', 'Name', 'Type', 'Installed by', 'Installed on',
                  'Status']]

        for i in records:
            line = [str(i[0]), str(i[1])]
            delta_type = i[2]
            if delta_type == 0:
                line.append('baseline')
            elif delta_type == DeltaType.PRE_PYTHON:
                line.append('pre py')
            elif delta_type == DeltaType.PRE_SQL:
                line.append('pre sql')
            elif delta_type == DeltaType.PYTHON:
                line.append('delta py')
            elif delta_type == DeltaType.SQL:
                line.append('delta sql')
            elif delta_type == DeltaType.POST_PYTHON:
                line.append('post py')
            elif delta_type == DeltaType.POST_SQL:
                line.append('post sql')

            line.append(str(i[3]))
            line.append(str(i[4]))

            success = str(i[5])
            if success == 'True':
                line.append('Success')
            else:
                line.append('Failed')

            table.append(line)

        self.__print_table(table)