openclimatefix / openclimatefix/ocf-data-sampler

Update and scale up / refactor for tests/torch_datasets/test_sample/

Open
#259 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

ocf-internal
Dominant language
Python
Stars
20
Forks
43
PR merge metrics
No merged PRs in 30d

Description

For example within test_uk_regional_sample.py:

  • Move numpy_sample and pvnet_configuration_object to conftest.py
  • Modify pvnet_configuration_object fixture to load settings from designated yaml
  • Parametrise validation tests: Consolidate those for missing / invalid data

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with tests/torch_datasets/test_sample/test_uk_regional_sample.py and inspect its existing fixtures and validation tests. Move numpy_sample and pvnet_configuration_object to conftest.py, make the latter load the designated YAML settings, and consolidate parametrized checks for missing or invalid data. Run the tests under tests/torch_datasets/test_sample/ to verify the refactor.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
testing
Issue type
Refactor
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.