feat(op): Add Metax conv and softmax operators#1407
Open
rubik-hua wants to merge 1 commit into
Open
Conversation
Implement convolution and softmax operators for Metax backend. - Conv: Uses mcDNN library for standard paths plus custom MACA kernels for 2D direct conv and 3D patch embed optimizations. - Softmax: Implements custom kernel using warp/block reduction for high throughput. - Types: Supports FP16, BF16, and FP32 for both operators.
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.
Implement convolution and softmax operators for Metax backend.
沐曦上跑MiniCPM-V-2_6缺conv/softmax算子

补上算子后能正常跑,验证如下:
启动推理服务:python python/infinilm/server/inference_server.py --device metax --model=/mnt/geogpt-doc-new/default/rubik/MiniCPM-V-2_6/ --tp 4 --max-batch-size 256 --enable-paged-attn --attn flash-attn --enable-graph --log-level INFO
客户端直接用test_perf测试
python scripts/test_perf.py --image-dir=/mnt/geogpt-doc-new/default/rubik/images/cats_and_dogs/master/data_files/extracted/bc5712030f447cf9f432ea41ef6ea0ae14bb12e6fa549d38d259a7bc130d65ba/train/cat --verbose