<commit_before><!DOCTYPE html>
<html>
<head>
    <title>Virtual Sky</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=2.0, user-scalable=yes" />
    <!-- Virtual Sky <canvas> application (c) 2010-2012 <NAME> (Las Cumbras Observatory Global Telescope)  -->
    <style>
        html,body { height: 100%; }
        body {
            font-family: Helvetica, sans-serif;
            color: black;
            margin: 0px;
            padding: 0px;
            height: 100%;
            width: 100%;
            font-size: 1em;
        }
        #starmapper {
            height: 100%;
            width:100%;
            position: relative;
        }
        #virtualskyinfobox{
            font-size: 12px;
            display:none;
            background-color:rgba(200,200,200,1);
            color:black;
            padding:5px;
            max-width:150px;
            border-radius:0.5em;
            -moz-border-radius: 0.5em;
            -webkit-border-radius: 0.5em;
            box-shadow:0px 0px 20px rgba(255,255,255,0.5);
            -moz-box-shadow:0px 0px 20px rgba(255,255,255,0.5);
            -webkit-box-shadow:0px 0px 20px rgba(255,255,255,0.5);
        }
        .virtualskyinfocredit{
            font-size:0.5em;
            float:left;
            position:absolute;
            padding:5px;
            color: white;}
        #virtualskyinfobox img { width: 128px; height: 128px; }
        </style>
        <!-- IE seems to get very confused if it loads Javascript from within a Javascript when in an iframe. We'll have to load it here --><!--[if IE]><script src="excanvas.min.js"></script><![endif]-->
        <script src="js/jquery-1.10.0.min.js"></script>
        <script src="js/virtualsky.js" type="text/javascript"></script>
        <script>
        window.onload = function(){
            //planetarium = new VirtualSky({id:'starmapper',callback:{geo:geoIP}});
            $("#showOctocat").on('change', function(e) { toggleOctocat() })
            jQuery.ajax({
                url: 'data/exos_radians.json',
                complete: function(e) {
                    exos = $.parseJSON(e.responseText).exos;
                    // Output values: name, apparentmagnitude, ra, dec, jupiter_mass, earth_mass, axis_au, disc_method, disc_year, distance, host_mass
                    planetarium = $.virtualsky({
                        id:'starmapper',
                        atmosphere: false,
                        live: true,
                        magnitude: 6,
                        projection: "mollweide",
                        exos: exos,
                        showstars: false,
                        showplanets: false,
                        showplanetlabels: false,
                        fullscreen:true
                    });
                    planetarium.draw();
                }
            })
        };
        function toggleOctocat() {
            if($("#showOctocat").is(":checked")) {
                planetarium.showstarsbackup = planetarium.showstars;
                planetarium.starsbackup = planetarium.stars.slice(0);
                $.get('octo_path.svg', function(s) {
                    octosvg = s.children[0];
                    p = octosvg.getElementsByTagName("path")[0];
                    L = p.getTotalLength();
                    x=[]; y=[];
                    for(var l=0; l<L; l += (10 + Math.random()*20)) {
                        pt = p.getPointAtLength(l)
                        x.push(pt['x']);
                        y.push(pt['y']);
                    }
                    MAXANGLE = 1.0;
                    xmin = Math.min(...x);
                    x = x.map(function(e) { return e-xmin });
                    xmax = Math.max(...x);
                    x = x.map(function(e) { return e*1.5*MAXANGLE/xmax });
                    ymin = Math.min(...y);
                    y = y.map(function(e) { return e-ymin });
                    ymax = Math.max(...y);
                    y = y.map(function(e) { return -e*MAXANGLE/ymax });
                    x.forEach(function(e,i,a) { planetarium.stars.push([677, -1, x[i], y[i]]); })
                    planetarium.showstars = true;
                    planetarium.draw();
                });
            } else {
                console.log("go back D:");
                planetarium.showstars = planetarium.showstarsbackup;
                planetarium.stars = planetarium.starsbackup;
                planetarium.draw();
            }
        }
        </script>
    <style type="text/css">
        body {
            background-color: #111111;
        }
        #controls {
            color: white;
        }
    </style>
    </head>

    <body>
        <div id="controls">
            Draw a sweet Octocat: <input type="checkbox" id="showOctocat"/><BR/>
            <!-- Draw stars: <input type="checkbox" id="showStars"/><BR/>
            Draw exoplanets: <input type="checkbox" id="showExos"/><BR/> -->
        </div>
        <div id="starmapper"></div>
    </body>
    </html><commit_msg>Added some filtering checkboxes for sifting through data by discovery method<commit_after><!DOCTYPE html>
