Skip to content

DA methods to perform barycentric mapping when input is close enough rather than exactly equal to source#529

Description

@kachayev

馃殌 Feature

Some DA transports provide a barycentric mapping "shortcut" when performing transformation of the input that is equal to the original set of source samples used for fitting. See BaseTransport (here) and MappingTransport (here) as examples.

The proposal is to use allclose instead of array_equal. In fact, it's already done this way for JCPOTTransport.

Motivation

Equality is a rather strong when working with floats. It seems like checking if two arrays are element-wise equal within a tolerance fits the use case. We could also make tolerance into optional parameter for the corresponding transport constructor.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions