Skip to content

added support for handling weird Siemens 1.5T data that doesnt have a… #14

added support for handling weird Siemens 1.5T data that doesnt have a…

added support for handling weird Siemens 1.5T data that doesnt have a… #14

Workflow file for this run

name: Build and Upload Wheels
on: [push]
permissions:
id-token: write # Grant the workflow permissions to use the id-token
jobs:
build-linux-wheels:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.9', '3.10', '3.11', '3.12']
architecture: [x86_64, i686, aarch64]
steps:
- uses: actions/checkout@v2
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v1
- name: Install QEMU
uses: docker/setup-qemu-action@v1
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Set up Docker image
run: |
docker pull quay.io/pypa/manylinux2014_${{ matrix.architecture }}
- name: Build wheels
run: |
docker run --rm -v $GITHUB_WORKSPACE:/project quay.io/pypa/manylinux2014_${{ matrix.architecture }} /bin/bash -c "
yum install -y fftw-devel && \
mkdir -p /project/dist && \
for PYBIN in /opt/python/*${{ matrix.python-version }}*/bin; do
if [ -d \$PYBIN ]; then
echo Using Python binary from \$PYBIN >> /project/build.log
\$PYBIN/python -m ensurepip >> /project/build.log 2>&1 && \
\$PYBIN/pip install -U pip setuptools wheel auditwheel pybind11 >> /project/build.log 2>&1 && \
cd /project && \
echo Building wheel with Python binary from \$PYBIN >> /project/build.log && \
\$PYBIN/python setup.py bdist_wheel >> /project/build.log 2>&1 && \
\$PYBIN/auditwheel repair dist/*.whl -w /project/dist >> /project/build.log 2>&1
fi
done
"
- name: Output build logs
run: |
if [ -f $GITHUB_WORKSPACE/build.log ]; then cat $GITHUB_WORKSPACE/build.log; else echo "Build log not found"; fi
- name: Verify wheels
run: |
ls -al $GITHUB_WORKSPACE/dist/
- name: Upload to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.PYPI_API_TOKEN }}
build-macos-wheels:
runs-on: macos-latest
strategy:
matrix:
python-version: ['3.9', '3.10', '3.11', '3.12']
architecture: [x86_64, arm64]
steps:
- uses: actions/checkout@v2
- name: Set up Python
run: |
if [[ "${{ matrix.architecture }}" == "arm64" ]]; then
arch -arm64 brew install pyenv
arch -arm64 pyenv install ${{ matrix.python-version }}
arch -arm64 pyenv global ${{ matrix.python-version }}
echo "Python version set to $(python --version)"
else
brew install pyenv
pyenv install ${{ matrix.python-version }}
pyenv global ${{ matrix.python-version }}
echo "Python version set to $(python --version)"
fi
- name: Install dependencies
run: |
python -m pip install --upgrade pip setuptools wheel pybind11
brew install fftw
- name: Build wheels
env:
ARCHFLAGS: "-arch ${{ matrix.architecture }}"
run: |
mkdir -p $GITHUB_WORKSPACE/dist
if [[ "${{ matrix.architecture }}" == "arm64" ]]; then
arch -arm64 python setup.py bdist_wheel
else
python setup.py bdist_wheel
fi
- name: Repair wheels
env:
ARCHFLAGS: "-arch ${{ matrix.architecture }}"
run: |
pip install delocate
if [[ "${{ matrix.architecture }}" == "arm64" ]]; then
arch -arm64 delocate-listdeps $GITHUB_WORKSPACE/dist/*.whl # lists library dependencies
arch -arm64 delocate-wheel $GITHUB_WORKSPACE/dist/*.whl # copies library dependencies into the wheel
else
delocate-listdeps $GITHUB_WORKSPACE/dist/*.whl # lists library dependencies
delocate-wheel $GITHUB_WORKSPACE/dist/*.whl # copies library dependencies into the wheel
fi
- name: Verify wheels
run: |
ls -al $GITHUB_WORKSPACE/dist/
- name: Upload to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.PYPI_API_TOKEN }}
# build-windows-wheels:
# runs-on: windows-latest
# strategy:
# matrix:
# python-version: ['3.9', '3.10', '3.11', '3.12']
# steps:
# - uses: actions/checkout@v2
# - name: Set up Python
# uses: actions/setup-python@v2
# with:
# python-version: ${{ matrix.python-version }}
# - name: Install Miniconda
# uses: conda-incubator/setup-miniconda@v2
# with:
# auto-update-conda: true
# python-version: ${{ matrix.python-version }}
# activate-environment: myenv
# - name: Install FFTW
# run: |
# conda install -c conda-forge fftw
# - name: Install dependencies
# run: |
# python -m pip install --upgrade pip setuptools wheel pybind11
# - name: Ensure Visual C++ Build Tools are Installed
# run: |
# choco install visualstudio2019buildtools --package-parameters "--add Microsoft.VisualStudio.Workload.VCTools --includeRecommended --includeOptional"
# - name: Build wheels
# run: |
# mkdir -p $GITHUB_WORKSPACE/dist
# python setup.py bdist_wheel 2>&1 | tee $GITHUB_WORKSPACE/build.log
# - name: Output build logs
# run: |
# if [ -f $GITHUB_WORKSPACE/build.log ]; then cat $GITHUB_WORKSPACE/build.log; else echo “Build log not found”; fi
# - name: Verify wheels
# run: |
# ls -al $GITHUB_WORKSPACE/dist/
# - name: Upload to PyPI
# uses: pypa/gh-action-pypi-publish@release/v1
# with:
# password: ${{ secrets.PYPI_API_TOKEN }}