3D conv heuristics (KTN part)#3918
Merged
Merged
Conversation
TODO: * check if metadata is correct. * Implement relevant cpp functions to load models and run them
…date kernel config
… the conv_hip_implicit_gemm_3d_grouped_wrw_xdlops solver
… (encoding + dropping constants)
* Forward declaration of EncodeKernelParams.
Removed some redundant code and unused vars to avoid most warnings during build (left unused var "arch" in for future use)
Author
|
Based on only reading the code and fixing any issues that came up when building MIOpen, we are ready for the next steps:
|
…e for easier reuse across other 3D conv solvers
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Proposed changes
This PR is focussed on introducing a new feature: A new model to perform heuristics for tuning the CK kernels used for 3D convolutions, initially only for gfx942:
These models are different from the current implementation of KTN:
It does not use an LSTM architecture, but instead relies on two TunaNet models:
input_encoder.tn.model: projects the input (conv parameters extracted from fdb_key) to latent spacekernel_config_encoder.tn.model: projects all possible kernel configurations (kernel parameters + split_k) for a particular fdb_key to the same latent space.the kernel configs are then scored through a dot product with the latent representaiton of the input, and the kernel_config with the highest score is selected
Checklist
Please put an
xinto the boxes that apply. You can also fill these out after creating the PR. If you're not sure, please don't hesitate to ask.make format&make check_formatto ensure the changes have been formatted