Add support for parallel I/O #975
Workflow file for this run
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
| name: Windows CI (Conda) | |
| # TODO | |
| # - Re-add lue_consume build, once mdspan is not needed anymore | |
| # - Excluded some tests. Revisit. | |
| on: | |
| pull_request: | |
| # branches-ignore: | |
| # - "*" | |
| paths: | |
| - "**" | |
| - "!.github/workflows/*" | |
| - ".github/workflows/windows-conda.yml" | |
| push: | |
| branches: | |
| - "master" | |
| workflow_dispatch: | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }}-${{ github.actor }} | |
| cancel-in-progress: true | |
| jobs: | |
| build: | |
| strategy: | |
| matrix: | |
| os: ["windows-2022"] | |
| compiler: | |
| - { name: "msvc", c: cl, cxx: cl } | |
| vs: | |
| - { | |
| name: "Visual Studio Enterprise 2022", | |
| version: "17", | |
| msvc_toolset: "14", | |
| } | |
| python_version: ["3.12"] | |
| architecture: ["amd64"] | |
| runs-on: ${{ matrix.os }} | |
| name: ${{ matrix.os }} / ${{ matrix.vs.name }} / python - ${{ matrix.python_version }} | |
| timeout-minutes: 360 | |
| defaults: | |
| run: | |
| shell: bash -l {0} | |
| working-directory: . | |
| env: | |
| build_type: Release | |
| lue_source_directory: lue_source | |
| lue_build_directory: lue_build | |
| lue_runtime_install_directory: lue_runtime_install | |
| lue_development_install_directory: lue_development_install | |
| lue_consume_source_directory: lue_consume_source | |
| lue_consume_build_directory: lue_consume_build | |
| # conda-build provides the conda-develop command | |
| conda_packages: "conda-build cxxopts docopt jinja2 hdf5 hpx libboost-devel libboost-headers libgdal libhwloc matplotlib ninja nlohmann_json numpy pybind11 ruamel.yaml" | |
| steps: | |
| - uses: actions/checkout@v4 | |
| with: | |
| path: ${{ env.lue_source_directory }} | |
| - uses: ilammy/msvc-dev-cmd@v1 | |
| with: | |
| arch: ${{ matrix.architecture }} | |
| toolset: ${{ matrix.vs.msvc_toolset }} | |
| - uses: conda-incubator/setup-miniconda@v3 | |
| with: | |
| auto-update-conda: true | |
| miniforge-version: latest | |
| conda-solver: "libmamba" | |
| conda-remove-defaults: true | |
| python-version: ${{ matrix.python_version }} | |
| - name: install conda packages | |
| run: | | |
| conda install ${{ env.conda_packages }} | |
| - name: configure | |
| run: | | |
| # The element types for which relevant data structures and algorithms must be instantiated are | |
| # passed in explicitly here. To test whether this works correct and to speed up the build on | |
| # Windows, which is slow compared to the other platforms. | |
| # The types used are the ones needed for compatibility with PCRaster. | |
| mkdir -p ${{ env.lue_build_directory }} | |
| cmake \ | |
| -S ${{ env.lue_source_directory }} \ | |
| -B ${{ env.lue_build_directory }} \ | |
| --preset lue_release_windows_node \ | |
| -G "Ninja" \ | |
| -D CMAKE_C_COMPILER=${{ matrix.compiler.c }} \ | |
| -D CMAKE_CXX_COMPILER=${{ matrix.compiler.cxx }} \ | |
| -D CMAKE_BUILD_TYPE=${{ env.build_type }} \ | |
| -D LUE_BUILD_QUALITY_ASSURANCE=TRUE \ | |
| -D LUE_QUALITY_ASSURANCE_WITH_PYTHON_API=TRUE \ | |
| -D LUE_QUALITY_ASSURANCE_WITH_TESTS=TRUE \ | |
| -D LUE_QUALITY_ASSURANCE_TEST_NR_LOCALITIES_PER_TEST=1 \ | |
| -D LUE_QUALITY_ASSURANCE_TEST_NR_THREADS_PER_LOCALITY=2 \ | |
| -D LUE_DATA_MODEL_WITH_PYTHON_API=TRUE \ | |
| -D LUE_DATA_MODEL_WITH_UTILITIES=TRUE \ | |
| -D LUE_FRAMEWORK_WITH_IMAGE_LAND=TRUE \ | |
| -D LUE_FRAMEWORK_WITH_PYTHON_API=TRUE \ | |
| -D LUE_FRAMEWORK_SIGNED_INTEGRAL_ELEMENTS=std::int32_t \ | |
| -D LUE_FRAMEWORK_UNSIGNED_INTEGRAL_ELEMENTS=std::uint8_t \ | |
| -D LUE_FRAMEWORK_FLOATING_POINT_ELEMENTS=float \ | |
| -D LUE_FRAMEWORK_BOOLEAN_ELEMENT=std::uint8_t \ | |
| -D LUE_FRAMEWORK_COUNT_ELEMENT=std::int32_t \ | |
| -D LUE_FRAMEWORK_INDEX_ELEMENT=std::int32_t \ | |
| -D LUE_FRAMEWORK_ID_ELEMENT=std::int32_t \ | |
| -D LUE_BUILD_VIEW=FALSE \ | |
| -D Hwloc_ROOT=$CONDA_PREFIX/Library \ | |
| -D Hwloc_LIBRARY=$CONDA_PREFIX/Library/lib/hwloc.lib | |
| - name: build | |
| run: | | |
| cmake --build ${{ env.lue_build_directory }} \ | |
| --target all | |
| - name: install | |
| run: | | |
| cmake --install ${{ env.lue_build_directory }} \ | |
| --prefix ${{ env.lue_runtime_install_directory }} \ | |
| --component lue_runtime \ | |
| --strip | |
| cmake --install ${{ env.lue_build_directory }} \ | |
| --prefix ${{ env.lue_development_install_directory }} \ | |
| --component lue_development \ | |
| --strip | |
| - name: test | |
| run: | | |
| # Unit tests | |
| ctest --test-dir ${{ env.lue_build_directory }} \ | |
| --output-on-failure \ | |
| --exclude-regex "\ | |
| algorithm_decreasing_order_test" | |
| # TODO Expand PATH for this to work | |
| # ${{ env.lue_runtime_install_directory }}/bin/lue_translate --version | |
| # ${{ env.lue_runtime_install_directory }}/bin/lue_validate --version | |
| # Add our Python package to the set of Conda packages | |
| ls -l ${{ env.lue_runtime_install_directory }}/lib/python${{ matrix.python_version }} | |
| conda-develop ${{ env.lue_runtime_install_directory }}/lib/python${{ matrix.python_version }} | |
| ${{ env.lue_runtime_install_directory }}/bin/lue_calculate.py --version | |
| ${{ env.lue_runtime_install_directory }}/bin/lue_scalability.py --version | |
| python -c "import lue, lue.data_model, lue.framework, lue.pcraster, lue.qa.scalability; print(lue.__version__)" | |
| - name: consume | |
| if: "false" | |
| run: | | |
| # Test of imported CMake targets | |
| git clone https://github.com/computationalgeography/lue_consume.git ${{ env.lue_consume_source_directory }} | |
| cmake \ | |
| -S ${{ env.lue_consume_source_directory }} \ | |
| -B ${{ env.lue_consume_build_directory }} \ | |
| -G "Ninja" \ | |
| -D CMAKE_CXX_COMPILER=${{ matrix.compiler.cxx }} \ | |
| -D CMAKE_BUILD_TYPE=${{ env.build_type }} \ | |
| -D FETCHCONTENT_QUIET=FALSE \ | |
| -D Hwloc_ROOT=$CONDA_PREFIX/Library \ | |
| -D Hwloc_LIBRARY=$CONDA_PREFIX/Library/lib/hwloc.lib \ | |
| -D lue_ROOT=${{ env.lue_development_install_directory }} | |
| cmake --build ${{ env.lue_consume_build_directory }} --target all | |
| export PATH="${{ env.lue_development_install_directory }}/bin:${{ env.hpx_install_directory }}/bin:$PATH" | |
| ${{ env.lue_consume_build_directory }}/lue_consume_data_model | |
| ${{ env.lue_consume_build_directory }}/lue_consume_framework_algorithm | |
| ${{ env.lue_consume_build_directory }}/lue_consume_framework_io | |
| # NOTE: Secrets and variables are not passed to workflows that are triggered by a pull request from | |
| # a fork. | |
| - name: deploy | |
| if: github.repository == 'computationalgeography/lue' && github.ref == 'refs/heads/master' | |
| uses: Dylan700/sftp-upload-action@latest | |
| with: | |
| server: ${{ secrets.FTP_SERVER }} | |
| username: ${{ secrets.FTP_USERNAME }} | |
| password: ${{ secrets.FTP_PASSWORD }} | |
| port: ${{ secrets.FTP_PORT }} | |
| uploads: | | |
| ${{ env.lue_build_directory }}/ => ${{ secrets.FTP_REMOTE_DIR }}/download/build/windows-${{ matrix.compiler.name }}/ | |
| ignore: | | |
| !.ninja_log |