Create noise from wl_bins input parameter
This commit is contained in:
parent
2029d5230c
commit
db13f0b073
@ -21,7 +21,7 @@ class TestAHotOpticalComponent(TestCase):
|
||||
wl = np.arange(201, 205, 1) << u.nm
|
||||
|
||||
def setUp(self):
|
||||
self.target = FileTarget("data/target/target_demo_1.csv")
|
||||
self.target = FileTarget("data/target/target_demo_1.csv", self.wl)
|
||||
|
||||
def test___init__(self):
|
||||
comp = HotOpticalComponent(self.target, SpectralQty(self.wl, np.repeat(0.5, 4) << u.dimensionless_unscaled),
|
||||
|
@ -6,7 +6,7 @@ import astropy.units as u
|
||||
|
||||
class TestAtmosphere(TestCase):
|
||||
def setUp(self):
|
||||
self.target = FileTarget("data/target/target_demo_1.csv")
|
||||
self.target = FileTarget("data/target/target_demo_1.csv", np.arange(200, 208) << u.nm)
|
||||
self.atmosphere = Atmosphere(self.target, "data/atmosphere/atmosphere_transmittance_1.csv",
|
||||
"data/atmosphere/atmosphere_emission_1.csv")
|
||||
|
||||
|
@ -10,7 +10,7 @@ class TestBeamSplitter(TestCase):
|
||||
wl = np.arange(201, 205, 1) << u.nm
|
||||
|
||||
def setUp(self):
|
||||
self.target = FileTarget("data/target/target_demo_1.csv")
|
||||
self.target = FileTarget("data/target/target_demo_1.csv", self.wl)
|
||||
self.splitter = BeamSplitter(self.target, "data/beamsplitter/beamsplitter_transmittance.csv", 0.5,
|
||||
temp=300 * u.K)
|
||||
|
||||
|
@ -13,7 +13,7 @@ class TestFilter(TestCase):
|
||||
0.0, 0.0] << u.W / (u.m ** 2 * u.nm)))
|
||||
|
||||
def test_fromFile(self):
|
||||
target = FileTarget("data/target/target_demo_1.csv")
|
||||
target = FileTarget("data/target/target_demo_1.csv", np.arange(200, 210, 1) << u.nm)
|
||||
filt = Filter.fromFile(target, "data/filter/filter_transmittance.csv")
|
||||
self.assertEqual(filt.calcSignal(), SpectralQty(np.arange(200, 210, 1) << u.nm,
|
||||
[1.10e-15, 1.20e-15, 1.30e-15, 1.40e-15, 1.35e-15, 1.44e-15,
|
||||
|
@ -10,7 +10,7 @@ class TestLens(TestCase):
|
||||
wl = np.arange(201, 205, 1) << u.nm
|
||||
|
||||
def setUp(self):
|
||||
self.target = FileTarget("data/target/target_demo_1.csv")
|
||||
self.target = FileTarget("data/target/target_demo_1.csv", self.wl)
|
||||
self.lens = Lens(self.target, "data/lens/lens_transmittance.csv", 0.5, temp=300 * u.K)
|
||||
|
||||
def test___init__(self):
|
||||
|
@ -10,7 +10,7 @@ class TestMirror(TestCase):
|
||||
wl = np.arange(201, 205, 1) << u.nm
|
||||
|
||||
def setUp(self):
|
||||
self.target = FileTarget("data/target/target_demo_1.csv")
|
||||
self.target = FileTarget("data/target/target_demo_1.csv", self.wl)
|
||||
self.mirror = Mirror(self.target, "data/mirror/mirror_reflectance.csv", 0.5, temp=300 * u.K)
|
||||
|
||||
def test___init__(self):
|
||||
|
@ -6,7 +6,7 @@ import astropy.units as u
|
||||
|
||||
class TestStrayLight(TestCase):
|
||||
def setUp(self):
|
||||
self.target = FileTarget("data/target/target_demo_1.csv")
|
||||
self.target = FileTarget("data/target/target_demo_1.csv", np.arange(200, 210) << u.nm)
|
||||
self.zodiac = StrayLight(self.target, "data/straylight/zodiacal_emission_1.csv")
|
||||
|
||||
def test_calcSignal(self):
|
||||
|
Loading…
x
Reference in New Issue
Block a user