Skip to content

Feat: Adding Linear Algebra Dot operation support #403

Feat: Adding Linear Algebra Dot operation support

Feat: Adding Linear Algebra Dot operation support #403

Workflow file for this run

name: Numpy User DTypes CI
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Setup Python
uses: actions/setup-python@v3
with:
python-version: "3.10"
- name: Install build and test dependencies
run: |
python -m pip install -U pip build pytest unyt wheel meson ninja meson-python patchelf pandas numpy
- name: Install asciidtype
working-directory: asciidtype
run: |
CFLAGS="-Werror" python -m pip install . --no-build-isolation
- name: Run asciidtype tests
working-directory: asciidtype
run: |
pytest -vvv --color=yes
- name: Install metadatadtype
working-directory: metadatadtype
run: |
python -m build --no-isolation --wheel -Cbuilddir=build
find ./dist/*.whl | xargs python -m pip install
- name: Run metadatadtype tests
working-directory: metadatadtype
run: |
pytest -vvv --color=yes
- name: install mpfdtype
working-directory: mpfdtype
run: |
sudo apt install libmpfr-dev -y
CFLAGS="-Werror" python -m pip install . --no-build-isolation
- name: Run mpfdtype tests
working-directory: mpfdtype
run: |
pytest -vvv --color=yes
- name: Install unytdtype
working-directory: unytdtype
run: |
python -m build --no-isolation --wheel -Cbuilddir=build
find ./dist/*.whl | xargs python -m pip install
- name: Run unytdtype tests
working-directory: unytdtype
run: |
pytest -vvv --color=yes
- name: Install quaddtype dependencies
run: |
sudo apt-get update
sudo apt-get install -y libmpfr-dev libssl-dev libfftw3-dev
- name: Install SLEEF
run: |
sudo apt-get update -y
sudo apt-get install -y cmake gcc g++ make git pkg-config
git clone --branch 3.8 https://github.com/shibatch/sleef.git
cd sleef
cmake -S . -B build -DSLEEF_BUILD_QUAD:BOOL=ON -DSLEEF_BUILD_SHARED_LIBS:BOOL=ON -DCMAKE_POSITION_INDEPENDENT_CODE=ON
cmake --build build/ --clean-first -j
sudo cmake --install build --prefix /usr/local
- name: Install quaddtype
working-directory: quaddtype
run: |
# Initialize submodules first
git submodule update --init --recursive
ls -la numpy_quaddtype/QBLAS/
# Set environment variables with proper export and correct paths
export CFLAGS="-I/usr/local/include -I$(pwd)/numpy_quaddtype/QBLAS/include"
export CXXFLAGS="-I/usr/local/include -I$(pwd)/numpy_quaddtype/QBLAS/include -fext-numeric-literals"
export LDFLAGS="-L/usr/local/lib64 -L/usr/local/lib -Wl,-rpath,/usr/local/lib64 -Wl,-rpath,/usr/local/lib -fopenmp"
export LD_LIBRARY_PATH="/usr/local/lib64:/usr/local/lib:$LD_LIBRARY_PATH"
# Install with meson args to ensure the C++ flags are passed through
python -m pip install . -v --no-build-isolation \
-Cbuilddir=build \
-C'compile-args=-v' \
-Csetup-args="-Dbuildtype=debug" \
-Csetup-args="-Dcpp_args=-fext-numeric-literals"
- name: Run quaddtype tests
working-directory: quaddtype
run: |
pytest -vvv --color=yes
- name: Install stringdtype
working-directory: stringdtype
run: |
if [ -d "build/" ]
then
rm -r build
fi
meson setup build
python -m build --no-isolation --wheel -Cbuilddir=build --config-setting='compile-args=-v' -Csetup-args="-Dbuildtype=debug"
find ./dist/*.whl | xargs python -m pip install
- name: Run stringdtype tests
working-directory: stringdtype
run: |
pytest -s -vvv --color=yes
pip uninstall -y pandas
pytest -s -vvv --color=yes