<commit_before>const yearMs = (1000 * 60 * 60 * 24 * 365);

class Timeline {
    constructor(element, INTERVALS, EVENTS) {
        element.classList.add('timeline');
        INTERVALS = this.computeOverlap(INTERVALS);

        const minDt = new Date(0);
        minDt.setFullYear(0);
        const maxDt = new Date();

        const years = ((maxDt - minDt) / yearMs) -2; // milliseconds
        const w = (years * 12), // 3px / month
              h = vhToPx(44.72);
            
        const axisY = vhToPx(37)

        const x = d3.scaleTime()
            .range([0, w])
            .domain([minDt, maxDt]);

        const svgContainer = d3.select(element)
            .append('svg:svg')
            .attr('width' , w + 200)
            .attr('height' , h);
        
        const svg = svgContainer
            .append('svg:svg')
            .attr('width' , w)
            .attr('height' , h)
            .attr('translate' , 'transform(100, 0)');

        // fake axis
        for (var i=0; i<(years); i++) {
            if (i%100==0) {
                let factor = 1
                if (i+100 > years){
                    factor = (years - i) / 100

                    svg.append('svg:text')
                        .text(Math.round(years))
                        .attr('class' , 'x axis-text')
                        .attr('x' , ((12) * years))
                        .attr('y' , (axisY + 8));<commit_msg>fix small placing thing<commit_after>const yearMs = (1000 * 60 * 60 * 24 * 365);

class Timeline {
    constructor(element, INTERVALS, EVENTS) {
        element.classList.add('timeline');
        INTERVALS = this.computeOverlap(INTERVALS);

        const minDt = new Date(0);
        minDt.setFullYear(0);
        const maxDt = new Date();

        const years = ((maxDt - minDt) / yearMs) -2; // milliseconds
        const w = (years * 12), // 3px / month
              h = vhToPx(44.72);
            
        const axisY = vhToPx(37)

        const x = d3.scaleTime()
            .range([0, w])
            .domain([minDt, maxDt]);

        const svgContainer = d3.select(element)
            .append('svg:svg')
            .attr('width' , w)
            .attr('height' , h);
        
        const svg = svgContainer
            .append('svg:svg')
            .attr('width' , w)
            .attr('height' , h);

        // fake axis
        for (var i=0; i<(years); i++) {
            if (i%100==0) {
                let factor = 1
                if (i+100 > years){
                    factor = (years - i) / 100

                    svg.append('svg:text')
                        .text(Math.round(years))
                        .attr('class' , 'x axis-text')
                        .attr('x' , ((12) * years))
                        .attr('y' , (axisY + 8));
{'fraction_non_alphanumeric': 0.14793536804308796, 'fraction_numerical': 0.03339317773788151, 'mean_word_length': 1.2967848309975267, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, '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': '704164', 'n_tokens_mistral': 950, 'n_tokens_neox': 845, 'n_words': 196}