Refactor visualization of flasher events to a more generic module.#2023
Open
GernotMaier wants to merge 16 commits intomainfrom
Open
Refactor visualization of flasher events to a more generic module.#2023GernotMaier wants to merge 16 commits intomainfrom
GernotMaier wants to merge 16 commits intomainfrom
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR refactors the visualization of flasher events into a more generic module, removing the ctapipe dependency and introducing new trace analysis functionality. The refactoring moves from function-based plotting to a class-based approach (PlotSimtelEvent) and introduces new modules for event reading and trace analysis.
Changes:
- Removed ctapipe dependency, introducing custom event reader (
simtel_event_reader.py) and trace analysis (trace_analysis.py) - Refactored
plot_simtel_events.pyfrom function-based to class-based architecture - Renamed Camera parameter from
telescope_model_nametotelescope_namefor consistency - Added new camera plotting utilities (
plot_pixel_layout_with_image) for displaying per-pixel values - Updated tests with comprehensive coverage for new modules
Reviewed changes
Copilot reviewed 20 out of 20 changed files in this pull request and generated 11 comments.
Show a summary per file
| File | Description |
|---|---|
| src/simtools/simtel/simtel_event_reader.py | New event reader to replace ctapipe EventSource |
| src/simtools/camera/trace_analysis.py | New trace analysis functions (pedestals, integration, peak finding) |
| src/simtools/visualization/plot_simtel_events.py | Complete rewrite with PlotSimtelEvent class |
| src/simtools/visualization/plot_camera.py | Added plot_pixel_layout_with_image and helper functions |
| src/simtools/model/camera.py | Added read_pixel_list_from_dict for eventio integration |
| src/simtools/applications/plot_simtel_events.py | Updated CLI to use telescope parameter |
| pyproject.toml, environment.yml | Removed ctapipe dependency |
| tests/unit_tests/visualization/test_plot_simtel_events.py | Complete test rewrite |
| tests/unit_tests/visualization/test_plot_camera.py | New comprehensive test file |
| tests/unit_tests/simtel/test_simtel_event_reader.py | New test file |
| tests/unit_tests/camera/test_trace_analysis.py | New test file |
| tests/unit_tests/model/test_camera.py | Expanded tests for new functionality |
tests/unit_tests/production_configuration/test_generate_production_grid.py
Show resolved
Hide resolved
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.




Relatively large refactoring - also preparation for additional functionality for long integration tests:
The test file for flasher events has outdated metadata - these are the two
TODOs in the code.