Skip to content

Benchmark use of np.where() versus boolean masking in Parcels kernels and interpolators #2197

@erikvansebille

Description

@erikvansebille

When starting to vectorise the particle loop in Parcels-v4, I chose to use/rely on np.where() statements as a replacement for if-statements. However it could be that boolean masking is much more efficient or cleaner. This could be explored in future benchmarking?

Originally posted by @VeckoTheGecko in #2152 (comment)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    Status

    Backlog

    Status

    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions