Skip to content

feat: diffusion.cpp bindings #7

feat: diffusion.cpp bindings

feat: diffusion.cpp bindings #7

Workflow file for this run

name: test
on:
workflow_dispatch:
pull_request:
branches: [ "main" ]
env:
CARGO_TERM_COLOR: always
jobs:
cargo-fmt:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
submodules: 'recursive'
- name: Ubuntu build dependencies
run: sudo apt update && sudo apt install -y clang cmake
- uses: dtolnay/rust-toolchain@stable
with:
components: rustfmt
- name: Check Style
run: cargo fmt --check
build:
strategy:
fail-fast: false
matrix:
platform: [ubuntu-latest, windows-latest, macos-latest]
runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@v4
with:
submodules: 'recursive'
- name: Ubuntu build dependencies
if: matrix.platform == 'ubuntu-latest'
run: sudo apt update && sudo apt install -y clang cmake
- uses: dtolnay/rust-toolchain@stable
- name: Build
run: cargo build
build-vulkan:
strategy:
fail-fast: false
matrix:
platform: [macos-latest, ubuntu-latest, windows-latest]
runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@v4
with:
submodules: 'recursive'
- name: install dependencies (ubuntu only)
if: matrix.platform == 'ubuntu-latest'
run: sudo apt update && sudo apt install -y clang cmake ninja-build
- name: install vulkan sdk
if: matrix.platform == 'macos-latest'
uses: humbletim/[email protected]
with:
version: latest
cache: true
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
- name: Build
run: cargo build --features vulkan
build-metal:
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
with:
submodules: 'recursive'
- uses: dtolnay/rust-toolchain@stable
- name: Build
run: cargo build --features metal
build-cuda:
strategy:
fail-fast: false
matrix:
platform: [ubuntu-22.04, windows-2022]
runs-on: ${{ matrix.platform }}
steps:
- uses: actions/checkout@v4
with:
submodules: 'recursive'
- name: Install cuda toolkit
uses: Jimver/[email protected]
- name: Install Windows dependencies
if: matrix.platform == 'windows-2022'
uses: ilammy/msvc-dev-cmd@v1
- name: Ubuntu build dependencies
if: matrix.platform == 'ubuntu-22.04'
run: sudo apt update && sudo apt install -y clang cmake
- uses: dtolnay/rust-toolchain@stable
- name: Build
env:
CUDA_COMPUTE_CAP: "75"
run: cargo build --features cublas