| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  | version: 2.1
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2024-02-15 19:30:35 -06:00
										 |  |  | orbs:
 | 
					
						
							|  |  |  |   apple: ml-explore/pr-approval@0.1.0
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  | parameters:
 | 
					
						
							|  |  |  |   nightly_build:
 | 
					
						
							|  |  |  |     type: boolean
 | 
					
						
							|  |  |  |     default: false
 | 
					
						
							|  |  |  |   weekly_build:
 | 
					
						
							|  |  |  |     type: boolean
 | 
					
						
							|  |  |  |     default: false
 | 
					
						
							| 
									
										
										
										
											2024-02-09 18:17:04 -08:00
										 |  |  |   test_release:
 | 
					
						
							|  |  |  |     type: boolean
 | 
					
						
							|  |  |  |     default: false
 | 
					
						
							| 
									
										
										
										
											2024-10-14 06:21:44 -07:00
										 |  |  |   linux_release:
 | 
					
						
							|  |  |  |     type: boolean
 | 
					
						
							|  |  |  |     default: false
 | 
					
						
							| 
									
										
										
										
											2025-06-19 15:26:36 -07:00
										 |  |  |   cuda_release:
 | 
					
						
							|  |  |  |     type: boolean
 | 
					
						
							|  |  |  |     default: false
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  | 
 | 
					
						
							|  |  |  | jobs:
 | 
					
						
							| 
									
										
										
										
											2024-10-15 17:40:00 -07:00
										 |  |  |   build_documentation:
 | 
					
						
							|  |  |  |     parameters:
 | 
					
						
							|  |  |  |       upload-docs:
 | 
					
						
							|  |  |  |         type: boolean
 | 
					
						
							|  |  |  |         default: false
 | 
					
						
							|  |  |  |     macos:
 | 
					
						
							| 
									
										
										
										
											2025-03-28 14:31:53 -07:00
										 |  |  |       xcode: "16.2.0"
 | 
					
						
							|  |  |  |     resource_class: m2pro.medium
 | 
					
						
							| 
									
										
										
										
											2024-10-15 17:40:00 -07:00
										 |  |  |     steps:
 | 
					
						
							|  |  |  |       - checkout
 | 
					
						
							|  |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Install
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							|  |  |  |             brew install python@3.9
 | 
					
						
							|  |  |  |             brew install doxygen
 | 
					
						
							|  |  |  |             python3.9 -m venv env
 | 
					
						
							|  |  |  |             source env/bin/activate
 | 
					
						
							|  |  |  |             pip install --upgrade pip
 | 
					
						
							|  |  |  |             pip install --upgrade cmake
 | 
					
						
							|  |  |  |             pip install -r docs/requirements.txt
 | 
					
						
							| 
									
										
										
										
											2025-07-07 22:06:45 +09:00
										 |  |  |             pip install . -v
 | 
					
						
							| 
									
										
										
										
											2024-10-15 17:40:00 -07:00
										 |  |  |       - when:
 | 
					
						
							|  |  |  |           condition:
 | 
					
						
							|  |  |  |             not: << parameters.upload-docs >>
 | 
					
						
							|  |  |  |           steps:
 | 
					
						
							|  |  |  |             - run:
 | 
					
						
							|  |  |  |                name: Build documentation
 | 
					
						
							|  |  |  |                command: |
 | 
					
						
							|  |  |  |                  source env/bin/activate
 | 
					
						
							|  |  |  |                  cd docs && doxygen && make html O=-W
 | 
					
						
							|  |  |  |       - when:
 | 
					
						
							|  |  |  |           condition: << parameters.upload-docs >>
 | 
					
						
							|  |  |  |           steps:
 | 
					
						
							|  |  |  |             - add_ssh_keys:
 | 
					
						
							|  |  |  |                 fingerprints:
 | 
					
						
							|  |  |  |                   - "SHA256:OhcVVMovbT0pkgMeiVRyxMnjV9R2t+hKBsNcuxq9h+0"
 | 
					
						
							|  |  |  |             - run:
 | 
					
						
							|  |  |  |                name: Upload documentation
 | 
					
						
							|  |  |  |                command: |
 | 
					
						
							|  |  |  |                  source env/bin/activate
 | 
					
						
							|  |  |  |                  git config user.email "mlx@group.apple.com"
 | 
					
						
							|  |  |  |                  git config user.name "CircleCI Docs"
 | 
					
						
							|  |  |  |                  git checkout gh-pages
 | 
					
						
							|  |  |  |                  git rebase main
 | 
					
						
							|  |  |  |                  cd docs
 | 
					
						
							|  |  |  |                  git rm -rf build/html
 | 
					
						
							|  |  |  |                  doxygen && make html O=-W
 | 
					
						
							|  |  |  |                  git add -f build/html
 | 
					
						
							|  |  |  |                  git commit -m "rebase"
 | 
					
						
							|  |  |  |                  git push -f origin gh-pages
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |   linux_build_and_test:
 | 
					
						
							|  |  |  |     docker:
 | 
					
						
							|  |  |  |       - image: cimg/python:3.9
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |     steps:
 | 
					
						
							|  |  |  |       - checkout
 | 
					
						
							|  |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Run style checks
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							|  |  |  |             pip install pre-commit
 | 
					
						
							|  |  |  |             pre-commit run --all
 | 
					
						
							|  |  |  |             if ! git diff --quiet; then echo 'Style checks failed, please install pre-commit and run pre-commit run --all and push the change'; exit 1; fi
 | 
					
						
							|  |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Install dependencies
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							|  |  |  |             pip install --upgrade cmake
 | 
					
						
							| 
									
										
										
										
											2024-12-17 10:57:54 -08:00
										 |  |  |             pip install nanobind==2.4.0
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |             pip install numpy
 | 
					
						
							|  |  |  |             sudo apt-get update
 | 
					
						
							| 
									
										
										
										
											2024-01-26 09:27:31 -08:00
										 |  |  |             sudo apt-get install libblas-dev liblapack-dev liblapacke-dev
 | 
					
						
							| 
									
										
										
										
											2025-03-21 11:23:10 -07:00
										 |  |  |             sudo apt-get install openmpi-bin openmpi-common libopenmpi-dev
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |       - run:
 | 
					
						
							| 
									
										
										
										
											2024-01-21 17:53:12 -03:00
										 |  |  |           name: Install Python package
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |           command: |
 | 
					
						
							| 
									
										
										
										
											2025-03-28 14:31:53 -07:00
										 |  |  |             CMAKE_ARGS="-DMLX_BUILD_METAL=OFF" \
 | 
					
						
							| 
									
										
										
										
											2024-09-10 15:15:17 -07:00
										 |  |  |               python3 setup.py build_ext --inplace
 | 
					
						
							| 
									
										
										
										
											2025-03-28 14:31:53 -07:00
										 |  |  |             CMAKE_ARGS="-DMLX_BUILD_METAL=OFF" \
 | 
					
						
							| 
									
										
										
										
											2024-09-10 15:15:17 -07:00
										 |  |  |               python3 setup.py develop
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |       - run:
 | 
					
						
							| 
									
										
										
										
											2024-01-21 17:53:12 -03:00
										 |  |  |           name: Generate package stubs
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							| 
									
										
										
										
											2024-03-18 20:12:25 -07:00
										 |  |  |             echo "stubs"
 | 
					
						
							| 
									
										
										
										
											2024-08-22 14:07:27 -07:00
										 |  |  |             pip install typing_extensions
 | 
					
						
							| 
									
										
										
										
											2025-06-19 15:26:36 -07:00
										 |  |  |             python setup.py generate_stubs
 | 
					
						
							| 
									
										
										
										
											2024-01-21 17:53:12 -03:00
										 |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Run Python tests
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |           command: |
 | 
					
						
							| 
									
										
										
										
											2024-01-29 11:19:38 -08:00
										 |  |  |             python3 -m unittest discover python/tests -v
 | 
					
						
							| 
									
										
										
										
											2025-03-21 11:23:10 -07:00
										 |  |  |             mpirun --bind-to none -host localhost:8 -np 8 python python/tests/mpi_test_distributed.py
 | 
					
						
							|  |  |  |             mlx.launch --verbose -n 8 python/tests/ring_test_distributed.py
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Build CPP only
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							| 
									
										
										
										
											2024-09-10 15:15:17 -07:00
										 |  |  |             mkdir -p build && cd build 
 | 
					
						
							|  |  |  |             cmake .. -DMLX_BUILD_METAL=OFF -DCMAKE_BUILD_TYPE=DEBUG
 | 
					
						
							|  |  |  |             make -j `nproc`
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Run CPP tests
 | 
					
						
							|  |  |  |           command: ./build/tests/tests
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  |   mac_build_and_test:
 | 
					
						
							| 
									
										
										
										
											2024-03-07 08:19:43 -08:00
										 |  |  |     parameters:
 | 
					
						
							|  |  |  |       xcode_version:
 | 
					
						
							|  |  |  |         type: string
 | 
					
						
							| 
									
										
										
										
											2025-03-28 14:31:53 -07:00
										 |  |  |         default: "16.2.0"
 | 
					
						
							|  |  |  |       macosx_deployment_target:
 | 
					
						
							|  |  |  |         type: string
 | 
					
						
							|  |  |  |         default: ""
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |     macos:
 | 
					
						
							| 
									
										
										
										
											2024-03-07 08:19:43 -08:00
										 |  |  |       xcode: << parameters.xcode_version >>
 | 
					
						
							| 
									
										
										
										
											2025-03-28 14:31:53 -07:00
										 |  |  |     environment:
 | 
					
						
							|  |  |  |       MACOSX_DEPLOYMENT_TARGET: << parameters.macosx_deployment_target >>
 | 
					
						
							|  |  |  |     resource_class: m2pro.medium
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |     steps:
 | 
					
						
							|  |  |  |       - checkout
 | 
					
						
							|  |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Install dependencies
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							| 
									
										
										
										
											2024-10-14 10:40:32 -07:00
										 |  |  |             brew install python@3.9
 | 
					
						
							| 
									
										
										
										
											2024-05-23 17:04:02 -07:00
										 |  |  |             brew install openmpi
 | 
					
						
							| 
									
										
										
										
											2024-10-14 10:40:32 -07:00
										 |  |  |             python3.9 -m venv env
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |             source env/bin/activate
 | 
					
						
							|  |  |  |             pip install --upgrade pip
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |             pip install --upgrade cmake
 | 
					
						
							| 
									
										
										
										
											2024-12-17 10:57:54 -08:00
										 |  |  |             pip install nanobind==2.4.0
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |             pip install numpy
 | 
					
						
							|  |  |  |             pip install torch
 | 
					
						
							| 
									
										
										
										
											2024-01-06 00:58:33 +01:00
										 |  |  |             pip install tensorflow
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |             pip install unittest-xml-reporting
 | 
					
						
							|  |  |  |       - run:
 | 
					
						
							| 
									
										
										
										
											2024-01-21 17:53:12 -03:00
										 |  |  |           name: Install Python package
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |           command: |
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |             source env/bin/activate
 | 
					
						
							| 
									
										
										
										
											2025-07-07 22:06:45 +09:00
										 |  |  |             DEBUG=1 CMAKE_ARGS="-DCMAKE_COMPILE_WARNING_AS_ERROR=ON" \
 | 
					
						
							| 
									
										
										
										
											2025-03-12 13:08:19 -07:00
										 |  |  |               pip install -e . -v
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |       - run:
 | 
					
						
							| 
									
										
										
										
											2024-01-21 17:53:12 -03:00
										 |  |  |           name: Generate package stubs
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |             source env/bin/activate
 | 
					
						
							| 
									
										
										
										
											2024-08-22 14:07:27 -07:00
										 |  |  |             pip install typing_extensions
 | 
					
						
							| 
									
										
										
										
											2025-06-19 15:26:36 -07:00
										 |  |  |             python setup.py generate_stubs
 | 
					
						
							| 
									
										
										
										
											2024-01-21 17:53:12 -03:00
										 |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Run Python tests
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |           command: |
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |             source env/bin/activate
 | 
					
						
							|  |  |  |             LOW_MEMORY=1 DEVICE=cpu python -m xmlrunner discover -v python/tests -o test-results/cpu
 | 
					
						
							| 
									
										
										
										
											2024-03-07 08:19:43 -08:00
										 |  |  |             LOW_MEMORY=1 DEVICE=gpu METAL_DEVICE_WRAPPER_TYPE=1 METAL_DEBUG_ERROR_MODE=0 python -m xmlrunner discover -v python/tests -o test-results/gpu
 | 
					
						
							| 
									
										
										
										
											2024-10-06 06:09:17 -07:00
										 |  |  |             mpirun --bind-to none -host localhost:8 -np 8 -x DYLD_LIBRARY_PATH=/opt/homebrew/lib/ python python/tests/mpi_test_distributed.py
 | 
					
						
							| 
									
										
										
										
											2025-01-29 17:55:04 -08:00
										 |  |  |             mlx.launch --verbose -n 8 python/tests/ring_test_distributed.py
 | 
					
						
							| 
									
										
										
										
											2024-05-16 15:36:25 -07:00
										 |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Build example extension
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							| 
									
										
										
										
											2024-05-17 15:09:28 -07:00
										 |  |  |             source env/bin/activate
 | 
					
						
							|  |  |  |             cd examples/extensions
 | 
					
						
							|  |  |  |             pip install -r requirements.txt
 | 
					
						
							|  |  |  |             python setup.py build_ext -j8
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |       - store_test_results:
 | 
					
						
							|  |  |  |           path: test-results
 | 
					
						
							| 
									
										
										
										
											2024-01-11 11:57:24 -08:00
										 |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Build CPP only
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |             source env/bin/activate
 | 
					
						
							| 
									
										
										
										
											2024-09-10 15:15:17 -07:00
										 |  |  |             mkdir -p build && cd build && cmake .. && make -j `sysctl -n hw.ncpu`
 | 
					
						
							| 
									
										
										
										
											2024-01-11 11:57:24 -08:00
										 |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Run CPP tests
 | 
					
						
							| 
									
										
										
										
											2024-02-14 13:42:13 -08:00
										 |  |  |           command: |
 | 
					
						
							|  |  |  |             DEVICE=gpu METAL_DEVICE_WRAPPER_TYPE=1 METAL_DEBUG_ERROR_MODE=0 ./build/tests/tests
 | 
					
						
							| 
									
										
										
										
											2024-05-22 12:57:13 -07:00
										 |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Build small binary
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							|  |  |  |             source env/bin/activate
 | 
					
						
							|  |  |  |             cd build/
 | 
					
						
							| 
									
										
										
										
											2024-09-10 15:15:17 -07:00
										 |  |  |             cmake .. -DCMAKE_BUILD_TYPE=MinSizeRel \
 | 
					
						
							|  |  |  |               -DBUILD_SHARED_LIBS=ON \
 | 
					
						
							|  |  |  |               -DMLX_BUILD_CPU=OFF \
 | 
					
						
							|  |  |  |               -DMLX_BUILD_SAFETENSORS=OFF \
 | 
					
						
							|  |  |  |               -DMLX_BUILD_GGUF=OFF \
 | 
					
						
							|  |  |  |               -DMLX_METAL_JIT=ON
 | 
					
						
							|  |  |  |             make -j `sysctl -n hw.ncpu`
 | 
					
						
							| 
									
										
										
										
											2024-08-28 16:39:11 -07:00
										 |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Run Python tests with JIT
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							|  |  |  |             source env/bin/activate
 | 
					
						
							| 
									
										
										
										
											2025-07-07 22:06:45 +09:00
										 |  |  |             CMAKE_ARGS="-DMLX_METAL_JIT=ON" \
 | 
					
						
							| 
									
										
										
										
											2024-09-10 15:15:17 -07:00
										 |  |  |               pip install -e . -v
 | 
					
						
							|  |  |  |             LOW_MEMORY=1 DEVICE=gpu METAL_DEVICE_WRAPPER_TYPE=1 \
 | 
					
						
							|  |  |  |               METAL_DEBUG_ERROR_MODE=0 \
 | 
					
						
							|  |  |  |               python -m xmlrunner discover -v python/tests -o test-results/gpu_jit
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2025-06-10 21:19:47 -07:00
										 |  |  |   cuda_build_and_test:
 | 
					
						
							|  |  |  |     machine:
 | 
					
						
							|  |  |  |       image: linux-cuda-12:default
 | 
					
						
							|  |  |  |       resource_class: gpu.nvidia.small.gen2
 | 
					
						
							|  |  |  |     steps:
 | 
					
						
							|  |  |  |       - checkout
 | 
					
						
							|  |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Install Python package
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							|  |  |  |             sudo apt-get update
 | 
					
						
							|  |  |  |             sudo apt-get install libblas-dev liblapack-dev liblapacke-dev
 | 
					
						
							|  |  |  |             python -m venv env
 | 
					
						
							|  |  |  |             source env/bin/activate
 | 
					
						
							| 
									
										
										
										
											2025-07-07 22:06:45 +09:00
										 |  |  |             CMAKE_ARGS="-DMLX_BUILD_CUDA=ON -DCMAKE_CUDA_COMPILER=`which nvcc`" \
 | 
					
						
							| 
									
										
										
										
											2025-06-10 21:19:47 -07:00
										 |  |  |               pip install -e ".[dev]"
 | 
					
						
							|  |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Run Python tests
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							|  |  |  |             source env/bin/activate
 | 
					
						
							|  |  |  |             LOW_MEMORY=1 DEVICE=cpu python -m unittest discover python/tests -v
 | 
					
						
							| 
									
										
										
										
											2025-06-15 10:56:48 -07:00
										 |  |  |             LOW_MEMORY=1 DEVICE=gpu python -m tests discover python/tests -v
 | 
					
						
							| 
									
										
										
										
											2025-06-10 21:19:47 -07:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |   build_release:
 | 
					
						
							|  |  |  |     parameters:
 | 
					
						
							|  |  |  |       python_version:
 | 
					
						
							|  |  |  |         type: string
 | 
					
						
							|  |  |  |         default: "3.9"
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |       xcode_version:
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |         type: string
 | 
					
						
							| 
									
										
										
										
											2025-03-28 14:31:53 -07:00
										 |  |  |         default: "16.2.0"
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |       build_env:
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |         type: string
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |         default: ""
 | 
					
						
							| 
									
										
										
										
											2025-03-28 14:31:53 -07:00
										 |  |  |       macosx_deployment_target:
 | 
					
						
							|  |  |  |         type: string
 | 
					
						
							|  |  |  |         default: ""
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |     macos:
 | 
					
						
							|  |  |  |       xcode: << parameters.xcode_version >>
 | 
					
						
							| 
									
										
										
										
											2025-03-28 14:31:53 -07:00
										 |  |  |     resource_class: m2pro.medium
 | 
					
						
							|  |  |  |     environment:
 | 
					
						
							|  |  |  |       MACOSX_DEPLOYMENT_TARGET: << parameters.macosx_deployment_target >>
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |     steps:
 | 
					
						
							|  |  |  |       - checkout
 | 
					
						
							|  |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Install dependencies
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |             brew install python@<< parameters.python_version >>
 | 
					
						
							| 
									
										
										
										
											2024-06-10 10:09:32 -07:00
										 |  |  |             brew install openmpi
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |             python<< parameters.python_version >> -m venv env
 | 
					
						
							|  |  |  |             source env/bin/activate
 | 
					
						
							|  |  |  |             pip install --upgrade pip
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |             pip install --upgrade cmake
 | 
					
						
							| 
									
										
										
										
											2024-12-17 10:57:54 -08:00
										 |  |  |             pip install nanobind==2.4.0
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |             pip install --upgrade setuptools
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |             pip install numpy
 | 
					
						
							|  |  |  |             pip install twine
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |             pip install build
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |       - run:
 | 
					
						
							| 
									
										
										
										
											2024-01-21 17:53:12 -03:00
										 |  |  |           name: Install Python package
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |             source env/bin/activate
 | 
					
						
							| 
									
										
										
										
											2025-04-12 20:41:58 -07:00
										 |  |  |             env -u MACOSX_DEPLOYMENT_TARGET DEV_RELEASE=1 \
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |               pip install . -v
 | 
					
						
							| 
									
										
										
										
											2024-01-21 17:53:12 -03:00
										 |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Generate package stubs
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |             source env/bin/activate
 | 
					
						
							| 
									
										
										
										
											2024-08-22 14:07:27 -07:00
										 |  |  |             pip install typing_extensions
 | 
					
						
							| 
									
										
										
										
											2025-06-19 15:26:36 -07:00
										 |  |  |             python setup.py generate_stubs
 | 
					
						
							| 
									
										
										
										
											2024-01-21 17:53:12 -03:00
										 |  |  |       - run:
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |           name: Build Python package
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |           command: |
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |             source env/bin/activate
 | 
					
						
							| 
									
										
										
										
											2025-07-07 22:06:45 +09:00
										 |  |  |             << parameters.build_env >> python -m build -w
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |       - when:
 | 
					
						
							|  |  |  |           condition: << parameters.build_env >>
 | 
					
						
							|  |  |  |           steps:
 | 
					
						
							|  |  |  |             - run:
 | 
					
						
							|  |  |  |                 name: Upload package
 | 
					
						
							|  |  |  |                 command: |
 | 
					
						
							|  |  |  |                   source env/bin/activate
 | 
					
						
							|  |  |  |                   twine upload dist/*
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |       - store_artifacts:
 | 
					
						
							|  |  |  |           path: dist/
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2024-10-14 06:21:44 -07:00
										 |  |  |   build_linux_release:
 | 
					
						
							| 
									
										
										
										
											2024-02-09 18:17:04 -08:00
										 |  |  |     parameters:
 | 
					
						
							|  |  |  |       python_version:
 | 
					
						
							|  |  |  |         type: string
 | 
					
						
							|  |  |  |         default: "3.9"
 | 
					
						
							|  |  |  |       extra_env:
 | 
					
						
							|  |  |  |         type: string
 | 
					
						
							|  |  |  |         default: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |     docker:
 | 
					
						
							|  |  |  |       - image: ubuntu:20.04
 | 
					
						
							|  |  |  |     steps:
 | 
					
						
							|  |  |  |       - checkout
 | 
					
						
							|  |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Build wheel
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							|  |  |  |             PYTHON=python<< parameters.python_version >>
 | 
					
						
							|  |  |  |             apt-get update
 | 
					
						
							|  |  |  |             apt-get upgrade -y
 | 
					
						
							|  |  |  |             DEBIAN_FRONTEND=noninteractive TZ=Etc/UTC apt-get -y install tzdata
 | 
					
						
							|  |  |  |             apt-get install -y apt-utils
 | 
					
						
							|  |  |  |             apt-get install -y software-properties-common
 | 
					
						
							|  |  |  |             add-apt-repository -y ppa:deadsnakes/ppa
 | 
					
						
							|  |  |  |             apt-get install -y $PYTHON $PYTHON-dev $PYTHON-full
 | 
					
						
							|  |  |  |             apt-get install -y libblas-dev liblapack-dev liblapacke-dev
 | 
					
						
							|  |  |  |             apt-get install -y build-essential git
 | 
					
						
							|  |  |  |             $PYTHON -m venv env
 | 
					
						
							|  |  |  |             source env/bin/activate
 | 
					
						
							|  |  |  |             pip install --upgrade pip
 | 
					
						
							|  |  |  |             pip install --upgrade cmake
 | 
					
						
							| 
									
										
										
										
											2024-12-17 10:57:54 -08:00
										 |  |  |             pip install nanobind==2.4.0
 | 
					
						
							| 
									
										
										
										
											2024-02-09 18:17:04 -08:00
										 |  |  |             pip install --upgrade setuptools
 | 
					
						
							|  |  |  |             pip install numpy
 | 
					
						
							|  |  |  |             pip install auditwheel
 | 
					
						
							|  |  |  |             pip install patchelf
 | 
					
						
							|  |  |  |             pip install build
 | 
					
						
							| 
									
										
										
										
											2024-10-14 06:21:44 -07:00
										 |  |  |             pip install twine
 | 
					
						
							| 
									
										
										
										
											2025-07-07 22:06:45 +09:00
										 |  |  |             << parameters.extra_env >> pip install . -v
 | 
					
						
							| 
									
										
										
										
											2024-08-22 14:07:27 -07:00
										 |  |  |             pip install typing_extensions
 | 
					
						
							| 
									
										
										
										
											2025-06-19 15:26:36 -07:00
										 |  |  |             python setup.py generate_stubs
 | 
					
						
							| 
									
										
										
										
											2025-07-07 22:06:45 +09:00
										 |  |  |             << parameters.extra_env >> python -m build --wheel
 | 
					
						
							| 
									
										
										
										
											2024-02-09 18:17:04 -08:00
										 |  |  |             auditwheel show dist/*
 | 
					
						
							|  |  |  |             auditwheel repair dist/* --plat manylinux_2_31_x86_64
 | 
					
						
							| 
									
										
										
										
											2024-10-14 06:21:44 -07:00
										 |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Upload package
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							|  |  |  |             source env/bin/activate
 | 
					
						
							|  |  |  |             twine upload wheelhouse/*
 | 
					
						
							| 
									
										
										
										
											2024-02-09 18:17:04 -08:00
										 |  |  |       - store_artifacts:
 | 
					
						
							|  |  |  |           path: wheelhouse/
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2025-06-19 15:26:36 -07:00
										 |  |  |   build_cuda_release:
 | 
					
						
							|  |  |  |     parameters:
 | 
					
						
							|  |  |  |       python_version:
 | 
					
						
							|  |  |  |         type: string
 | 
					
						
							|  |  |  |         default: "3.9"
 | 
					
						
							|  |  |  |       extra_env:
 | 
					
						
							|  |  |  |         type: string
 | 
					
						
							|  |  |  |         default: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |     machine:
 | 
					
						
							|  |  |  |       image: linux-cuda-12:default
 | 
					
						
							|  |  |  |       resource_class: gpu.nvidia.small.gen2
 | 
					
						
							|  |  |  |     steps:
 | 
					
						
							|  |  |  |       - checkout
 | 
					
						
							|  |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Build wheel
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							|  |  |  |             sudo apt-get update
 | 
					
						
							|  |  |  |             sudo apt-get install libblas-dev liblapack-dev liblapacke-dev
 | 
					
						
							|  |  |  |             python -m venv env
 | 
					
						
							|  |  |  |             source env/bin/activate
 | 
					
						
							|  |  |  |             pip install auditwheel
 | 
					
						
							|  |  |  |             pip install patchelf
 | 
					
						
							|  |  |  |             pip install build
 | 
					
						
							|  |  |  |             pip install twine
 | 
					
						
							|  |  |  |             << parameters.extra_env >> \
 | 
					
						
							|  |  |  |               CMAKE_ARGS="-DMLX_BUILD_CUDA=ON -DCMAKE_CUDA_COMPILER=`which nvcc`" \
 | 
					
						
							|  |  |  |               pip install ".[dev]" -v
 | 
					
						
							|  |  |  |             python setup.py generate_stubs
 | 
					
						
							|  |  |  |             << parameters.extra_env >> \
 | 
					
						
							|  |  |  |               CMAKE_ARGS="-DMLX_BUILD_CUDA=ON -DCMAKE_CUDA_COMPILER=`which nvcc`" \
 | 
					
						
							|  |  |  |               python -m build --wheel
 | 
					
						
							|  |  |  |             bash python/scripts/repair_cuda.sh
 | 
					
						
							|  |  |  |       - run:
 | 
					
						
							|  |  |  |           name: Upload package
 | 
					
						
							|  |  |  |           command: |
 | 
					
						
							|  |  |  |             source env/bin/activate
 | 
					
						
							|  |  |  |             twine upload wheelhouse/*.whl
 | 
					
						
							|  |  |  |       - store_artifacts:
 | 
					
						
							|  |  |  |           path: wheelhouse/
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  | workflows:
 | 
					
						
							|  |  |  |   build_and_test:
 | 
					
						
							|  |  |  |     when:
 | 
					
						
							|  |  |  |       and:
 | 
					
						
							| 
									
										
										
										
											2024-02-14 13:42:13 -08:00
										 |  |  |         - matches:
 | 
					
						
							|  |  |  |             pattern: "^(?!pull/)[-\\w]+$"
 | 
					
						
							|  |  |  |             value: << pipeline.git.branch >>
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |         - not: << pipeline.parameters.nightly_build >>
 | 
					
						
							|  |  |  |         - not: << pipeline.parameters.weekly_build >>
 | 
					
						
							| 
									
										
										
										
											2024-02-09 18:17:04 -08:00
										 |  |  |         - not: << pipeline.parameters.test_release >>
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |     jobs:
 | 
					
						
							| 
									
										
										
										
											2024-03-07 08:19:43 -08:00
										 |  |  |       - mac_build_and_test:
 | 
					
						
							|  |  |  |           matrix:
 | 
					
						
							|  |  |  |             parameters:
 | 
					
						
							| 
									
										
										
										
											2025-03-28 14:31:53 -07:00
										 |  |  |               macosx_deployment_target: ["13.5", "14.0"]
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |       - linux_build_and_test
 | 
					
						
							| 
									
										
										
										
											2025-06-10 21:19:47 -07:00
										 |  |  |       - cuda_build_and_test 
 | 
					
						
							| 
									
										
										
										
											2024-10-15 17:40:00 -07:00
										 |  |  |       - build_documentation 
 | 
					
						
							| 
									
										
										
										
											2024-02-22 14:09:13 -08:00
										 |  |  | 
 | 
					
						
							|  |  |  |   build_pypi_release:
 | 
					
						
							|  |  |  |     when:
 | 
					
						
							|  |  |  |       and:
 | 
					
						
							|  |  |  |         - not: << pipeline.parameters.nightly_build >>
 | 
					
						
							|  |  |  |         - not: << pipeline.parameters.weekly_build >>
 | 
					
						
							|  |  |  |         - not: << pipeline.parameters.test_release >>
 | 
					
						
							|  |  |  |     jobs:
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |       - build_release:
 | 
					
						
							|  |  |  |           filters:
 | 
					
						
							|  |  |  |             tags:
 | 
					
						
							|  |  |  |               only: /^v.*/
 | 
					
						
							|  |  |  |             branches:
 | 
					
						
							|  |  |  |               ignore: /.*/
 | 
					
						
							|  |  |  |           matrix:
 | 
					
						
							|  |  |  |             parameters:
 | 
					
						
							| 
									
										
										
										
											2024-11-01 20:55:35 -07:00
										 |  |  |               python_version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
 | 
					
						
							| 
									
										
										
										
											2025-03-28 14:31:53 -07:00
										 |  |  |               macosx_deployment_target: ["13.5", "14.0", "15.0"]
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |               build_env: ["PYPI_RELEASE=1"]
 | 
					
						
							| 
									
										
										
										
											2025-04-04 20:25:01 -07:00
										 |  |  |               xcode_version: ["16.2.0", "15.0.0"]
 | 
					
						
							|  |  |  |             exclude:
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "13.5"
 | 
					
						
							|  |  |  |                 xcode_version: "16.2.0"
 | 
					
						
							|  |  |  |                 python_version: "3.9"
 | 
					
						
							|  |  |  |                 build_env: "PYPI_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "13.5"
 | 
					
						
							|  |  |  |                 xcode_version: "16.2.0"
 | 
					
						
							|  |  |  |                 python_version: "3.10"
 | 
					
						
							|  |  |  |                 build_env: "PYPI_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "13.5"
 | 
					
						
							|  |  |  |                 xcode_version: "16.2.0"
 | 
					
						
							|  |  |  |                 python_version: "3.11"
 | 
					
						
							|  |  |  |                 build_env: "PYPI_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "13.5"
 | 
					
						
							|  |  |  |                 xcode_version: "16.2.0"
 | 
					
						
							|  |  |  |                 python_version: "3.12"
 | 
					
						
							|  |  |  |                 build_env: "PYPI_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "13.5"
 | 
					
						
							|  |  |  |                 xcode_version: "16.2.0"
 | 
					
						
							|  |  |  |                 python_version: "3.13"
 | 
					
						
							|  |  |  |                 build_env: "PYPI_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "14.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.9"
 | 
					
						
							|  |  |  |                 build_env: "PYPI_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "14.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.10"
 | 
					
						
							|  |  |  |                 build_env: "PYPI_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "14.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.11"
 | 
					
						
							|  |  |  |                 build_env: "PYPI_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "14.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.12"
 | 
					
						
							|  |  |  |                 build_env: "PYPI_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "14.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.13"
 | 
					
						
							|  |  |  |                 build_env: "PYPI_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "15.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.9"
 | 
					
						
							|  |  |  |                 build_env: "PYPI_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "15.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.10"
 | 
					
						
							|  |  |  |                 build_env: "PYPI_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "15.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.11"
 | 
					
						
							|  |  |  |                 build_env: "PYPI_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "15.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.12"
 | 
					
						
							|  |  |  |                 build_env: "PYPI_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "15.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.13"
 | 
					
						
							|  |  |  |                 build_env: "PYPI_RELEASE=1"
 | 
					
						
							| 
									
										
										
										
											2024-10-15 17:40:00 -07:00
										 |  |  |       - build_documentation:
 | 
					
						
							|  |  |  |           filters:
 | 
					
						
							|  |  |  |             tags:
 | 
					
						
							|  |  |  |               only: /^v.*/
 | 
					
						
							|  |  |  |             branches:
 | 
					
						
							|  |  |  |               ignore: /.*/
 | 
					
						
							|  |  |  |           upload-docs: true
 | 
					
						
							| 
									
										
										
										
											2025-07-07 09:29:23 -07:00
										 |  |  |       - build_linux_release:
 | 
					
						
							|  |  |  |           filters:
 | 
					
						
							|  |  |  |             tags:
 | 
					
						
							|  |  |  |               only: /^v.*/
 | 
					
						
							|  |  |  |             branches:
 | 
					
						
							|  |  |  |               ignore: /.*/
 | 
					
						
							|  |  |  |           matrix:
 | 
					
						
							|  |  |  |             parameters:
 | 
					
						
							|  |  |  |               python_version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
 | 
					
						
							|  |  |  |               extra_env: ["PYPI_RELEASE=1"]
 | 
					
						
							| 
									
										
										
										
											2024-10-15 17:40:00 -07:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2024-02-12 19:47:21 -06:00
										 |  |  |   prb:
 | 
					
						
							|  |  |  |     when:
 | 
					
						
							|  |  |  |       matches:
 | 
					
						
							|  |  |  |         pattern: "^pull/\\d+(/head)?$"
 | 
					
						
							|  |  |  |         value: << pipeline.git.branch >>
 | 
					
						
							|  |  |  |     jobs:
 | 
					
						
							|  |  |  |       - hold:
 | 
					
						
							|  |  |  |           type: approval
 | 
					
						
							| 
									
										
										
										
											2024-02-15 19:30:35 -06:00
										 |  |  |       - apple/authenticate:
 | 
					
						
							|  |  |  |           context: pr-approval
 | 
					
						
							| 
									
										
										
										
											2024-02-12 19:47:21 -06:00
										 |  |  |       - mac_build_and_test:
 | 
					
						
							|  |  |  |           requires: [ hold ]
 | 
					
						
							| 
									
										
										
										
											2024-03-12 05:14:44 +01:00
										 |  |  |           matrix:
 | 
					
						
							|  |  |  |             parameters:
 | 
					
						
							| 
									
										
										
										
											2025-03-28 14:31:53 -07:00
										 |  |  |               macosx_deployment_target: ["13.5", "14.0"]
 | 
					
						
							| 
									
										
										
										
											2024-02-12 19:47:21 -06:00
										 |  |  |       - linux_build_and_test:
 | 
					
						
							|  |  |  |           requires: [ hold ]
 | 
					
						
							| 
									
										
										
										
											2025-06-10 21:19:47 -07:00
										 |  |  |       - cuda_build_and_test:
 | 
					
						
							|  |  |  |           requires: [ hold ]
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |   nightly_build:
 | 
					
						
							| 
									
										
										
										
											2024-02-12 19:47:21 -06:00
										 |  |  |     when:
 | 
					
						
							|  |  |  |       and:
 | 
					
						
							|  |  |  |         - equal: [ main, << pipeline.git.branch >> ]
 | 
					
						
							|  |  |  |         - << pipeline.parameters.nightly_build >>
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |     jobs:
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |       - build_release:
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |           matrix:
 | 
					
						
							|  |  |  |             parameters:
 | 
					
						
							| 
									
										
										
										
											2024-11-01 20:55:35 -07:00
										 |  |  |               python_version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
 | 
					
						
							| 
									
										
										
										
											2025-03-28 14:31:53 -07:00
										 |  |  |               macosx_deployment_target: ["13.5", "14.0", "15.0"]
 | 
					
						
							| 
									
										
										
										
											2025-04-04 20:25:01 -07:00
										 |  |  |               xcode_version: ["16.2.0", "15.0.0"]
 | 
					
						
							|  |  |  |             exclude:
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "13.5"
 | 
					
						
							|  |  |  |                 xcode_version: "16.2.0"
 | 
					
						
							|  |  |  |                 python_version: "3.9"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "13.5"
 | 
					
						
							|  |  |  |                 xcode_version: "16.2.0"
 | 
					
						
							|  |  |  |                 python_version: "3.10"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "13.5"
 | 
					
						
							|  |  |  |                 xcode_version: "16.2.0"
 | 
					
						
							|  |  |  |                 python_version: "3.11"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "13.5"
 | 
					
						
							|  |  |  |                 xcode_version: "16.2.0"
 | 
					
						
							|  |  |  |                 python_version: "3.12"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "13.5"
 | 
					
						
							|  |  |  |                 xcode_version: "16.2.0"
 | 
					
						
							|  |  |  |                 python_version: "3.13"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "14.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.9"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "14.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.10"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "14.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.11"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "14.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.12"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "14.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.13"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "15.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.9"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "15.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.10"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "15.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.11"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "15.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.12"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "15.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.13"
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |   weekly_build:
 | 
					
						
							| 
									
										
										
										
											2024-02-12 19:47:21 -06:00
										 |  |  |     when:
 | 
					
						
							|  |  |  |       and:
 | 
					
						
							|  |  |  |         - equal: [ main, << pipeline.git.branch >> ]
 | 
					
						
							|  |  |  |         - << pipeline.parameters.weekly_build >>
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |     jobs:
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |       - build_release:
 | 
					
						
							| 
									
										
										
										
											2023-12-04 16:04:11 -08:00
										 |  |  |           matrix:
 | 
					
						
							|  |  |  |             parameters:
 | 
					
						
							| 
									
										
										
										
											2024-11-01 20:55:35 -07:00
										 |  |  |               python_version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
 | 
					
						
							| 
									
										
										
										
											2025-03-28 14:31:53 -07:00
										 |  |  |               macosx_deployment_target: ["13.5", "14.0", "15.0"]
 | 
					
						
							| 
									
										
										
										
											2024-02-07 06:04:34 -08:00
										 |  |  |               build_env: ["DEV_RELEASE=1"]
 | 
					
						
							| 
									
										
										
										
											2025-04-04 20:25:01 -07:00
										 |  |  |               xcode_version: ["16.2.0", "15.0.0"]
 | 
					
						
							|  |  |  |             exclude:
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "13.5"
 | 
					
						
							|  |  |  |                 xcode_version: "16.2.0"
 | 
					
						
							|  |  |  |                 python_version: "3.9"
 | 
					
						
							|  |  |  |                 build_env: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "13.5"
 | 
					
						
							|  |  |  |                 xcode_version: "16.2.0"
 | 
					
						
							|  |  |  |                 python_version: "3.10"
 | 
					
						
							|  |  |  |                 build_env: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "13.5"
 | 
					
						
							|  |  |  |                 xcode_version: "16.2.0"
 | 
					
						
							|  |  |  |                 python_version: "3.11"
 | 
					
						
							|  |  |  |                 build_env: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "13.5"
 | 
					
						
							|  |  |  |                 xcode_version: "16.2.0"
 | 
					
						
							|  |  |  |                 python_version: "3.12"
 | 
					
						
							|  |  |  |                 build_env: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "13.5"
 | 
					
						
							|  |  |  |                 xcode_version: "16.2.0"
 | 
					
						
							|  |  |  |                 python_version: "3.13"
 | 
					
						
							|  |  |  |                 build_env: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "14.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.9"
 | 
					
						
							|  |  |  |                 build_env: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "14.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.10"
 | 
					
						
							|  |  |  |                 build_env: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "14.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.11"
 | 
					
						
							|  |  |  |                 build_env: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "14.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.12"
 | 
					
						
							|  |  |  |                 build_env: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "14.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.13"
 | 
					
						
							|  |  |  |                 build_env: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "15.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.9"
 | 
					
						
							|  |  |  |                 build_env: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "15.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.10"
 | 
					
						
							|  |  |  |                 build_env: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "15.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.11"
 | 
					
						
							|  |  |  |                 build_env: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "15.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.12"
 | 
					
						
							|  |  |  |                 build_env: "DEV_RELEASE=1"
 | 
					
						
							|  |  |  |               - macosx_deployment_target: "15.0"
 | 
					
						
							|  |  |  |                 xcode_version: "15.0.0"
 | 
					
						
							|  |  |  |                 python_version: "3.13"
 | 
					
						
							|  |  |  |                 build_env: "DEV_RELEASE=1"
 | 
					
						
							| 
									
										
										
										
											2024-02-09 18:17:04 -08:00
										 |  |  |   linux_test_release:
 | 
					
						
							| 
									
										
										
										
											2024-02-12 19:47:21 -06:00
										 |  |  |     when:
 | 
					
						
							|  |  |  |       and:
 | 
					
						
							|  |  |  |         - equal: [ main, << pipeline.git.branch >> ]
 | 
					
						
							| 
									
										
										
										
											2024-10-14 06:21:44 -07:00
										 |  |  |         - << pipeline.parameters.linux_release >>
 | 
					
						
							| 
									
										
										
										
											2024-02-09 18:17:04 -08:00
										 |  |  |     jobs:
 | 
					
						
							| 
									
										
										
										
											2024-10-14 06:21:44 -07:00
										 |  |  |       - build_linux_release:
 | 
					
						
							| 
									
										
										
										
											2024-02-09 18:17:04 -08:00
										 |  |  |           matrix:
 | 
					
						
							|  |  |  |             parameters:
 | 
					
						
							| 
									
										
										
										
											2024-11-01 20:55:35 -07:00
										 |  |  |               python_version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
 | 
					
						
							| 
									
										
										
										
											2024-02-09 18:17:04 -08:00
										 |  |  |               extra_env: ["PYPI_RELEASE=1"]
 | 
					
						
							| 
									
										
										
										
											2025-06-19 15:26:36 -07:00
										 |  |  |   cuda_test_release:
 | 
					
						
							|  |  |  |     when:
 | 
					
						
							|  |  |  |       and:
 | 
					
						
							|  |  |  |         - equal: [ main, << pipeline.git.branch >> ]
 | 
					
						
							|  |  |  |         - << pipeline.parameters.cuda_release >>
 | 
					
						
							|  |  |  |     jobs:
 | 
					
						
							|  |  |  |       - build_cuda_release:
 | 
					
						
							|  |  |  |           matrix:
 | 
					
						
							|  |  |  |             parameters:
 | 
					
						
							|  |  |  |               python_version: ["3.9", "3.10", "3.11", "3.12", "3.13"]
 | 
					
						
							|  |  |  |               extra_env: ["PYPI_RELEASE=1"]
 |