import pyfits as pf import scipy.signal as SG from scipy.spatial import KDTree from numpy.polynomial.chebyshev import chebfit, chebval from scipy.interpolate import interp1d import SEDMr.Extraction as Extraction import SEDMr.Wavelength as Wavelength import SEDMr.Spectra as SS import sys sys.setrecursionlimit(10000) # reference wavelength for X positions fid_wave = Wavelength.fiducial_wavelength() scale = 1.0 H2P = np.array([[np.sqrt(3), np.sqrt(3)/2], [0, 3/2.]]) * scale P2H = np.array([[np.sqrt(3)/3, -1/3.], [0, 2/3.]]) / scale # Rotation matrix theta = np.deg2rad(-37+13.5) ROT = np.array([[np.cos(theta), -np.sin(theta)], [np.sin(theta), np.cos(theta)]]) ''' See figures here: