【训练营】AI编译器 1.算子添加✅feat(operators): add 8 operators 2.功能开发❌ @simon_chou#22
Open
Simon-CHOU wants to merge 2 commits intobitzyz:mainfrom
Open
【训练营】AI编译器 1.算子添加✅feat(operators): add 8 operators 2.功能开发❌ @simon_chou#22Simon-CHOU wants to merge 2 commits intobitzyz:mainfrom
Simon-CHOU wants to merge 2 commits intobitzyz:mainfrom
Conversation
This commit adds complete full-stack implementations for: - Clip: tensor clipping operation - Conv: 2D convolution with InfiniCore kernel - LayerNorm: layer normalization with workspace support - LpNorm: Lp normalization with CPU fallback - RMSNorm: root mean square normalization - Softmax/LogSoftmax: softmax operations with transpose support - UnaryOps: Relu, Sigmoid, Tanh, Gelu, Silu Changes: - Add operator definitions (OperatorObj subclasses) - Add kernel implementations with InfiniCore integration - Add PyTorch FX frontend converters - Add comprehensive C++ and Python tests - Add CPU fallbacks for robustness - Add MOORE platform compatibility fixes Test Results: - C++ Unit Tests: 15/15 passed (100%) - Python Frontend Tests: 37/37 passed (100%) Related Issue: #grand-slam-target
Formatted Python files according to project style guidelines.
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.
PR Description
Summary
This PR adds complete full-stack implementations for 8 operators, achieving the "Grand Slam" target for the AI Compiler Winter Camp 2025 project.
Operators Added
operators/Clip.cc,kernels/Clip.ccoperators/Conv.cc,kernels/Conv.ccoperators/LayerNorm.cc,kernels/LayerNorm.ccoperators/LpNorm.cc,kernels/LpNorm.ccoperators/RMSNorm.cc,kernels/RMSNorm.ccoperators/Softmax.cc,kernels/Softmax.ccoperators/Softmax.cc,kernels/Softmax.ccoperators/Unary.cc,kernels/Unary.ccImplementation Details
Test Results by Platform
Note: Failures on MOORE/METAX/ILUVATAR platforms are due to missing operator support in their respective InfiniCore backends.
Known Limitations
SiluandLpNormoperators not supported by backendFiles Changed
Checklist