result_bool = [(np.isclose(imlist[i].image_rms, value_compare[i], rtol=rtol, atol=atol, equal_nan=False), os.path.basename(imlist[i].image)) for i in [0,1]]
import os
import time
import datetime
import regression_utility as regutl
import sys, traceback
import numpy as np
import pipeline
pathname = os.environ.get('CASAPATH').split()[0]
rootdatapath = pathname+'/data/regression/pipeline/vla/'
'''Initial VLA pipeline regression
B. Kent, May 2015
Update September 1, 2015
Update April 20, 2018
Update June 01, 2018
Update Feb 22, 2019 Added imaging statistics
Update March 18, 2019 Switched to new data directory
'''
THISHOME = "working/"
startTime=0.0
endTime=0.0
startProc=0.0
endProc=0.0
regstate = True
def printmsg(logfile, msg):
print >>logfile, msg
print(msg)
return
def load_context(filename):
with open(filename, 'rb') as picklefile:
return pipeline.infrastructure.utils.pickle_load(picklefile)
EPS = 1e-5
def pipeline_regression():
global regstate
ASDM = rootdatapath + "13A-537.sb24066356.eb24324502.56514.05971091435"
try:
import pipeline.recipes.hifv as hifv
except ImportError, e:
print(e)
if not os.path.exists(ASDM):
print("Unable to open ASDM ", ASDM)
regstate=False
raise IOError
else:
print("Using ", ASDM)
try:
hifv.hifv([ASDM], importonly=False)
except Exception as e:
print(e)
regstage=False
def run():
'''Timing and running of main regression function
'''
global startTime, endTime, startProc, endProc, regstate;
startTime = time.time()