<commit_before>package net.hyperic.sigar.cmd;

import net.hyperic.sigar.CpuPerc;
import net.hyperic.sigar.Sigar;
import net.hyperic.sigar.SigarException;

/**
 * Display cpu information for each cpu found on the system.
 */
public class CpuInfo extends SigarCommandBase {

    public boolean displayTimes = true;
    
    public CpuInfo(Shell shell) {
        super(shell);
    }

    public CpuInfo() {
        super();
    }

    public String getUsageShort() {
        return "Display cpu information";
    }

    public void output(String[] args) throws SigarException {
        net.hyperic.sigar.CpuInfo[] infos =
            this.sigar.getCpuInfoList();

        CpuPerc[] cpus = null;

        println(infos.length + " total CPUs..");

        for (int i=0; i<infos.length; i++) {
            net.hyperic.sigar.CpuInfo info = infos[i];
            long cacheSize = info.getCacheSize();
            println("Vendor........" + info.getVendor());
            println("Model........." + info.getModel());
            println("Mhz..........." + info.getMhz());
            if (cacheSize != Sigar.FIELD_NOTIMPL) {
                println("Cache size...." + cacheSize);
            }
            if (!this.displayTimes) {
                continue;
            }
            if (cpus == null) {
                cpus = this.sigar.getCpuPercList();
            }
            CpuPerc cpu = cpus[i];
            println("User Time....." + CpuPerc.format(cpu.getUser()));
            println("Sys Time......" + CpuPerc.format(cpu.getSys()));
            println("Idle Time....." + CpuPerc.format(cpu.getIdle()));
            println("Wait Time....." + CpuPerc.format(cpu.getWait()));
            println("Nice Time....." + CpuPerc.format(cpu.getNice()));
            println("Combined......" + CpuPerc.format(cpu.getCombined()));
            
            println("");
        }
    }
<commit_msg>only print cpuinfo once, it'll be the same for each<commit_after>package net.hyperic.sigar.cmd;

import net.hyperic.sigar.CpuPerc;
import net.hyperic.sigar.Sigar;
import net.hyperic.sigar.SigarException;

/**
 * Display cpu information for each cpu found on the system.
 */
public class CpuInfo extends SigarCommandBase {

    public boolean displayTimes = true;
    
    public CpuInfo(Shell shell) {
        super(shell);
    }

    public CpuInfo() {
        super();
    }

    public String getUsageShort() {
        return "Display cpu information";
    }

    public void output(String[] args) throws SigarException {
        net.hyperic.sigar.CpuInfo[] infos =
            this.sigar.getCpuInfoList();

        CpuPerc[] cpus = null;

        println(infos.length + " total CPUs..");
        net.hyperic.sigar.CpuInfo info = infos[0];
        long cacheSize = info.getCacheSize();
        println("Vendor........" + info.getVendor());
        println("Model........." + info.getModel());
        println("Mhz..........." + info.getMhz());
        if (cacheSize != Sigar.FIELD_NOTIMPL) {
            println("Cache size...." + cacheSize);
        }

        if (!this.displayTimes) {
            return;
        }

        for (int i=0; i<infos.length; i++) {
            if (cpus == null) {
                cpus = this.sigar.getCpuPercList();
            }
            CpuPerc cpu = cpus[i];
            println("User Time....." + CpuPerc.format(cpu.getUser()));
            println("Sys Time......" + CpuPerc.format(cpu.getSys()));
            println("Idle Time....." + CpuPerc.format(cpu.getIdle()));
            println("Wait Time....." + CpuPerc.format(cpu.getWait()));
            println("Nice Time....." + CpuPerc.format(cpu.getNice()));
            println("Combined......" + CpuPerc.format(cpu.getCombined()));
            
            println("");
        }
    }

{'fraction_non_alphanumeric': 0.16326530612244897, 'fraction_numerical': 0.0007951232441028359, 'mean_word_length': 1.8569265707797122, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3626934', 'n_tokens_mistral': 1177, 'n_tokens_neox': 1130, 'n_words': 225}