cta-observatory / cta-lstchain

LST prototype testbench chain
https://cta-observatory.github.io/cta-lstchain/
BSD 3-Clause "New" or "Revised" License
26 stars 77 forks source link

Fail to read simulation header data in DL1/DL2 data processed with lstchain v0.9 #1141

Closed SeiyaNozaki closed 5 months ago

SeiyaNozaki commented 1 year ago

Apart from the difference of n_showers and num_showers in SimulationConfigContainer, I didn't manage to read simulation header data in DL1/DL2 processed by lstchain v0.9. If I want to use lstchain v0.10, would it be better to ask lstmcpipe team for new MC DL1/DL2 production with lstchain v0.10 as well (I know it is the best though)? or do we have a quick trick to solve this...?

>>> from lstchain.io.io import read_simu_info_hdf5
>>> filename = "/fefs/aswg/data/mc/DL1/AllSky/20221215_v0.9.12_base_prod/TestingDataset/dl1_20221215_v0.9.12_base_prod_node_theta_10.0_az_102.199__merged.h5"
>>> simu_info = read_simu_info_hdf5(filename)
Table /simulation/run_config is missing column None for field corsika_version of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field simtel_version of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field energy_range_min of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field energy_range_max of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field prod_site_B_total of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field prod_site_B_declination of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field prod_site_B_inclination of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field prod_site_alt of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field spectral_index of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field shower_prog_start of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field shower_prog_id of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field detector_prog_start of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field detector_prog_id of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field n_showers of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field shower_reuse of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field max_alt of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field min_alt of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field max_az of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field min_az of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field diffuse of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field max_viewcone_radius of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field min_viewcone_radius of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field max_scatter_range of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field min_scatter_range of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field core_pos_mode of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field injection_height of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field atmosphere of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field corsika_iact_options of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field corsika_low_E_model of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field corsika_high_E_model of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field corsika_bunchsize of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field corsika_wlen_min of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field corsika_wlen_max of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field corsika_low_E_detail of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
Table /simulation/run_config is missing column None for field corsika_high_E_detail of container <class 'ctapipe.containers.SimulationConfigContainer'>. It will be skipped.
vuillaut commented 1 year ago

Hi Seiya,

Depends what you want to do but I think you could do something in the line of :

from astropy.tables import Table
Table.read(filename, 'simulation/run_config')