compute_MVBS#
- echopype.commongrid.compute_MVBS(ds_Sv: Dataset, range_var: Literal['echo_range', 'depth'] = 'echo_range', range_bin: str = '20m', ping_time_bin: str = '20s', method: str = 'map-reduce', reindex: bool = False, skipna: bool = True, fill_value: float = nan, closed: Literal['left', 'right'] = 'left', range_var_max: str = None, **flox_kwargs)#
Compute Mean Volume Backscattering Strength (MVBS) based on intervals of range (
echo_range) or depth (depth) andping_timespecified in physical units.Output of this function differs from that of
compute_MVBS_index_binning, which computes bin-averaged Sv according to intervals ofecho_rangeandping_timespecified as index number.- Parameters:
- ds_Svxr.Dataset
dataset containing Sv and
echo_range[m]- range_var: {‘echo_range’, ‘depth’}, default ‘echo_range’
The variable to use for range binning. Must be one of
echo_rangeordepth. Note thatdepthis only available if the input dataset containsdepthas a data variable.- range_binstr, default ‘20m’
bin size along
echo_rangeordepthin meters.- ping_time_binstr, default ’20s’
bin size along
ping_time- method: str, default ‘map-reduce’
The flox strategy for reduction of dask arrays only. See flox documentation for more details.
- reindex: bool, default False
If False, reindex after the blockwise stage. If True, reindex at the blockwise stage. Generally, reindex=False results in less memory at the cost of computation speed. Can only be used when method=’map-reduce’. See flox documentation for more details.
- skipna: bool, default True
If true, the mean operation skips NaN values. Else, the mean operation includes NaN values.
- fill_value: float, default np.nan
Fill value when no group data exists to aggregate.
- closed: {‘left’, ‘right’}, default ‘left’
Which side of bin interval is closed.
- range_var_max: str, default None
Range variable maximum. Can be true range variable maximum or the maximum depth the user wishes to regrid to. If known, users can pass in range variable maximum to ensure that compute_MVBS can lazily run without any computation.
- **flox_kwargs
Additional keyword arguments to be passed to flox reduction function.
- Returns:
- A dataset containing bin-averaged Sv