<commit_before>import csv

from sqlalchemy import func, desc

from flask import current_app

from models import Scans, OnOffPairs_Scans, OnOffPairs_Stops
from api import db


GREEN_STATUS = '#76DB55'
RED_STATUS = '#DB5555'
INBOUND = '1'
OUTBOUND = '0'
DIRECTION = {'1':'Inbound', '0':'Outbound'}
TRAINS = ['190','193','194','200']
QUOTAS = "/home/meyersj/api/app/data/route_quotas.csv"



def quota(quotas_csv, route, target):
    data = {}

    with open(quotas_csv, 'rb') as csv_file:<commit_msg>changes<commit_after>import csv, os

from sqlalchemy import func, desc

from flask import current_app

from models import Scans, OnOffPairs_Scans, OnOffPairs_Stops
from api import db, app


GREEN_STATUS = '#76DB55'
RED_STATUS = '#DB5555'
INBOUND = '1'
OUTBOUND = '0'
DIRECTION = {'1':'Inbound', '0':'Outbound'}
TRAINS = ['190','193','194','200']
QUOTAS = "/home/meyersj/api/app/data/route_quotas.csv"
#QUOTAS = os.path.join(app.config["ROOT_DIR"], "data/route_quotas.csv")


def quota(quotas_csv, route, target):
    data = {}

    with open(quotas_csv, 'rb') as csv_file:
{'fraction_non_alphanumeric': 0.15140186915887852, 'fraction_numerical': 0.044859813084112146, 'mean_word_length': 5.413173652694611, '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': '625017', 'n_tokens_mistral': 452, 'n_tokens_neox': 404, 'n_words': 96}