<commit_before># -*- coding: utf-8 -*-

# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
"""Ceilometer collectd plugin units definition"""

from __future__ import unicode_literals


# Unit mappings in alphabetical order
UNITS = {
    'apache.apache_idle_workers':   'Workers',
    'apache.apache_bytes':          'B/s',
    'apache.apache_requests':       'Req/s',
    'apache.apache_scoreboard':     'Slots',
    'apache.apache_connections':    'Connections',

    'apcups.timeleft':      's',
    'apcups.temperature':   '°C',
    'apcups.percent':       'Load',
    'apcups.charge':        'Ah',
    'apcups.frequency':     'Hz',
    'apcups.voltage':       'V',

    # 'ascent': 'None',

    'battery.current': 'A',
    'battery.charge':  'Ah',
    'battery.voltage': 'V',

    # 'bind': 'None',

    'chrony.clock_last_meas':    's',
    'chrony.clock_last_update':  's',
    'chrony.clock_mode':         '',
    'chrony.clock_reachability': '',
    'chrony.clock_skew_ppm':     'ppm',
    'chrony.clock_state':        '',
    'chrony.clock_stratum':      '',
    'chrony.frequency_error':    'ppm',
    'chrony.root_delay':         's',
    'chrony.root_dispersion':    '',
    'chrony.time_offset':        's',
    'chrony.time_offset_ntp':    's',
    'chrony.time_offset_rms':    's',
    'chrony.time_ref':           's',

    'conntrack': 'Entries',
    'contextswitch': 'Sw./s',
    'cpu': 'jiffies',
    'cpufreq': 'MHz',
    'cpusleep.total_time_in_ms': 'ms',

    'dbi': 'Count',
    'dbi.mysql_databasesize': 'B',
    'dbi.pg_db_size': 'MB',

    'df': 'B',

    'disk.disk_merged':     'Ops/s',
    'disk.disk_octets':     'B/s',
    'disk.disk_ops':        'Ops/s',
    'disk.disk_time':       's',

    'dns.dns_opcode':   'Queries/s',
    'dns.dns_qtype':    'Queries/s',
    'dns.dns_octets':   'b/s',
    'dns.dns_rcode':    'Queries/s',

    'entropy': 'b',

    'filecount.files': 'Files',
    'filecount.bytes': 'B',

    'gps.dilution_of_precision': 'm',
    'gps.satellites':            'Satellites',

    'hddtemp': '°C',

    'interface.if_dropped': 'Packets/s',
    'interface.if_errors':  'Errors/s',
    'interface.if_packets': 'Packets/s',
    'interface.if_octets':  'B/s',<commit_msg>Add unit mappings for new plugins collectd 5.7.2<commit_after># -*- coding: utf-8 -*-

# Licensed under the Apache License, Version 2.0 (the "License"); you may
# not use this file except in compliance with the License. You may obtain
# a copy of the License at
#
#      http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
# License for the specific language governing permissions and limitations
# under the License.
"""Ceilometer collectd plugin units definition"""

from __future__ import unicode_literals


# Unit mappings in alphabetical order
UNITS = {
    'apache.apache_idle_workers':   'Workers',
    'apache.apache_bytes':          'B/s',
    'apache.apache_requests':       'Req/s',
    'apache.apache_scoreboard':     'Slots',
    'apache.apache_connections':    'Connections',

    'apcups.timeleft':      's',
    'apcups.temperature':   '°C',
    'apcups.percent':       'Load',
    'apcups.charge':        'Ah',
    'apcups.frequency':     'Hz',
    'apcups.voltage':       'V',

    # 'ascent': 'None',

    'battery.current': 'A',
    'battery.charge':  'Ah',
    'battery.voltage': 'V',

    # 'bind': 'None',

    'chrony.clock_last_meas':    's',
    'chrony.clock_last_update':  's',
    'chrony.clock_mode':         '',
    'chrony.clock_reachability': '',
    'chrony.clock_skew_ppm':     'ppm',
    'chrony.clock_state':        '',
    'chrony.clock_stratum':      '',
    'chrony.frequency_error':    'ppm',
    'chrony.root_delay':         's',
    'chrony.root_dispersion':    '',
    'chrony.time_offset':        's',
    'chrony.time_offset_ntp':    's',
    'chrony.time_offset_rms':    's',
    'chrony.time_ref':           's',

    'conntrack': 'Entries',
    'contextswitch': 'Sw./s',
    'cpu': 'jiffies',
    'cpufreq': 'MHz',
    'cpusleep.total_time_in_ms': 'ms',

    'dbi': 'Count',
    'dbi.mysql_databasesize': 'B',
    'dbi.pg_db_size': 'MB',

    'df': 'B',

    'disk.disk_merged':     'Ops/s',
    'disk.disk_octets':     'B/s',
    'disk.disk_ops':        'Ops/s',
    'disk.disk_time':       's',

    'dns.dns_opcode':   'Queries/s',
    'dns.dns_qtype':    'Queries/s',
    'dns.dns_octets':   'b/s',
    'dns.dns_rcode':    'Queries/s',

    'dpdkstat.derive':        'Errors',
    'dpdkstat.errors':        'Errors',
    'dpdkstat.if_rx_dropped': 'Dropped',
    'dpdkstat.if_rx_errors':  'Errors',
    'dpdkstat.if_rx_octets':  'Bytes',
    'dpdkstat.if_rx_packets': 'Packets',
    'dpdkstat.if_tx_errors':  'Errors',
    'dpdkstat.if_tx_octets':  'Bytes',
    'dpdkstat.if_tx_packets': 'Packets',
    'dpdkstat.operations':    'Ops',

    'entropy': 'b',

    'filecount.files': 'Files',
    'filecount.bytes': 'B',

    'gps.dilution_of_precision': 'm',
    'gps.satellites':            'Satellites',

    'hddtemp': '°C',

    'hugepages.bytes':           'Bytes',
    'hugepages.vmpage_number':   'Pages',
    'hugepages.percent':         '%',

    'intel_rdt.ipc':               'instructions/cycle',
    'intel_rdt.memory_bandwidth':  'Bytes',
    'intel_rdt.bytes':             'Bytes',

    'interface.if_dropped': 'Packets/s',
    'interface.if_errors':  'Errors/s',
    'interface.if_packets': 'Packets/s',
    'interface.if_octets':  'B/s',
{'fraction_non_alphanumeric': 0.1702266427523235, 'fraction_numerical': 0.0021196804174139897, 'mean_word_length': 2.744810744810745, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, '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': '5198016', 'n_tokens_mistral': 2273, 'n_tokens_neox': 2181, 'n_words': 447}