Skip to content

Commit

Permalink
Raise error when instatiating cost/kernel for a grid (#565)
Browse files Browse the repository at this point in the history
  • Loading branch information
michalk8 committed Jul 22, 2024
1 parent 2b866d3 commit 7dcc09c
Showing 1 changed file with 14 additions and 0 deletions.
14 changes: 14 additions & 0 deletions src/ott/geometry/grid.py
Original file line number Diff line number Diff line change
Expand Up @@ -325,6 +325,20 @@ def mask(
"""Not implemented."""
raise NotImplementedError("Masking is not implemented for grids.")

@property
def cost_matrix(self) -> jnp.ndarray:
"""Not implemented."""
raise NotImplementedError(
"Instantiating cost matrix is not implemented for grids."
)

@property
def kernel_matrix(self) -> jnp.ndarray:
"""Not implemented."""
raise NotImplementedError(
"Instantiating kernel matrix is not implemented for grids."
)

@classmethod
def prepare_divergences(
cls,
Expand Down

0 comments on commit 7dcc09c

Please sign in to comment.