Skip to content

Commit

Permalink
Merge pull request #88 from xmos/doc_charts
Browse files Browse the repository at this point in the history
Doc charts
  • Loading branch information
shuchitak authored Sep 28, 2023
2 parents b5b90b0 + 544d3c8 commit fc45721
Show file tree
Hide file tree
Showing 7 changed files with 666 additions and 5 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -29,3 +29,6 @@ tests/vpu_ff3_test/autogen
tests/vpu_rat_test/autogen
*.csv
python/lib_src.egg-info
**/tmp_models/
*.bak
make_docs.sh
22 changes: 19 additions & 3 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -94,23 +94,39 @@ pipeline {
}
}
}
stage('Run doc python') {
steps {
runningOn(env.NODE_NAME)
dir("${REPO}") {
withTools(params.TOOLS_VERSION) {
withVenv {
dir("doc/python") {
sh "python -m doc_asrc.py"
sh "zip -r snr_build.zip _build"
archiveArtifacts artifacts: "snr_build.zip"
}
}
}
}
}
}
stage('Tests XS2') {
steps {
runningOn(env.NODE_NAME)
dir("${REPO}") {
withTools(params.TOOLS_VERSION) {
withVenv {
sh 'mkdir build'
sh 'mkdir -p build'
dir("build") {
sh 'rm -rf'
sh 'rm CMakeCache.txt'
sh 'cmake --toolchain ../xmos_cmake_toolchain/xs2a.cmake ..'
sh 'make test_ds3_voice test_us3_voice test_unity_gain_voice -j'
}
dir("tests") {
localRunPytest('-n auto -k "xs2" -vv')
}
dir("build") {
sh 'rm -rf' // Cleanup XS2 cmake cache for next stage
sh 'rm CMakeCache.txt' // Cleanup XS2 cmake cache for next stage
}
}
}
Expand Down
37 changes: 37 additions & 0 deletions doc/python/README.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
INTRODUCTION
============

This folder includes a python script which runs the C emulators for the ASRC, SSRC, OS3 and DS3 modules.
For each model we present test signals - both a single tone to test the THD performance and a range of tones to
observe roll-off at the top of the band.
Using an un-windowed FFT we calculate the SNR.
We scrape the logs to extract MIPS/Utilization where supported.

Tests are run for all suported input and output sample freqencies, and for worst case frequency deviation.
Note that not all modules support all input scenarios - these are ignored.

The result of this script is the generation an rst file which is included into the documentation,
incorporating a full set of charts and summary table.



REQUIREMENTS
============

Python 3.9 or above. Make sure the dependencies listed in lib_src/requirements.txt are installed.

cd ../../
pip install -r requirements.txt



To run the script:

python3 doc_asrc.py


By default, this will create a "_build" folder, containing sub-folders:
./input all generated test files
./expected simulation output from the models
./output plots and a csv format log file
./rst a single rst file which incorporates all the plots and log file as a table
Loading

0 comments on commit fc45721

Please sign in to comment.