Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Get SPE file location always from importlib resources absolute path #1312

Open
morcuended opened this issue Oct 25, 2024 · 0 comments
Open
Labels
enhancement New feature or request invalid This doesn't seem right

Comments

@morcuended
Copy link
Member

spe_location = (config['waveform_nsb_tuning']['spe_location']
if 'spe_location' in config['waveform_nsb_tuning']
and config['waveform_nsb_tuning']['spe_location']
is not None
else get_resource_path(
"data/SinglePhE_ResponseInPhE_expo2Gaus.dat"))

For the spe file, I would always use the get resource path here getting the path from importlib resources instead of trying first to search for the path in the config file.

It happens to me that the path in the lstchain config used for DL1 production was defined as "lstchain/data/SinglePhE_ResponseInPhE_expo2Gaus.dat" which does not define the absolute path, hence failing.

@morcuended morcuended added enhancement New feature or request invalid This doesn't seem right labels Nov 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request invalid This doesn't seem right
Projects
None yet
Development

No branches or pull requests

1 participant