Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add's getOutputShape (and possibly others) fails when supplied with two of the same input with shape placeholders #66

Open
kostaleonard opened this issue Jan 28, 2023 · 0 comments
Assignees
Labels
bug Something isn't working

Comments

@kostaleonard
Copy link
Owner

As a machine learning engineer, I want DifferentiableFunction's getOutputShape to succeed when the shape can reasonably be resolved with placeholder dimensions so that I can write complex functions.

Add's getOutputShape (and possibly others) fails in the following case where two of the same Inputs are supplied as arguments. Normally, we wouldn't be able to resolve the output shape, but because it's the same input both times, we should reasonably be able to determine the output shape.

  it should "return its output shape with placeholder dimensions in the same input" in {
    val input = Input[Float]("X", Array(None))
    val addition = Add(input, input)
    val shape = addition.getOutputShape
    assert(shape.isSuccess)
    assert(shape.get sameElements Array(None))
  }
@kostaleonard kostaleonard added the bug Something isn't working label Jan 28, 2023
@kostaleonard kostaleonard added this to the Second release milestone Jan 28, 2023
@kostaleonard kostaleonard self-assigned this Jan 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant