Update README.md #98
This file contains 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
name: Build Windows Wheel and test it | |
on: | |
workflow_dispatch: | |
push: | |
branches: [ "Cross_platform" ] | |
pull_request: | |
branches: [ "Cross_platform" ] | |
jobs: | |
build_windows_wheel: | |
runs-on: windows-2022 | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Install build deps | |
shell: bash | |
run: pip install -r requirements/build-wheel.txt | |
- name: Build Windows Wheel | |
shell: cmd | |
run: .\create_windows_wheel.bat | |
- name: upload_output | |
id: installer-upload-step | |
uses: actions/upload-artifact@v4 | |
with: | |
name: python_wheel_VS_2022_Windows_x64 | |
path: dist | |
regression_tests: | |
needs: build_windows_wheel | |
strategy: | |
fail-fast: false | |
matrix: | |
python_version: ['3.9', '3.10', '3.11', '3.12'] | |
name: "Run regression tests. " | |
runs-on: windows-2022 | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Download output tree built in previous job | |
uses: actions/download-artifact@v4 | |
with: | |
name: python_wheel_VS_2022_Windows_x64 | |
path: dist | |
- name: Run regression tests | |
uses: ./.github/actions/run_regression_tests | |
with: | |
python_version: ${{ matrix.python_version }} | |
DONT_TEST_N_LINK_SUBSYSTEMS_ORDER: 1 | |
ALLOW_NEGATIVE_FORMULA_ERROR_ON_ANY_LINK_PRESENT: 1 | |
sdna_installed_in_python_env: 1 | |
sdnadll: '' | |
sdna_debug: "" | |
shell: bash | |
smoke_tests: | |
needs: build_windows_wheel | |
strategy: | |
fail-fast: false | |
matrix: | |
python_version: ['3.12'] | |
smoke_test: ["python -u debug_test.py", | |
"python -u hybrid_test.py", | |
"python -u 3d_test.py", | |
"python -u partial_test.py", | |
"python -u test_parallel_results.py", | |
"python -u prepare_barns_test.py", | |
'sdnalearn --calibfile tiny.shp --target MADn --vars MGLAn,MCFn --boxcoxtarget --bcregex ".*" --mode single_best_variable --output regtestout_single_py3.txt --resids regtestresids_py3.shp', | |
'sdnalearn --calibfile tiny.shp --target MADn --vars MGLAn,MCFn --mode multiple_variables --output regtestout_multiple_py3.txt', | |
"python -u make_od_test_shp.py", | |
'sdnaintegral --im "net=skimtest" --om "skim=testout_od_skim_py3.csv" "radii=n;outputskim;skimzone=zone;nonetdata;metric=euclidean"', | |
'sdnaintegral --im "net=skimtestzeroweight" --om "skim=testout_od_skimzeroweight_py3.csv" "radii=n;outputskim;skimzone=zone;nonetdata;metric=euclidean;weight=weight"', | |
'python -u make_od_test_shp.py && sdnaintegral --im "net=odtest;tables=testodmatrix.csv" --om "net=odtestoutsparse_py3" "radii=n;odmatrix"', | |
'python -u make_od_test_shp.py && sdnaintegral --im "net=odtest;tables=testodmatrix-nonsparse.csv" --om "net=odtestoutnonsparse_py3" "radii=n;odmatrix" ', | |
'sdnaprepare -i prep_crash_shapefile/shapefilepreparecrash -o prep_crash_shapefile/out_py3 "action=repair;splitlinks;isolated;nearmisses;duplicates;xytol=0.01"', | |
"python -u prepare_test_new.py", | |
] | |
name: "Run smoke test. " | |
runs-on: windows-2022 | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: LizardByte/setup-python-action@master | |
with: | |
python-version: ${{ matrix.python_version }} | |
- name: Install dependencies (PyShp, Numpy & R Portable) | |
shell: bash | |
run: python -m pip install -r requirements/base.txt -r requirements/learn-predict.txt -r requirements/R_full.txt | |
- name: Download output tree built in previous job | |
uses: actions/download-artifact@v4 | |
with: | |
name: python_wheel_VS_2022_Windows_x64 | |
path: dist | |
- name: Install wheel | |
shell: bash | |
run: python -m pip install dist/sdna_plus*.whl | |
- name: Smoke test | |
working-directory: ./sDNA/sdna_vs2008/tests | |
env: | |
sdnadll: '' | |
SDNA_INSTALLED_IN_PYTHON_ENV: 1 | |
run: ${{ matrix.smoke_test }} |