File tree Expand file tree Collapse file tree 1 file changed +15
-1
lines changed
Expand file tree Collapse file tree 1 file changed +15
-1
lines changed Original file line number Diff line number Diff line change @@ -26,7 +26,21 @@ def setup_instrument_hardware():
2626 hardware = instrument .Hardware (config )
2727 make_radiance_maps .MakeRadianceMaps (config ).run ()
2828 filenames = glob (os .getenv ('suncet_data' ) + '/mhd/bright_fast/rendered_euv_maps/radiance_maps_200.fits' )
29- radiance_maps = sunpy .map .Map (filenames , sequence = True )
29+
30+ maps_by_index_and_wavelength = {}
31+ for filename in filenames :
32+ index = os .path .basename (filename ).split ('_' )[- 1 ].replace ('.fits' , '' )
33+ maps = sunpy .map .Map (filename )
34+
35+ if index not in maps_by_index_and_wavelength :
36+ maps_by_index_and_wavelength [index ] = {}
37+
38+ for map in maps :
39+ wavelength = str (map .wavelength )
40+ maps_by_index_and_wavelength [index ][wavelength ] = map
41+
42+ radiance_maps = maps_by_index_and_wavelength
43+
3044 hardware .store_target_wavelengths (radiance_maps )
3145 hardware .compute_effective_area ()
3246 return hardware
You can’t perform that action at this time.
0 commit comments