Skip to content

Commit 2b4c824

Browse files
authored
Update CI framework versions and README badge for release 3.1.1 (#2058)
Signed-off-by: Sun, Xuehao <xuehao.sun@intel.com>
1 parent 64c2f34 commit 2b4c824

13 files changed

+35
-11
lines changed

.azure-pipelines/scripts/fwk_version.sh

+2-2
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,6 @@ export tensorflow_version='2.15.0-official'
55
export pytorch_version='2.5.1+cpu'
66
export torchvision_version='0.20.1'
77
export ipex_version='2.5.0+cpu'
8-
export onnx_version='1.16.0'
9-
export onnxruntime_version='1.18.0'
8+
export onnx_version='1.17.0'
9+
export onnxruntime_version='1.20.0'
1010
export mxnet_version='1.9.1'

.azure-pipelines/scripts/install_nc.sh

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
#!/bin/bash
22

3-
echo -e "\n Install Neural Compressor ... "
3+
echo -e "##[group]Install Neural Compressor ... "
44
cd /neural-compressor
55
if [[ $1 = *"3x_pt"* ]]; then
66
python -m pip install --no-cache-dir -r requirements_pt.txt
@@ -27,4 +27,5 @@ else
2727
fi
2828

2929
echo -e "\n pip list after install Neural Compressor ... "
30+
echo "##[endgroup]"
3031
pip list

.azure-pipelines/scripts/ut/3x/run_3x_pt.sh

+2-1
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,12 @@ test_case="run 3x Torch"
44
echo "${test_case}"
55

66
# install requirements
7-
echo "set up UT env..."
7+
echo "##[group]set up UT env..."
88
export LD_LIBRARY_PATH=/usr/local/lib/:$LD_LIBRARY_PATH
99
pip install -r /neural-compressor/test/3x/torch/requirements.txt
1010
pip install pytest-cov
1111
pip install pytest-html
12+
echo "##[endgroup]"
1213
pip list
1314

1415
export COVERAGE_RCFILE=/neural-compressor/.azure-pipelines/scripts/ut/3x/coverage.3x_pt

.azure-pipelines/scripts/ut/3x/run_3x_pt_fp8.sh

+2-1
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ test_case="run 3x Torch Habana FP8"
44
echo "${test_case}"
55

66
# install requirements
7-
echo "set up UT env..."
7+
echo "##[group]set up UT env..."
88
export LD_LIBRARY_PATH=/usr/local/lib/:$LD_LIBRARY_PATH
99
sed -i '/^intel_extension_for_pytorch/d' /neural-compressor/test/3x/torch/requirements.txt
1010
sed -i '/^auto_round/d' /neural-compressor/test/3x/torch/requirements.txt
@@ -13,6 +13,7 @@ pip install -r /neural-compressor/test/3x/torch/requirements.txt
1313
pip install pytest-cov
1414
pip install pytest-html
1515
pip install pytest-html-merger
16+
echo "##[endgroup]"
1617
pip list
1718

1819
export COVERAGE_RCFILE=/neural-compressor/.azure-pipelines/scripts/ut/3x/coverage.3x_pt_fp8

.azure-pipelines/scripts/ut/3x/run_3x_tf.sh

+2-1
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,12 @@ test_case="run 3x TensorFlow"
44
echo "${test_case}"
55

66
# install requirements
7-
echo "set up UT env..."
7+
echo "##[group]set up UT env..."
88
pip install -r /neural-compressor/test/3x/tensorflow/requirements.txt
99
pip install pytest-cov
1010
pip install pytest-html
1111
pip install pytest-html-merger
12+
echo "##[endgroup]"
1213
pip list
1314

1415
export COVERAGE_RCFILE=/neural-compressor/.azure-pipelines/scripts/ut/3x/coverage.3x_tf

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

+4-2
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ coverage_log_base="/neural-compressor/log_dir/coverage_log_base"
77
coverage_compare="/neural-compressor/log_dir/coverage_compare.html"
88
cd /neural-compressor/log_dir
99

10-
$BOLD_YELLOW && echo "collect coverage for PR branch" && $RESET
10+
$BOLD_YELLOW && echo "##[group]collect coverage for PR branch" && $RESET
1111
mkdir -p coverage_PR
1212
cp ut_*_coverage/.coverage.* ./coverage_PR/
1313

@@ -28,8 +28,9 @@ git checkout master
2828
rm -rf build dist *egg-info
2929
echo y | pip uninstall neural-compressor
3030
cd /neural-compressor/.azure-pipelines-pr/scripts && bash install_nc.sh
31+
echo "##[endgroup]"
3132

32-
$BOLD_YELLOW && echo "collect coverage for baseline" && $RESET
33+
$BOLD_YELLOW && echo "##[group]collect coverage for baseline" && $RESET
3334
coverage erase
3435
cd /neural-compressor/log_dir
3536
mkdir -p coverage_base
@@ -43,6 +44,7 @@ coverage report -m --rcfile=${COVERAGE_RCFILE} | tee ${coverage_log_base}
4344
coverage html -d log_dir/coverage_base/htmlcov --rcfile=${COVERAGE_RCFILE}
4445
coverage xml -o log_dir/coverage_base/coverage.xml --rcfile=${COVERAGE_RCFILE}
4546
ls -l log_dir/coverage_base/htmlcov
47+
echo "##[endgroup]"
4648

4749
get_coverage_data() {
4850
# Input argument

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

+3-2
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ echo "onnxruntime version is $onnxruntime_version"
1919
echo "mxnet version is $mxnet_version"
2020

2121
test_case=$1
22-
echo "========= test case is ${test_case}"
22+
echo -e "##[group]test case is ${test_case}"
2323

2424
if [[ "${tensorflow_version}" == *"-official" ]]; then
2525
pip install tensorflow==${tensorflow_version%-official}
@@ -100,6 +100,8 @@ pip install coverage
100100
pip install pytest
101101
pip install pytest-html
102102

103+
echo "##[endgroup]"
104+
103105
pip list
104106
echo "[DEBUG] list pipdeptree..."
105107
pip install pipdeptree
@@ -112,4 +114,3 @@ if [[ $(echo "${test_case}" | grep -c "run basic api") != 0 ]] || [[ $(echo "${t
112114
find . -name "test*.py" | xargs sed -i 's/import tensorflow.compat.v1 as tf/import torch; import tensorflow.compat.v1 as tf/g'
113115
find . -name "test*.py" | xargs sed -i 's/from tensorflow import keras/import torch; from tensorflow import keras/g'
114116
fi
115-

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

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ source /neural-compressor/.azure-pipelines/scripts/fwk_version.sh $1
88

99
echo "set up UT env..."
1010
bash /neural-compressor/.azure-pipelines/scripts/ut/env_setup.sh "${test_case}"
11+
export LD_LIBRARY_PATH=/usr/local/lib/:$LD_LIBRARY_PATH
1112
export COVERAGE_RCFILE=/neural-compressor/.azure-pipelines/scripts/ut/coverage.file
1213
lpot_path=$(python -c 'import neural_compressor; import os; print(os.path.dirname(neural_compressor.__file__))')
1314
cd /neural-compressor/test || exit 1

.azure-pipelines/ut-3x-pt-fp8.yml

+4
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,10 @@ stages:
9595
&& bash ut/3x/collect_log_3x.sh 3x_pt_fp8"
9696
displayName: "Collect UT Coverage"
9797
98+
- task: PublishCodeCoverageResults@2
99+
inputs:
100+
summaryFileLocation: $(Build.SourcesDirectory)/log_dir/coverage_PR/coverage.xml
101+
98102
- task: PublishPipelineArtifact@1
99103
condition: succeededOrFailed()
100104
inputs:

.azure-pipelines/ut-3x-pt.yml

+4
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,10 @@ stages:
9595
&& bash ut/3x/collect_log_3x.sh 3x_pt"
9696
displayName: "Collect UT Coverage"
9797
98+
- task: PublishCodeCoverageResults@2
99+
inputs:
100+
summaryFileLocation: $(Build.SourcesDirectory)/log_dir/coverage_PR/coverage.xml
101+
98102
- task: PublishPipelineArtifact@1
99103
condition: succeededOrFailed()
100104
inputs:

.azure-pipelines/ut-3x-tf.yml

+4
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,10 @@ stages:
9292
&& bash ut/3x/collect_log_3x.sh 3x_tf"
9393
displayName: "Collect UT Coverage"
9494
95+
- task: PublishCodeCoverageResults@2
96+
inputs:
97+
summaryFileLocation: $(Build.SourcesDirectory)/log_dir/coverage_PR/coverage.xml
98+
9599
- task: PublishPipelineArtifact@1
96100
condition: succeededOrFailed()
97101
inputs:

.azure-pipelines/ut-basic.yml

+4
Original file line numberDiff line numberDiff line change
@@ -266,6 +266,10 @@ stages:
266266
&& bash ut/collect_log.sh"
267267
displayName: "Collect UT Coverage"
268268
269+
- task: PublishCodeCoverageResults@2
270+
inputs:
271+
summaryFileLocation: $(Build.SourcesDirectory)/log_dir/coverage_PR/coverage.xml
272+
269273
- task: PublishPipelineArtifact@1
270274
condition: succeededOrFailed()
271275
inputs:

README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ Intel® Neural Compressor
55
<h3> An open-source Python library supporting popular model compression techniques on all mainstream deep learning frameworks (TensorFlow, PyTorch, and ONNX Runtime)</h3>
66

77
[![python](https://img.shields.io/badge/python-3.8%2B-blue)](https://github.com/intel/neural-compressor)
8-
[![version](https://img.shields.io/badge/release-3.0-green)](https://github.com/intel/neural-compressor/releases)
8+
[![version](https://img.shields.io/badge/release-3.1.1-green)](https://github.com/intel/neural-compressor/releases)
99
[![license](https://img.shields.io/badge/license-Apache%202-blue)](https://github.com/intel/neural-compressor/blob/master/LICENSE)
1010
[![coverage](https://img.shields.io/badge/coverage-85%25-green)](https://github.com/intel/neural-compressor)
1111
[![Downloads](https://static.pepy.tech/personalized-badge/neural-compressor?period=total&units=international_system&left_color=grey&right_color=green&left_text=downloads)](https://pepy.tech/project/neural-compressor)

0 commit comments

Comments
 (0)