Skip to content

Add outer method to BindingsArray #12437

Open
@chriseclectic

Description

@chriseclectic

What should we add?

Add a convenience method to compute the outer product of two bindings arrays. Eg

class BindingsArray:

    def outer(self, other: BindingsArray) -> BindingsArray:
         # validate self and other have distinct parameters
         # reshape arrays to append 1 dims to self and prepend 1 dims to ther
         # construct the data dict combining the two bas
    ... 

where ba_outer = ba1.outer(ba2) has ba_outer.shape = (*b1.shape, *ba2.shape).

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions