Implement BatchnormBwd functionality into hip-kernel-provider#5558
Draft
BalintCsala wants to merge 11 commits intoROCm:developfrom
Draft
Implement BatchnormBwd functionality into hip-kernel-provider#5558BalintCsala wants to merge 11 commits intoROCm:developfrom
BalintCsala wants to merge 11 commits intoROCm:developfrom
Conversation
…lementing batchnorm forward training functionality The code builds and runs, but the results are incorrect.
…ild parameters were not being passed
… for fused batchnorm forward training & added related tests
…indTensorAttributes for better exception handling
…aunching batchnorm fwd train spatial variant 2 kernel
…ests based on latest format
Its inclusion doesn't seem to be necessary for the functionality provided by StaticUnroll.hpp
…IPlan & IPlanBuilder in hipDNN
…tection utils function
…iles related to batchnorm forward training functionality
Add backward batchnorm operations (miopenBatchNormalizationBackward_V2) and fused backward+activation (miopenBatchNormBackwardActivation) support to the hip-kernel-provider plugin. New files: - BatchnormBwdPlan.hpp/cpp: Plan implementation for backward batchnorm with spatial (single and multi-kernel) and per-activation modes - BatchNormBwdSpatial.cpp: Spatial backward HIP kernel - BatchNormBwdSpatialMultiple.cpp: Multi-pass spatial backward HIP kernel - BatchNormBwdPerAct.cpp: Per-activation backward HIP kernel - BatchnormStash.hpp: Stash utilities for multi-kernel approach Modified files: - BatchnormPlanBuilder.cpp: Route backward graphs (1-node and 3-node fused BnInference+Pointwise+BnBackward) to backward plan - BatchnormApplicabilityChecks.hpp/cpp: Add backward tensor config and activation mode validation - HipKernelUtils.hpp/cpp: Add findDeviceBuffer declaration and correct parseActivation implementation with full activation mode support Tests: - Integration tests for backward and backward+activation operations across NCHW/NHWC/NCDHW/NDHWC layouts with fp32/fp16/bfloat16 - Unit tests for BatchnormBwdParams initialization
e63e7ab to
37e23ba
Compare
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.
Caution
Must be merged after #4885
Motivation
This PR moves the BatchnormBwd implementation of MIOpen into the hip-kernel-provider hipDNN plugin.
Technical Details
Test Plan
Testing done through included unit and integration tests.
Test Result
Tests passed on gfx90a
Submission Checklist