Closed austinTalbot7241993 closed 2 months ago
The changes introduce a new file batch_adaptation.py
that implements domain adaptation techniques to correct for batch effects in data analysis. It features the BatchAdaptationUnivariate
class, which includes methods for fitting a model to data and transforming new datasets. Additionally, a testing module is added in test_batch_adaptation.py
to validate the functionality of the BatchAdaptationUnivariate
class through simulated datasets and unit tests.
Files | Change Summary |
---|---|
python/python/bystro/domain_adaptation/batch_adaptation.py |
Added batch_adaptation.py with sample_from_data_list function and BatchAdaptationUnivariate class, including methods for fitting and transforming data. |
python/python/bystro/domain_adaptation/tests/test_batch_adaptation.py |
Introduced testing module with simulate_data function and test_univariate_adaptation for validating BatchAdaptationUnivariate . |
In the land of data where rabbits play,
New tools for batches have come our way!
With means and variances, we hop and adjust,
Ensuring our results are fair and robust.
So let’s celebrate with a joyful cheer,
For clean data paths are finally here! 🐇✨
[!TIP]
Announcements
- The review status is no longer posted as a separate comment when there are no actionable or nitpick comments. In such cases, the review status is included in the walkthrough comment. - We have updated our review workflow to use the Anthropic's Claude family of models. Please share any feedback in the [discussion post](https://discordapp.com/channels/1134356397673414807/1279579842131787838) on our Discord. - Possibly related PRs: Walkthrough comment now includes a list of potentially related PRs to help you recall past context. Please share any feedback in the [discussion post](https://discordapp.com/channels/1134356397673414807/1282535539299323995) on our Discord. - Suggested labels: CodeRabbit can now suggest labels by learning from your past PRs in the walkthrough comment. You can also provide custom labeling instructions in the UI or configuration file. - Possibly related PRs, automatic label suggestions based on past PRs, learnings, and possibly related issues require data opt-in (enabled by default).
This PR implements a novel method for domain adaptation when a single control sample is included in each batch. This is the univariate version only.
Summary by CodeRabbit
New Features
BatchAdaptationUnivariate
class for adjusting data based on mean shifts caused by batch effects.Tests
BatchAdaptationUnivariate
class, including synthetic data generation and performance validation of the adaptation process.