Nm Training Placeholder
Placeholder code snippets for noise model training integration.
This module contains template/placeholder code that demonstrates how noise model training could be integrated into CAREamist. These are reference implementations and should not be imported or used directly.
train_noise_model(self, clean_data, noisy_data, learning_rate=0.1, batch_size=250000, n_epochs=2000, lower_clip=0.0, upper_clip=100.0, save_noise_models=True)
Train noise models from clean/noisy data pairs.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
self
|
object
|
CAREamist instance. |
required |
clean_data
|
Union[Path, str, NDArray]
|
Clean (signal) data for training noise models. |
required |
noisy_data
|
Union[Path, str, NDArray]
|
Noisy (observation) data for training noise models. |
required |
learning_rate
|
float
|
Learning rate for noise model training. |
1e-1
|
batch_size
|
int
|
Batch size for noise model training. |
250000
|
n_epochs
|
int
|
Number of epochs for noise model training. |
2000
|
lower_clip
|
float
|
Lower percentile for clipping training data. |
0.0
|
upper_clip
|
float
|
Upper percentile for clipping training data. |
100.0
|
save_noise_models
|
bool
|
Whether to save trained noise models to disk. |
True
|
Raises:
| Type | Description |
|---|---|
ValueError
|
If noise models are not initialized for training. |
ValueError
|
If data shapes don't match expectations. |