<commit_before>'''
Created on Feb 6, 2015

@author: cmccully
'''
import om10
import numpy as np
from lsst.sims.catUtils.baseCatalogModels import GalaxyAgnObj
import random


class sprinklerAGN(GalaxyAgnObj):
    objid = 'sprinklerAGN'
    objectTypeID = 1024

    def _final_pass(self, results):
        print('got here.')
        sp = sprinkler(results)
        results = sp.sprinkle()
        return results


class sprinkler():
    def __init__(self, catsim_cat):
        self.catalog = catsim_cat
        # ****** THIS ASSUMES THAT THE ENVIRONMENT VARIABLE OM10_DIR IS SET *******
        lensdb = om10.DB(catalog=os.environ['OM10_DIR']+"/data/qso_mock.fits")
        self.lenscat = lensdb.lenses.copy()
        return

    def sprinkle(self):
        # For each galaxy in the catsim catalog
        updated_catalog = self.catalog.copy()<commit_msg>Fixed os import.<commit_after>'''
Created on Feb 6, 2015

@author: cmccully
'''
import om10
import numpy as np
from lsst.sims.catUtils.baseCatalogModels import GalaxyAgnObj
import random
import os


class sprinklerAGN(GalaxyAgnObj):
    objid = 'sprinklerAGN'
    objectTypeID = 1024

    def _final_pass(self, results):
        print('got here.')
        sp = sprinkler(results)
        results = sp.sprinkle()
        return results


class sprinkler():
    def __init__(self, catsim_cat):
        self.catalog = catsim_cat
        # ****** THIS ASSUMES THAT THE ENVIRONMENT VARIABLE OM10_DIR IS SET *******
        lensdb = om10.DB(catalog=os.environ['OM10_DIR']+"/data/qso_mock.fits")
        self.lenscat = lensdb.lenses.copy()
        return

    def sprinkle(self):
        # For each galaxy in the catsim catalog
        updated_catalog = self.catalog.copy()
{'fraction_non_alphanumeric': 0.10762070971495055, 'fraction_numerical': 0.01977894124490983, 'mean_word_length': 3.0, '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': '1511734', 'n_tokens_mistral': 598, 'n_tokens_neox': 551, 'n_words': 141}