Skip to content

Merge pull request #696 from hasktorch/fix/move-tokenizer-to-examples #3037

Merge pull request #696 from hasktorch/fix/move-tokenizer-to-examples

Merge pull request #696 from hasktorch/fix/move-tokenizer-to-examples #3037

Workflow file for this run

name: stack-macos
on: [push, pull_request]
jobs:
build:
runs-on: macOS-latest
steps:
- uses: actions/checkout@v4
with:
submodules: true
- name: Setup tool-chains
run: |
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"
brew install libomp || true
pip3 install pyyaml || true
## Stack is preinstalled on the GHA runners
#wget -qO- https://get.haskellstack.org/ | sed -e 's/^STACK_VERSION=.*/STACK_VERSION="1.9.3"/g' | sh || true
#wget -qO- https://get.haskellstack.org/ | sh || true
clang --version
stack --version
brew tap hasktorch/libtorch-prebuild https://github.com/hasktorch/homebrew-libtorch-prebuild || true
brew install libtorch-prebuild@2.0 || true
#pushd deps/ ; ./get-deps.sh -a cpu -c ;popd
- name: Cache .stack
uses: actions/cache@v3
with:
path: |
~/.stack
.stack-work
key: "\
${{ runner.os }}-stack\
-${{ hashFiles('**/stack.yaml.lock') }}\
-${{ hashFiles('**/package.yaml') }}\
"
restore-keys: |
${{ runner.os }}-stack-
- name: Build
run: |
#. setenv
stack build \
libtorch-ffi \
libtorch-ffi-helper \
hasktorch \
codegen \
examples \
bounding-box \
dataloader-cifar10 \
untyped-nlp
- name: Test
run: |
#. setenv
stack test codegen
stack test libtorch-ffi
stack test hasktorch
stack exec codegen-exe
stack exec xor-mlp
stack exec regression
stack exec gaussian-process
stack exec vae
stack exec optimizers