Skip to content

Conversation

@sahiljhawar
Copy link
Collaborator

resolves #12

@sahiljhawar sahiljhawar marked this pull request as ready for review October 2, 2025 10:47
@sahiljhawar sahiljhawar requested a review from Copilot October 2, 2025 10:50
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds the read_with_horizon method to ensemble classes for reading forecast data at specific forecast horizons. The method enables filtering ensemble data based on the lead time from forecast creation to target time.

  • Adds read_with_horizon method to Kp and Hp ensemble classes for horizon-based data reading
  • Refactors file listing logic into separate helper methods for better code organization
  • Updates test suites with comprehensive coverage for the new horizon functionality

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.

Show a summary per file
File Description
swvo/io/kp/ensemble.py Implements read_with_horizon method and refactors file listing into ensemble_file_list helper
swvo/io/hp/ensemble.py Adds abstract read_with_horizon method to base class and concrete implementations for Hp30/Hp60
tests/io/kp/test_kp_ensemble.py Adds comprehensive test cases for Kp ensemble horizon functionality
tests/io/hp/test_hp_ensemble.py Adds test coverage for Hp ensemble horizon methods with validation and error cases
tests/io/dst/test_wdc.py Updates test date to avoid potential data availability issues

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@sahiljhawar sahiljhawar merged commit 012b9fe into GFZ:main Oct 2, 2025
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

add function to read Kp at different KpML horizon

1 participant