osc.data.utils.wrap_with_seed
- wrap_with_seed(augment_fn, *, initial_seed=0)[source]
Wrap stateless random functions by providing a new seed to each invocation.
- Parameters
augment_fn (
AugmentFnStateless
) – callable, augment_fn(img, seed)initial_seed (
int
) – initial seed for the generator.
- Return type
Callable
[[Tensor
],Tensor
]- Returns
Callable that wraps
augment_fn
.