<commit_before># -*- coding: utf-8 -*-
import json
import os
import sys
import base64
import tkinter as tk
from tkinter import ttk
from functools import partial
from threading import Thread
from ss.settings import settings
from ss import utils
from ss.encrypt import CIPHERS_TO_TEST

if getattr(sys, 'frozen', None):
    basedir = sys._MEIPASS
else:
    basedir = os.path.dirname(__file__)

conf_dir = os.path.join(basedir, "conf")

PY2 = sys.version_info[0] == 2
DEFAULT_PAC = "../config/pac"

if PY2:
    from urllib import urlopen, urlencode
    import tkMessageBox as messagebox
else:
    from tkinter import messagebox
    from urllib.request import urlopen
    from urllib.parse import urlencode

class Row(object):

    def __init__(self, label, widget, bindvar):
        self.label = label
        self.widget = widget
        self.bindvar = bindvar

class Event(object):
    def __init__(self, event, callback):
        self.event = event
        self.callback = callback

class Form(object):
    
    def __init__(self):
        self.rows = []<commit_msg>compatible to pyinstall<commit_after># -*- coding: utf-8 -*-
import json
import os
import sys
import base64
import tkinter as tk
from tkinter import ttk
from functools import partial
from threading import Thread
from ss.settings import settings
from ss import utils
from ss.encrypt import CIPHERS_TO_TEST

if getattr(sys, 'frozen', None):
    basedir = sys._MEIPASS
    DEFAULT_PAC = "config/pac"
else:
    basedir = os.path.dirname(__file__)
    DEFAULT_PAC = "../config/pac"

conf_dir = os.path.join(basedir, "config/json")

PY2 = sys.version_info[0] == 2


if PY2:
    from urllib import urlopen, urlencode
    import tkMessageBox as messagebox
else:
    from tkinter import messagebox
    from urllib.request import urlopen
    from urllib.parse import urlencode

class Row(object):

    def __init__(self, label, widget, bindvar):
        self.label = label
        self.widget = widget
        self.bindvar = bindvar

class Event(object):
    def __init__(self, event, callback):
        self.event = event
        self.callback = callback

class Form(object):
    
    def __init__(self):
        self.rows = []
{'fraction_non_alphanumeric': 0.08657810352725608, 'fraction_numerical': 0.00641319285387082, 'mean_word_length': 3.257309941520468, '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': '1917141', 'n_tokens_mistral': 699, 'n_tokens_neox': 688, 'n_words': 220}