- satpy.multiscene._blend_funcs._combine_stacked_attrs(collected_attrs: Sequence[Mapping], combine_times: bool) dict
- satpy.multiscene._blend_funcs._fill_weights_for_invalid_dataset_pixels(datasets: Sequence[DataArray], weights: Sequence[DataArray]) Iterable[DataArray]
Replace weight valus with 0 where data values are invalid/null.
- satpy.multiscene._blend_funcs._get_combined_start_end_times(metadata_objects: Iterable[Mapping]) tuple[datetime | None, datetime | None]
Get the start and end times attributes valid for the entire dataset series.
- satpy.multiscene._blend_funcs._stack_blend_by_weights(datasets: Sequence[DataArray], weights: Sequence[DataArray], combine_times: bool) DataArray
Stack datasets blending overlap using weights.
- satpy.multiscene._blend_funcs._stack_no_weights(datasets: Sequence[DataArray], combine_times: bool) DataArray
- satpy.multiscene._blend_funcs._stack_select_by_weights(datasets: Sequence[DataArray], weights: Sequence[DataArray], combine_times: bool) DataArray
Stack datasets selecting pixels using weights.
- satpy.multiscene._blend_funcs._stack_with_weights(datasets: Sequence[DataArray], weights: Sequence[DataArray], combine_times: bool, blend_type: str) DataArray
- satpy.multiscene._blend_funcs.stack(data_arrays: Sequence[DataArray], weights: Sequence[DataArray] | None = None, combine_times: bool = True, blend_type: str = 'select_with_weights') DataArray
Combine a series of datasets in different ways.
By default, DataArrays are stacked on top of each other, so the last one applied is on top. Each DataArray is assumed to represent the same geographic region, meaning they have the same area. If a sequence of weights is provided then they must have the same shape as the area. Weights with greater than 2 dimensions are not currently supported.
When weights are provided, the DataArrays will be combined according to those weights. Data can be integer category products (ex. cloud type), single channels (ex. radiance), or a multi-band composite (ex. an RGB or RGBA true_color). In the latter case, the weight array is applied to each band (R, G, B, A) in the same way. The result will be a composite DataArray where each pixel is constructed in a way depending on
Blend type can be one of the following:
select_with_weights: The input pixel with the maximum weight is chosen.
blend_with_weights: The final pixel is a weighted average of all valid input pixels.
Expand dataset with and concatenate by time dimension.