Skip to content

Conversation

@jokasimr
Copy link
Contributor

@jokasimr jokasimr commented May 2, 2024

Previously masks were not applied in a correct way.
The old version had a bug that made it only work if there was only one mask per dimension.

Copy link
Member

@SimonHeybrock SimonHeybrock left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please edit the issue title so it is clear which function(s) are affected.

Comment on lines 214 to 216
combined_mask = zeros(dims=fda.data.dims, shape=fda.data.shape, dtype='bool')
for m in fda.masks.values():
fda = fda[~m]
combined_mask |= m
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could use

def irreducible_mask(da: DataArray, dim: Dims) -> Union[None, Variable]:
?

@jokasimr jokasimr changed the title fix: masks not applied correctly fix: masks not applied correctly in curve_fit May 2, 2024
@SimonHeybrock SimonHeybrock enabled auto-merge May 2, 2024 09:01
@SimonHeybrock SimonHeybrock merged commit e3b9b1b into main May 2, 2024
@SimonHeybrock SimonHeybrock deleted the fix-curve-fit-masking branch May 2, 2024 09:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants