<commit_before>#!/usr/bin/env python

from distribute_setup import use_setuptools
use_setuptools()

import os
# Prevent distutils from trying to create hard links
# which are not allowed on AFS between directories.
# This is a hack to force copying.
try:
    del os.link
except AttributeError:
    pass

try:
    from setuptools.core import setup
except ImportError:
    from distutils.core import setup

from glob import glob
from os.path import join
import sys

if sys.version_info < (2, 6):
    raise RuntimeError("rootpy only supports python 2.6 and above")

local_path = os.path.dirname(os.path.abspath(__file__))
# setup.py can be called from outside the rootpy directory
os.chdir(local_path)
sys.path.insert(0, local_path)

# check for custom args
# we should instead extend distutils...
filtered_args = []
release = False<commit_msg>check for ROOT and ROOT version in setup.py<commit_after>#!/usr/bin/env python

import sys

# check Python version
if sys.version_info < (2, 6):
    raise RuntimeError("rootpy only supports python 2.6 and above")

# check that ROOT can be imported
try:
    import ROOT
except ImportError:
    raise RuntimeError(
        "ROOT cannot be imported. Is ROOT installed with PyROOT enabled?")

# check that we have at least the minimum required version of ROOT
ROOT_VERSION = ROOT.gROOT.GetVersionInt()
if ROOT_VERSION < 52800:
    raise RuntimeError(
        "rootpy requires at least ROOT 5.28/00; "
        "You have {0:d}.{1:02d}/{2:02d}.".format(
            int(ROOT_VERSION / 1E4),
            int(ROOT_VERSION / 1E2) % 100,
            ROOT_VERSION % 100))

from distribute_setup import use_setuptools
use_setuptools()

import os
# Prevent distutils from trying to create hard links
# which are not allowed on AFS between directories.
# This is a hack to force copying.
try:
    del os.link
except AttributeError:
    pass

try:
    from setuptools.core import setup
except ImportError:
    from distutils.core import setup

from glob import glob
from os.path import join

local_path = os.path.dirname(os.path.abspath(__file__))
# setup.py can be called from outside the rootpy directory
os.chdir(local_path)
sys.path.insert(0, local_path)

# check for custom args
# we should instead extend distutils...
filtered_args = []
release = False
{'fraction_non_alphanumeric': 0.07752956636005257, 'fraction_numerical': 0.016206745510293472, 'mean_word_length': 3.778242677824268, 'pattern_counts': {'":': 0, '<': 6, '<?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': '7598220', 'n_tokens_mistral': 722, 'n_tokens_neox': 689, 'n_words': 262}