Skip to content

How to average over different/multiple axes of weights matrix? #2402

Answered by szaman19
jvwilliams23 asked this question in Q&A
Discussion options

You must be logged in to vote

We're working on expanding the Reduction layer but in the meantime, this is the hack I have to do reductions on 3/4D inputs using grouped convolutions with frozen constant weights.

weights = lbann.Weights(initializer=lbann.ConstantInitializer(value=1, optimizer=lbann.NoOptimizer()))
reduction_kernel = lbann.ConvolutionModule(
                                  weights=weights,
                                  num_dims=3, 
                                  kernel=[512, 3 , 3],
                                  groups=512,
                                  output_channels=512,
                                  stride=1,
                                  padding=0,
                          …

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@jvwilliams23
Comment options

jvwilliams23 Dec 13, 2023
Collaborator Author

@szaman19
Comment options

@jvwilliams23
Comment options

jvwilliams23 Dec 22, 2023
Collaborator Author

@jvwilliams23
Comment options

jvwilliams23 Jan 8, 2024
Collaborator Author

Answer selected by jvwilliams23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants