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

Merge Layer #194

Open
opfromthestart opened this issue Mar 1, 2023 · 0 comments
Open

Merge Layer #194

opfromthestart opened this issue Mar 1, 2023 · 0 comments

Comments

@opfromthestart
Copy link
Contributor

Is your feature request related to a particular use-case?

Say I have a model where I have a model with two linear layers and two inputs, but the second input should not be passed to the first layer but to the second layer. A Merge layer takes two specified inputs and merges them into one output.

Describe the solution you'd like to implement/see implemented

A MergeConfig would take two input ids, an output id, an axis to merge along, merging the first and second along the needed axis and placing the result in the output. This should allow a layer that only expects one input to get the output of two operations. It should only merge if the sizes on all other dimensions match. This is also useful for implementing recurrent networks explicitly.

Describe alternatives you've considered

Due to how LayerConfig works, modifications of the library are needed/more convenient for adding layers to a Solver, for example.

Additional context

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

No branches or pull requests

1 participant