<commit_before># Licensed under a 3-clause BSD style license - see LICENSE.rst

import numpy as np
from Chandra.Time import DateTime, convert, convert_vals, date2secs, secs2date
from cxotime import CxoTime
import time


def test_convert_vals_scalar():
    fmts = ['date', 'secs', 'jd', 'mjd', 'fits', 'caldate']
    vals = {fmt: getattr(DateTime('2012:001'), fmt) for fmt in fmts}
    for fmt_in in fmts:
        val = vals[fmt_in]
        for fmt_out in fmts:
            if fmt_in != fmt_out:
                convert_val = convert_vals(val, fmt_in, fmt_out)
                convert_back = convert_vals(convert_val, fmt_out, fmt_in)
                if val != convert_back:<commit_msg>Change import syntax for running pytest directly<commit_after># Licensed under a 3-clause BSD style license - see LICENSE.rst

import numpy as np
from ..Time import DateTime, convert, convert_vals, date2secs, secs2date
from cxotime import CxoTime
import time


def test_convert_vals_scalar():
    fmts = ['date', 'secs', 'jd', 'mjd', 'fits', 'caldate']
    vals = {fmt: getattr(DateTime('2012:001'), fmt) for fmt in fmts}
    for fmt_in in fmts:
        val = vals[fmt_in]
        for fmt_out in fmts:
            if fmt_in != fmt_out:
                convert_val = convert_vals(val, fmt_in, fmt_out)
                convert_back = convert_vals(convert_val, fmt_out, fmt_in)
                if val != convert_back:
{'fraction_non_alphanumeric': 0.09792709077912795, 'fraction_numerical': 0.014295925661186561, 'mean_word_length': 3.0, 'pattern_counts': {'":': 0, '<': 3, '<?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': '7296244', 'n_tokens_mistral': 482, 'n_tokens_neox': 446, 'n_words': 143}