<html>
<head>
    <title>Virtual Sky</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=2.0, user-scalable=yes" />
    <!-- Virtual Sky <canvas> application (c) 2010-2012 <NAME> (Las Cumbras Observatory Global Telescope)  -->
    <style>
        html,body { height: 100%; }
        body {
            font-family: Helvetica, sans-serif;
            color: black;
            margin: 0px;
            padding: 0px;
            height: 100%;
            width: 100%;
            font-size: 1em;
        }
        #starmapper {
            height: 100%;
            width:100%;
            position: relative;
        }
        #virtualskyinfobox{
            font-size: 12px;
            display:none;
            background-color:rgba(200,200,200,1);
            color:black;
            padding:5px;
            max-width:150px;
            border-radius:0.5em;
            -moz-border-radius: 0.5em;
            -webkit-border-radius: 0.5em;
            box-shadow:0px 0px 20px rgba(255,255,255,0.5);
            -moz-box-shadow:0px 0px 20px rgba(255,255,255,0.5);
            -webkit-box-shadow:0px 0px 20px rgba(255,255,255,0.5);
        }
        .virtualskyinfocredit{
            font-size:0.5em;
            float:left;
            position:absolute;
            padding:5px;
            color: white;}
        #virtualskyinfobox img { width: 128px; height: 128px; }
        </style>
        <!-- IE seems to get very confused if it loads Javascript from within a Javascript when in an iframe. We'll have to load it here --><!--[if IE]><script src="excanvas.min.js"></script><![endif]-->
        <script src="js/jquery-1.10.0.min.js"></script>
        <script src="js/virtualsky.js" type="text/javascript"></script>
        <script>
        window.onload = function(){
            //planetarium = new VirtualSky({id:'starmapper',callback:{geo:geoIP}});
            $("#showOctocat").on('change', function(e) { toggleOctocat() })
            jQuery.ajax({
                url: 'data/exos_radians.json',
                complete: function(e) {
                    exos = $.parseJSON(e.responseText).exos;
                    // Output values: name, apparentmagnitude, ra, dec, jupiter_mass, earth_mass, axis_au, disc_method, disc_year, distance, host_mass
                    planetarium = $.virtualsky({
                        id:'starmapper',
                        atmosphere: false,
                        live: true,
                        magnitude: 6,
                        projection: "mollweide",
                        exos: exos,
                        showstars: false,
                        showplanets: false,
                        showplanetlabels: false,
                        fullscreen:true
                    });
                    $("#showStars").on('change', function(e) { planetarium.showstars = !planetarium.showstars; });
                    $(".exofilter").on('change', function(e) { updateExos(); });
                    planetarium.draw();
                }
            })
        };
        function updateExos() {
            planetarium.exos = exos.filter(function(e) {
                return ($("#exo_timing").is(":checked") && e[7] == "timing") ||
                ($("#exo_RV").is(":checked") && e[7] == "RV") ||
                ($("#exo_transit").is(":checked") && e[7] == "transit") ||
                ($("#exo_microlensing").is(":checked") && e[7] == "microlensing") ||
                ($("#exo_imaging").is(":checked") && e[7] == "imaging");
            });
        }
        function toggleOctocat() {
            if($("#showOctocat").is(":checked")) {
                planetarium.showstarsbackup = planetarium.showstars;
                planetarium.starsbackup = planetarium.stars.slice(0);
                $.get('octo_path.svg', function(s) {
                    octosvg = s.children[0];
                    p = octosvg.getElementsByTagName("path")[0];
                    L = p.getTotalLength();
                    x=[]; y=[];
                    for(var l=0; l<L; l += (10 + Math.random()*20)) {
                        pt = p.getPointAtLength(l)
                        x.push(pt['x']);
                        y.push(pt['y']);
                    }
                    MAXANGLE = 1.0;
                    xmin = Math.min(...x);
                    x = x.map(function(e) { return e-xmin });
                    xmax = Math.max(...x);
                    x = x.map(function(e) { return e*1.5*MAXANGLE/xmax });
                    ymin = Math.min(...y);
                    y = y.map(function(e) { return e-ymin });
                    ymax = Math.max(...y);
                    y = y.map(function(e) { return -e*MAXANGLE/ymax });
                    x.forEach(function(e,i,a) { planetarium.stars.push([677, -1, x[i], y[i]]); })
                    // planetarium.showstars = true;
                    planetarium.draw();
                });
            } else {
                // planetarium.showstars = planetarium.showstarsbackup;
                planetarium.stars = planetarium.starsbackup;
                planetarium.draw();
            }
        }
        </script>
    <style type="text/css">
        body {
            background-color: #111111;
        }
        #controls {
            color: white;
        }
    </style>
    </head>

    <body>
        <div id="controls">
            Draw a sweet Octocat: <input type="checkbox" id="showOctocat"/><BR/>
            Draw stars: <input type="checkbox" id="showStars"/><BR/>
            Transit: <input type="checkbox" class="exofilter" id="exo_transit"/><BR/>
            Timing: <input type="checkbox" class="exofilter" id="exo_timing"/><BR/>
            Radial velocity: <input type="checkbox" class="exofilter" id="exo_RV"/><BR/>
            Microlensing: <input type="checkbox" class="exofilter" id="exo_microlensing"/><BR/>
            Imaging: <input type="checkbox" class="exofilter" id="exo_imaging"/><BR/>
        </div>
        <div id="starmapper"></div>
    </body>
    </html>
{'fraction_non_alphanumeric': 0.1451670220326937, 'fraction_numerical': 0.02407604832977967, 'mean_word_length': 1.4349989184512222, 'pattern_counts': {'":': 7, '<': 90, '<?xml version=': 0, '>': 88, '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': '1613699', 'n_tokens_mistral': 3530, 'n_tokens_neox': 3202, 'n_words': 608}