Comments (2)
Further information:
- this happens because the file is a La Palma-prod3b file containing also Flashcam
- using files such as this will crash also in the latest development version
- this bug is complementary to issue #23
from protopipe.
Update:
The cam_id_list key in the analysis.yml configuration file is used only to call the cam_ids for the estimators (one model per camera type). This means that it is completely useless in the rest of the code. Regarding --cam_ids, I am afraid that it is totally useless (I can't find it used anywhere in write_dl1.py).
What happens is that, when an ImageCleaner object is initialized, it checks which are the cameras listed in the image cleaning part of the configuration file. Since we never used Flashcam, the script will eventually crash if it doesn't find a camera that is in the simtel file.
Proposed solution:
There are a couple of nice built-in functions in ctapipe to manipulate subarrays, which have never been used probably because this part of protopipe was coded before.
For example, given a generic Paranal simtel file,
# Select all telescopes
In [22]: subarray
Out[22]: SubarrayDescription(name='MonteCarloArray', num_tels=567)
# Get the tel_ids of the LST subarray
In [15]: subarray.get_tel_ids_for_type("LST_LST_LSTCam")
Out[15]: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]
# Build a custom array
In [25]: custom_array = subarray.select_subarray("custom_array", [1, 35, 90])
# Get only the cameras really involved
In [26]: [camera.cam_id for camera in custom_array.camera_types]
Out[26]: ['FlashCam', 'NectarCam', 'LSTCam']
Given PR #29 we can:
- implement the tools above in
protopipe.pipeline.utils
, thus making the cam_id_list key in the config file obsolete and give the list of cameras also to ImageCleaner so only the necessary objects get initialized, - retain the camera radius part, which is necessary for the moment,
- add the missing cameras to the image cleaning section of analysis.yaml (removing the dl1_test.yaml), giving them dummy values
This should make all cases runnable, but we continue to work only on LSTCam + NectarCam for the moment. If any new developer wants to test other cameras will be more than welcomed by updated documentation (see issues #23, #27).
from protopipe.
Related Issues (20)
- Add image extraction status
- Add tables attributes
- Merge DIRAC grid interface
- Containerization
- How to handle performance showcasing in the future HOT 1
- Refactoring of the TRAINING stage HOT 3
- Add analysis book template
- [BUG] Notebooks should try to import uproot only if ROOT-based data is required
- Add a benchmarking notebook template
- Should not transform the Geometry for each event (slow) HOT 1
- Number of recorded SST telescopes is miscalculated or missing
- Remove dangerous fall-back to MARS cuts if there is a typo in the config file HOT 2
- Some broken benchmarks HOT 1
- Update integration test pipeline with (diffuse) Prod5b data from CTAN and CTAS
- Native parallelization
- Make conda package
- PyPI upload doesn't work anymore HOT 2
- Dropdown menu to switch between docs versions doesn't work HOT 2
- Automate documentation of CLI scripts
- Should we archive this repository? HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from protopipe.