Skip to content

Commit fe2f567

Browse files
chensuyueKaihui-inteln1ck-guoxin3heyiliu30
authored
Sync External Code (#9)
* Fix rtn tuning_device issue (#893) Signed-off-by: Kaihui-intel <kaihui.tang@intel.com> * fix vlm gguf ut (#895) Signed-off-by: n1ck-guo <heng.guo@intel.com> * update alg_ext.abi3.so with python compatible version (#894) * move ste from quant to round for nvfp4 (#889) Signed-off-by: He, Xin3 <xin3.he@intel.com> * Add GPT-OSS quant support (#887) * better help printing information (#883) * better help printing information Signed-off-by: n1ck-guo <heng.guo@intel.com> * speedup quant and evaluation, fix recompile issue (#897) * rewrite the implementation for ease-of-maintain Signed-off-by: He, Xin3 <xin3.he@intel.com> * fix bug Signed-off-by: He, Xin3 <xin3.he@intel.com> * fix quant performance Signed-off-by: He, Xin3 <xin3.he@intel.com> * Update auto_round/compressors/base.py --------- Signed-off-by: He, Xin3 <xin3.he@intel.com> * fix nvfp act quantization bug (#891) * fix nvfp act quantization bug Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * add cuda ut for moe nvfp quantize Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * add cpu UT, refine cuda UT Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * fix ut typo Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * fix cpu ut Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * enhance experts amax match, refine UT Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --------- Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * support automatic mixed bits assignment (#851) * try to fix gguf issue (#886) * remove numba from requirments (#905) Signed-off-by: yiliu30 <yi4.liu@intel.com> * Extend mxfp loading dtypes (#907) * block dataset logger info (#908) Signed-off-by: n1ck-guo <heng.guo@intel.com> * fix torch compile issue in AutoScheme (#909) * Revert "Extend mxfp loading dtypes (#907)" (#915) This reverts commit 0c2619c. * support disable_opt_rtn in auto-scheme (#913) * fix llama 4 ut (#896) * fix ut of llama 4 Signed-off-by: n1ck-guo <heng.guo@intel.com> * add numba for cpu lib (#919) Signed-off-by: yiliu30 <yi4.liu@intel.com> * Loosen the packing restrictions for mxfp&nvfp (#911) * Loosen the packing restrictions for mxfp&nvfp, enable Qwen1.5-MoE-A2.7B quantize Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * fix UT Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * refine mxfp&nvfp layer checker Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * fix pylint Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --------- Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Extend mxfp loading dtypes (#916) Signed-off-by: root <root@clx5673.ra.intel.com> Signed-off-by: yiliu30 <yi4.liu@intel.com> Co-authored-by: root <root@clx5673.ra.intel.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Fix act config exporting for mixed schemes (#903) * fp8 exporting bugfix Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * fix act related config saving Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * add ut for act_config check Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * refine extra_config saving, add UTs Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * fix ut typo Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * fix ut typo Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * fixtypo Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * fix CI Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * fix scan issue Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * fix scan issue Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * rm global variable Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * rerun ut Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * refine ut Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --------- Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * optimize rtn for int woq (#924) * fix bug of gguf and support for LiquidAI/LFM2-1.2B (#927) Signed-off-by: n1ck-guo <heng.guo@intel.com> * remove numpy<2.0 limitation (#921) * enable regex quantization config saving for mixed bits (#825) * enable dynamic quantization config saving Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * fixtypo Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * rebase code, refine config saving Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * refine ut Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * fix UT Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * enable hf loading for regex, add UTs Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * refine export, enhance gptq UT Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci --------- Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> * Fix Flux tuning issue (#936) Signed-off-by: Mengni Wang <mengni.wang@intel.com> * gguf support for inclusionAI/Ling-flash-2.0 (#940) * remove low_cpu_mem (#934) * Add compatibility test (#918) * Add commit hash to version (#941) Signed-off-by: Sun, Xuehao <xuehao.sun@intel.com> * gguf weight type align with original, output.weight, token_embed (#900) * support attention mask in user's dataset (#930) * Add diffusion README (#923) * update readme (#949) * refactor utils file (#943) * refact utils Signed-off-by: n1ck-guo <heng.guo@intel.com> * update readme for sglang support (#953) * update readme for sglang support Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * refine doc Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> * Update README.md --------- Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> Co-authored-by: Wenhua Cheng <wenhua.cheng@intel.com> * update gguf and support for CompressedLinear (#950) * Reduce AutoSchem VRAM usage by up to 10X (#944) * add self attribution and fix avg_bits error (#956) * add self attribution and fix avg_bits error --------- Signed-off-by: He, Xin3 <xin3.he@intel.com> Co-authored-by: Wenhua Cheng <wenhua.cheng@intel.com> * add logo (#960) * refine AutoScheme readme/code (#958) * update readme (#962) * fix critic disable_opt_rtn regression (#963) * [1/N] Initial vllm-ext evaluation support (MXFP4 MOE) (#935) Signed-off-by: yiliu30 <yi4.liu@intel.com> * fix bug of imatrix contains 0 (#955) * fix rtn bug (#966) * enhance flux doc (#967) * clean code (#968) * support for model scope (#957) * support for model scope Signed-off-by: n1ck-guo <heng.guo@intel.com> * merge main branch to alg_ext (#970) * fix cuda CI backend issue, fixtypo (#974) * disable compile packing by default (#975) Signed-off-by: yiliu30 <yi4.liu@intel.com> * enhance auto device map and support XPU (#961) * enhance auto device map and support XPU --------- Signed-off-by: He, Xin3 <xin3.he@intel.com> * refine readme (#978) * cli support for positional arguments model (#979) Signed-off-by: n1ck-guo <heng.guo@intel.com> * update bits (#986) Signed-off-by: He, Xin3 <xin3.he@intel.com> * fix guff scheme and device_map bug (#969) * add support for Magistral-Small (#980) * support model_dtype and fix bug of scheme contains quotes, mllm eval (#985) --------- Signed-off-by: Kaihui-intel <kaihui.tang@intel.com> Signed-off-by: n1ck-guo <heng.guo@intel.com> Signed-off-by: He, Xin3 <xin3.he@intel.com> Signed-off-by: Zhang, Weiwei1 <weiwei1.zhang@intel.com> Signed-off-by: yiliu30 <yi4.liu@intel.com> Signed-off-by: root <root@clx5673.ra.intel.com> Signed-off-by: Mengni Wang <mengni.wang@intel.com> Signed-off-by: Sun, Xuehao <xuehao.sun@intel.com> Co-authored-by: Tang Kaihui <kaihui.tang@intel.com> Co-authored-by: Heng Guo <heng.guo@intel.com> Co-authored-by: Xin He <xin3.he@intel.com> Co-authored-by: Yi Liu <yi4.liu@intel.com> Co-authored-by: Weiwei <weiwei1.zhang@intel.com> Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> Co-authored-by: Wenhua Cheng <wenhua.cheng@intel.com> Co-authored-by: root <root@clx5673.ra.intel.com> Co-authored-by: Wang, Mengni <mengni.wang@intel.com> Co-authored-by: Sun, Xuehao <xuehao.sun@intel.com>
1 parent 3243987 commit fe2f567

File tree

119 files changed

+13340
-8422
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

119 files changed

+13340
-8422
lines changed
Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
trigger: none
2+
3+
pr:
4+
autoCancel: true
5+
drafts: false
6+
branches:
7+
include:
8+
- main
9+
paths:
10+
include:
11+
- auto_round
12+
- auto_round_extension
13+
- setup.py
14+
- setup.cfg
15+
- requirements.txt
16+
- requirements-cpu.txt
17+
- .azure-pipelines/compatibility-test.yml
18+
exclude:
19+
- "*.md"
20+
- "**/*.md"
21+
22+
stages:
23+
- stage:
24+
displayName: Compatibility Test
25+
dependsOn: []
26+
jobs:
27+
- job:
28+
timeoutInMinutes: 20
29+
strategy:
30+
matrix:
31+
Python310_Linux:
32+
python_version: '3.10'
33+
vmImage: 'ubuntu-latest'
34+
Python311_Linux:
35+
python_version: '3.11'
36+
vmImage: 'ubuntu-latest'
37+
Python312_Linux:
38+
python_version: '3.12'
39+
vmImage: 'ubuntu-latest'
40+
Python313_Linux:
41+
python_version: '3.13'
42+
vmImage: 'ubuntu-latest'
43+
44+
Python310_Windows:
45+
python_version: '3.10'
46+
vmImage: 'windows-latest'
47+
Python311_Windows:
48+
python_version: '3.11'
49+
vmImage: 'windows-latest'
50+
Python312_Windows:
51+
python_version: '3.12'
52+
vmImage: 'windows-latest'
53+
Python313_Windows:
54+
python_version: '3.13'
55+
vmImage: 'windows-latest'
56+
57+
pool:
58+
vmImage: $(vmImage)
59+
60+
steps:
61+
- task: UsePythonVersion@0
62+
inputs:
63+
versionSpec: '$(python_version)'
64+
displayName: 'Use Python $(python_version)'
65+
66+
- script: |
67+
python -m pip install --upgrade pip uv
68+
uv pip install -r requirements.txt --extra-index-url https://download.pytorch.org/whl/cpu
69+
uv pip install .
70+
pip list
71+
env:
72+
PYTHONUNBUFFERED: '1'
73+
UV_NO_PROGRESS: '1'
74+
UV_SYSTEM_PYTHON: '1'
75+
displayName: 'Install dependencies'
76+
77+
- script: |
78+
python -c "import auto_round"
79+
displayName: 'Run compatibility test'

.azure-pipelines/scripts/ut/run_ut.sh

Lines changed: 12 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,12 +27,20 @@ mkdir -p ${LOG_DIR}
2727
ut_log_name=${LOG_DIR}/ut.log
2828

2929
# Split test files into 5 parts
30-
find . -name "test*.py" ! -name "*hpu_only*.py" | sort > all_tests.txt
30+
find . -name "test*.py" | sort > all_tests.txt
3131
total_lines=$(wc -l < all_tests.txt)
3232
NUM_CHUNKS=5
33-
chunk_size=$(( (total_lines + NUM_CHUNKS - 1) / NUM_CHUNKS ))
34-
start_line=$(( (test_part - 1) * chunk_size + 1 ))
35-
selected_files=$(tail -n +$start_line all_tests.txt | head -n $chunk_size)
33+
q=$(( total_lines / NUM_CHUNKS ))
34+
r=$(( total_lines % NUM_CHUNKS ))
35+
if [ "$test_part" -le "$r" ]; then
36+
chunk_size=$(( q + 1 ))
37+
start_line=$(( (test_part - 1) * chunk_size + 1 ))
38+
else
39+
chunk_size=$q
40+
start_line=$(( r * (q + 1) + (test_part - r - 1) * q + 1 ))
41+
fi
42+
end_line=$(( start_line + chunk_size - 1 ))
43+
selected_files=$(sed -n "${start_line},${end_line}p" all_tests.txt)
3644
printf '%s\n' "${selected_files}" | sed "s,\.\/,python -m pytest --cov=\"${auto_round_path}\" --cov-report term --html=report.html --self-contained-html --cov-report xml:coverage.xml --cov-append -vs --disable-warnings ,g" > run.sh
3745
cat run.sh
3846
bash run.sh 2>&1 | tee "${ut_log_name}"

.azure-pipelines/scripts/ut/run_ut_cuda.sh

Lines changed: 84 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,10 @@ CONDA_ENV_NAME="unittest_cuda"
55
PYTHON_VERSION="3.10"
66
REPO_PATH=$(git rev-parse --show-toplevel)
77
LOG_DIR=${REPO_PATH}/ut_log_dir
8+
SUMMARY_LOG=${LOG_DIR}/results_summary.log
9+
10+
rm -rf ${LOG_DIR} && mkdir -p ${LOG_DIR}
11+
touch ${SUMMARY_LOG}
812
[[ -z "$CUDA_VISIBLE_DEVICES" ]] && export CUDA_VISIBLE_DEVICES=0
913

1014
function create_conda_env() {
@@ -34,6 +38,55 @@ function create_conda_env() {
3438
uv pip install pytest-cov pytest-html cmake==4.0.2
3539
}
3640

41+
function print_test_results_table() {
42+
local log_pattern=$1
43+
local test_type=$2
44+
45+
echo ""
46+
echo "==========================================" >> ${SUMMARY_LOG}
47+
echo "Test Results Summary - ${test_type}" >> ${SUMMARY_LOG}
48+
echo "==========================================" >> ${SUMMARY_LOG}
49+
printf "%-30s %-10s %-50s\n" "Test Case" "Result" "Log File" >> ${SUMMARY_LOG}
50+
printf "%-30s %-10s %-50s\n" "----------" "------" "--------" >> ${SUMMARY_LOG}
51+
52+
local total_tests=0
53+
local passed_tests=0
54+
local failed_tests=0
55+
56+
for log_file in ${LOG_DIR}/${log_pattern}; do
57+
if [ -f "${log_file}" ]; then
58+
local test_name=$(basename "${log_file}" .log)
59+
# Remove prefix to get clean test case name
60+
test_name=${test_name#unittest_cuda_}
61+
test_name=${test_name#unittest_cuda_vlm_}
62+
63+
local result="UNKNOWN"
64+
local failure_count=$(grep -c '== FAILURES ==' "${log_file}" 2>/dev/null || echo 0)
65+
local error_count=$(grep -c '== ERRORS ==' "${log_file}" 2>/dev/null || echo 0)
66+
local passed_count=$(grep -c ' passed' "${log_file}" 2>/dev/null || echo 0)
67+
68+
if [ ${failure_count} -gt 0 ] || [ ${error_count} -gt 0 ]; then
69+
result="FAILED"
70+
failed_tests=$((failed_tests + 1))
71+
elif [ ${passed_count} -gt 0 ]; then
72+
result="PASSED"
73+
passed_tests=$((passed_tests + 1))
74+
else
75+
result="NO_TESTS"
76+
fi
77+
78+
total_tests=$((total_tests + 1))
79+
local log_filename=$(basename "${log_file}")
80+
printf "%-30s %-10s %-50s\n" "${test_name}" "${result}" "${log_filename}" >> ${SUMMARY_LOG}
81+
fi
82+
done
83+
84+
echo "==========================================" >> ${SUMMARY_LOG}
85+
printf "Total: %d, Passed: %d, Failed: %d\n" ${total_tests} ${passed_tests} ${failed_tests} >> ${SUMMARY_LOG}
86+
echo "==========================================" >> ${SUMMARY_LOG}
87+
echo "" >> ${SUMMARY_LOG}
88+
}
89+
3790
function run_unit_test() {
3891
# install unit test dependencies
3992
create_conda_env
@@ -49,24 +102,25 @@ function run_unit_test() {
49102
uv pip install -r requirements.txt
50103
uv pip install -r requirements_diffusion.txt
51104

52-
uv pip list
105+
pip list > ${LOG_DIR}/ut_pip_list.txt
53106
export COVERAGE_RCFILE=${REPO_PATH}/.azure-pipelines/scripts/ut/.coverage
54107
local auto_round_path=$(python -c 'import auto_round; print(auto_round.__path__[0])')
55-
56-
# setup test env
57-
mkdir -p ${LOG_DIR}
58-
local ut_log_name=${LOG_DIR}/unittest_cuda.log
59-
find . -name "test_*.py" | sed "s,\.\/,python -m pytest --cov=\"${auto_round_path}\" --cov-report term --html=report.html --self-contained-html --cov-report xml:coverage.xml --cov-append -vs --disable-warnings ,g" >run.sh
60-
cat run.sh
61-
62-
# run unit test
63-
bash run.sh 2>&1 | tee ${ut_log_name}
64-
65-
cp report.html ${LOG_DIR}/
66-
cp coverage.xml ${LOG_DIR}/
67-
68-
if [ $(grep -c '== FAILURES ==' ${ut_log_name}) != 0 ] || [ $(grep -c '== ERRORS ==' ${ut_log_name}) != 0 ] || [ $(grep -c ' passed' ${ut_log_name}) == 0 ]; then
69-
echo "Find errors in pytest case, please check the output..."
108+
109+
# run unit tests individually with separate logs
110+
for test_file in $(find . -name "test_*.py"); do
111+
local test_basename=$(basename ${test_file} .py)
112+
local ut_log_name=${LOG_DIR}/unittest_cuda_${test_basename}.log
113+
echo "Running ${test_file}..."
114+
115+
python -m pytest --cov="${auto_round_path}" --cov-report term --html=report.html --self-contained-html --cov-report xml:coverage.xml --cov-append -vs --disable-warnings ${test_file} 2>&1 | tee ${ut_log_name}
116+
done
117+
118+
mv report.html ${LOG_DIR}/
119+
mv coverage.xml ${LOG_DIR}/
120+
121+
# Print test results table and check for failures
122+
if ! print_test_results_table "unittest_cuda_test_*.log" "CUDA Unit Tests"; then
123+
echo "Some CUDA unit tests failed. Please check the individual log files for details."
70124
fi
71125
}
72126

@@ -85,30 +139,32 @@ function run_unit_test_vlm() {
85139
uv pip install flash-attn==2.7.4.post1 --no-build-isolation
86140
uv pip install -r requirements_vlm.txt
87141

88-
uv pip list
142+
pip list > ${LOG_DIR}/vlm_ut_pip_list.txt
89143
export COVERAGE_RCFILE=${REPO_PATH}/.azure-pipelines/scripts/ut/.coverage
90144
local auto_round_path=$(python -c 'import auto_round; print(auto_round.__path__[0])')
91145

92-
# setup test env
93-
mkdir -p ${LOG_DIR}
94-
local ut_log_name=${LOG_DIR}/unittest_cuda_vlm.log
95-
find . -name "test*vlms.py" | sed "s,\.\/,python -m pytest --cov=\"${auto_round_path}\" --cov-report term --html=report_vlms.html --self-contained-html --cov-report xml:coverage_vlms.xml --cov-append -vs --disable-warnings ,g" >run_vlms.sh
96-
cat run_vlms.sh
146+
# run VLM unit tests individually with separate logs
147+
for test_file in $(find . -name "test*vlms.py"); do
148+
local test_basename=$(basename ${test_file} .py)
149+
local ut_log_name=${LOG_DIR}/unittest_cuda_vlm_${test_basename}.log
150+
echo "Running ${test_file}..."
97151

98-
# run unit test
99-
bash run_vlms.sh 2>&1 | tee ${ut_log_name}
152+
python -m pytest --cov="${auto_round_path}" --cov-report term --html=report_vlms.html --self-contained-html --cov-report xml:coverage_vlms.xml --cov-append -vs --disable-warnings ${test_file} 2>&1 | tee ${ut_log_name}
153+
done
100154

101-
cp report_vlms.html ${LOG_DIR}/
102-
cp coverage_vlms.xml ${LOG_DIR}/
155+
mv report_vlms.html ${LOG_DIR}/
156+
mv coverage_vlms.xml ${LOG_DIR}/
103157

104-
if [ $(grep -c '== FAILURES ==' ${ut_log_name}) != 0 ] || [ $(grep -c '== ERRORS ==' ${ut_log_name}) != 0 ] || [ $(grep -c ' passed' ${ut_log_name}) == 0 ]; then
105-
echo "Find errors in pytest case, please check the output..."
158+
# Print test results table and check for failures
159+
if ! print_test_results_table "unittest_cuda_vlm_test*.log" "CUDA VLM Tests"; then
160+
echo "Some CUDA VLM tests failed. Please check the individual log files for details."
106161
fi
107162
}
108163

109164
function main() {
110165
run_unit_test_vlm
111166
run_unit_test
167+
cat ${SUMMARY_LOG}
112168
}
113169

114170
main

.azure-pipelines/template/ut-template.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ steps:
5555
displayName: "Run UT"
5656
5757
- task: PublishPipelineArtifact@1
58-
condition: succeededOrFailed()
58+
condition: succeeded()
5959
inputs:
6060
targetPath: ${{ parameters.uploadPath }}
6161
artifact: ${{ parameters.utArtifact }}_coverage

0 commit comments

Comments
 (0)