This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[('http://dessne.cosmology.illinois.edu/SNWG/web/display/examineCand.php?SNId=1098152', | |
'z=0.129', | |
'numepochs=17', | |
'numepochs_ml=0'), | |
('http://dessne.cosmology.illinois.edu/SNWG/web/display/examineCand.php?SNId=1098305', | |
'z=0.129', | |
'numepochs=17', | |
'numepochs_ml=0'), | |
('http://dessne.cosmology.illinois.edu/SNWG/web/display/examineCand.php?SNId=1052550', | |
'z=0.216', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[('http://dessne.cosmology.illinois.edu/SNWG/web/display/examineCand.php?SNId=1098152', | |
'z=0.129', | |
'numepochs=17', | |
'numepochs_ml=0'), | |
('http://dessne.cosmology.illinois.edu/SNWG/web/display/examineCand.php?SNId=1098305', | |
'z=0.129', | |
'numepochs=17', | |
'numepochs_ml=0'), | |
('http://dessne.cosmology.illinois.edu/SNWG/web/display/examineCand.php?SNId=1052550', | |
'z=0.216', |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import cx_Oracle | |
username = 'your_username' | |
password = 'your_password' | |
dsn = 'leovip148.ncsa.uiuc.edu/destest' | |
db = cx_Oracle.connect(username, password, dsn) | |
cursor = db.cursor() | |
cursor.execute('begin fixSynonyms(\'\',\'SNY1REPROC\'); end;') # this points you to the right | |
# tablespace |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Query to find the subtractions with more than 5x the | |
# median number of detections per subtraction passing an ML cut of 0.5 | |
query = 'SELECT DISTINCT test.IMAGE_NAME_DIFF, SNOBS.nite, passing_det_count FROM '\ | |
'(SELECT IMAGE_NAME_DIFF, COUNT(CASE WHEN a.ml_score >= 0.5 THEN 1 END) passing_det_count '\ | |
'FROM SNOBS o JOIN SNAUTOSCAN a ON o.snobjid = a.snobjid '\ | |
'WHERE a.ml_version = 2 GROUP BY '\ | |
'IMAGE_NAME_DIFF) test JOIN SNOBS ON '\ | |
'test.IMAGE_NAME_DIFF = SNOBS.IMAGE_NAME_DIFF where passing_det_count >= 55' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import cx_Oracle | |
import pickle | |
import numpy as np | |
from itertools import chain | |
from PIL import Image, ImageDraw, ImageFont | |
from exceptions import IOError | |
import shutil | |
import os | |
NewerOlder