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

A Python to Vega translator. Python data structures go in, Vega grammar
comes out.

'''

from __future__ import print_function
from __future__ import division
import os
import json
import time
import itertools
from pkg_resources import resource_string
from string import Template
import pandas as pd


class Vega(object):
    '''Vega abstract base class'''

    def __init__(self, width=400, height=200,
                 padding={'top': 10, 'left': 30, 'bottom': 20, 'right': 20},
                 viewport=None):
        '''
        The Vega classes generate JSON output in Vega grammar, a
        declarative format for creating and saving visualization designs.
        This class is meant to be an abstract base class on which to build
        the other piece of the complete VEGA specification.

        A Vega object is instantiated with only the Vega Visualization basic,
        properties, with default values for the name, width, height, padding,
        and viewport.

        Parameters:
        -----------

        width: int, default 800
            Width of the visualization
        height: int, default 400
            Height of the visualization
        padding: dict, default {'top': 10, 'left': 30, 'bottom':20, 'right':10}
            Internal margins for the visualization, Top, Left, Bottom, Right
        viewport: list, default None
            Width and height of on-screen viewport

        '''

        self.width = width
        self.height = height
        self.padding = padding
        self.viewport = viewport
        self.visualization = {'width': self.width,
                              'padding': self.padding,
                              'viewport': self.viewport}<commit_msg>removed mutable object from class method signature.<commit_after># -*- coding: utf-8 -*-
'''
Vincent
-------

A Python to Vega translator. Python data structures go in, Vega grammar
comes out.

'''

from __future__ import print_function
from __future__ import division
import os
import json
import time
import itertools
from pkg_resources import resource_string
from string import Template
import pandas as pd


class Vega(object):
    '''Vega abstract base class'''

    def __init__(self, width=400, height=200, padding=None, viewport=None):
        '''
        The Vega classes generate JSON output in Vega grammar, a
        declarative format for creating and saving visualization designs.
        This class is meant to be an abstract base class on which to build
        the other piece of the complete VEGA specification.

        A Vega object is instantiated with only the Vega Visualization basic,
        properties, with default values for the name, width, height, padding,
        and viewport.

        Parameters:
        -----------

        width: int, default 800
            Width of the visualization
        height: int, default 400
            Height of the visualization
        padding: dict, default {'top': 10, 'left': 30, 'bottom':20, 'right':10}
            Internal margins for the visualization, Top, Left, Bottom, Right
        viewport: list, default None
            Width and height of on-screen viewport

        '''

        self.width = width
        self.height = height
        self.padding = padding or {
            'top': 10, 'left': 30, 'bottom': 20, 'right': 20
        }
        self.viewport = viewport
        self.visualization = {'width': self.width,
                              'padding': self.padding,
                              'viewport': self.viewport}
{'fraction_non_alphanumeric': 0.08328690807799442, 'fraction_numerical': 0.01615598885793872, 'mean_word_length': 2.223518850987433, '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': '7106284', 'n_tokens_mistral': 963, 'n_tokens_neox': 869, 'n_words': 383}