<commit_before>def dot(a, b):
    ''' Matrixmultiplication
        :param RaytracerColor a: color triple
        :param RaytracerColor b: color triple
        :returns matrixmultiplicition of a and b
    '''
    return RaytracerColor(a.r * b.r, a.g * b.g, a.b * b.b)


class RaytracerColor:
    ''' represents a color
    '''
    def __init__(self, r=0.0, g=0.0, b=0.0):
        ''' :param float r: red color component between 0 and 1
            :param float g: green color component between 0 and 1
            :param float b: blue color component between 0 and 1
            :var float r: red color component between 0 and 1
            :var float g: green color component between 0 and 1
            :var float b: blue color component between 0 and 1
        '''
        self._r = r
        self._g = g
        self._b = b
<commit_msg>Add color parsing<commit_after>def dot(a, b):
    ''' Matrixmultiplication
        :param RaytracerColor a: color triple
        :param RaytracerColor b: color triple
        :returns matrixmultiplicition of a and b
    '''
    return RaytracerColor(a.r * b.r, a.g * b.g, a.b * b.b)

def parse(color_node):
    return RaytracerColor(color_node.attrib['r'],
                          color_node.attrib['g'],
                          color_node.attrib['b'])


class RaytracerColor:
    ''' represents a color
    '''
    def __init__(self, r=0.0, g=0.0, b=0.0):
        ''' :param float r: red color component between 0 and 1
            :param float g: green color component between 0 and 1
            :param float b: blue color component between 0 and 1
            :var float r: red color component between 0 and 1
            :var float g: green color component between 0 and 1
            :var float b: blue color component between 0 and 1
        '''
        self._r = r
        self._g = g
        self._b = b

{'fraction_non_alphanumeric': 0.09159482758620689, 'fraction_numerical': 0.01939655172413793, 'mean_word_length': 1.9807383627608346, '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': '3118421', 'n_tokens_mistral': 570, 'n_tokens_neox': 542, 'n_words': 214}