Skip to content

Commit

Permalink
Merge branch 'main' into choleskysolvePaddleTensor
Browse files Browse the repository at this point in the history
  • Loading branch information
Ishticode authored Mar 3, 2024
2 parents a9c3077 + 6625044 commit bfde3bd
Show file tree
Hide file tree
Showing 713 changed files with 32,420 additions and 19,808 deletions.
61 changes: 61 additions & 0 deletions .devcontainer/build_apple_silicon/devcontainer.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
// For format details, see https://aka.ms/devcontainer.json. For config options, see the README at:
// https://github.com/microsoft/vscode-dev-containers/tree/v0.236.0/containers/docker-existing-dockerfile
{
"name": "Ivy Apple Silicon Development Environment (build)",

"build": {
"dockerfile": "../../docker/DockerfileAppleSilicon",
"context": "../..",
"args": {
"pycon": ["3.10"]
}
},

"customizations": {
"vscode": {
"extensions": [
"ms-python.python"
],
"settings": {
"python.defaultInterpreterPath": "/opt/miniconda/envs/multienv/bin/python3"
}
}
},

"postCreateCommand": {
"post_create": "bash .devcontainer/post_create_commands.sh",
"bashrc": "echo \"alias python=python3\" >> ~/.bashrc"
},

// Use 'forwardPorts' to make a list of ports inside the container available locally.
// "forwardPorts": [],

// Uncomment the next line to run commands after the container is created - for example installing curl.

// Uncomment when using a ptrace-based debugger like C++, Go, and Rust
// "runArgs": [ "--cap-add=SYS_PTRACE", "--security-opt", "seccomp=unconfined" ],

// Uncomment to use the Docker CLI from inside the container. See https://aka.ms/vscode-remote/samples/docker-from-docker.
// "mounts": [ "source=/var/run/docker.sock,target=/var/run/docker.sock,type=bind" ],

// Uncomment to connect as a non-root user if you've added one. See https://aka.ms/vscode-remote/containers/non-root.
// "remoteUser": "vscode",
"features": {
"ghcr.io/devcontainers/features/common-utils:2": {
"installZsh": true,
"configureZshAsDefaultShell": true,
"installOhMyZsh": true,
"upgradePackages": false
},
"ghcr.io/devcontainers/features/docker-outside-of-docker:1": {
"moby": true,
"installDockerBuildx": true,
"version": "20.10",
"dockerDashComposeVersion": "v2"
},
"ghcr.io/devcontainers/features/github-cli:1": {
"installDirectlyFromGitHubRelease": true,
"version": "latest"
}
}
}
6 changes: 3 additions & 3 deletions .devcontainer/build_gpu/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,11 @@
"name": "Ivy GPU Development Environment (build)",

"build": {
"dockerfile": "../../docker/DockerfileGPUMultiCuda",
"dockerfile": "../../docker/DockerfileGPU",
"context": "../..",
"args": {
"IMAGE_NAME": "unifyai/multicuda",
"IMAGE_TAG": "base_and_requirements"
"IMAGE_NAME": "unifyai/ivy",
"IMAGE_TAG": "latest-gpu"
}
},

Expand Down
2 changes: 1 addition & 1 deletion .devcontainer/image_gpu/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "Ivy GPU Development Environment (image)",

"image": "unifyai/multicuda:base_and_requirements",
"image": "unifyai/ivy:latest-gpu",
"customizations": {
"vscode": {
"extensions": [
Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/sub-task.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
name: 🍰 Sub-Task
about: Reserve a sub-task from a ToDo list issue
title: "<Function_Name>"
labels: Sub Task, hacktoberfest
labels: Sub Task
assignees: ''

---
8 changes: 6 additions & 2 deletions .github/workflows/array-api-det-coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,10 @@ permissions:
jobs:
determine_coverage:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
branch: [ 1, 2, 3, 4 ]
steps:
- name: Checkout Ivy 🛎
uses: actions/checkout@v2
Expand All @@ -22,7 +26,7 @@ jobs:
run: |
pip install pydriller tqdm
cd ivy
python scripts/determine_tests/array_api_det_coverage.py
python scripts/determine_tests/array_api_det_coverage.py ${{ matrix.branch }}
cd ..
mkdir tests
cp ivy/tests.pbz2 tests/
Expand All @@ -37,4 +41,4 @@ jobs:
destination-repository-name: 'Mapping'
user-email: [email protected]
commit-message: Update Array API Tests Mapping
target-branch: main
target-branch: main${{ matrix.branch }}
67 changes: 57 additions & 10 deletions .github/workflows/array-api-intelligent-tests-pr.yml
Original file line number Diff line number Diff line change
@@ -1,37 +1,84 @@
name: array-api-intelligent-tests-pr
on:
pull_request:
types: [ labeled, opened, synchronize, reopened, review_requested ]
types: [opened, synchronize, reopened, review_requested ]

permissions:
actions: read

jobs:
display_test_results:
if: ${{ always() }}
runs-on: ubuntu-latest
needs:
- run_tests

steps:
- name: Download all test results
uses: actions/download-artifact@v3

- name: Combined Test Results
run: |
find . -name "test_results_*.txt" -exec cat {} + > combined_test_results.txt
echo "Test results summary:"
cat combined_test_results.txt
- name: New Failures Introduced
run: |
find . -name "new_failures_*.txt" -exec cat {} + > combined_failures.txt
if [ -s combined_failures.txt ]
then
echo "This PR introduces the following new failing tests:"
cat combined_failures.txt
else
echo "This PR does not introduce any new test failures! Yippee!"
fi
run_tests:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
branch: [ 1, 2, 3, 4 ]

steps:
- name: Checkout Ivy 🛎
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
path: ivy
persist-credentials: false
submodules: "recursive"
fetch-depth: 100

- name: Determine Tests
- name: Get Job URL
uses: Tiryoh/gha-jobid-action@v0
id: jobs
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
job_name: ${{ github.job }}

- name: Determine and Run Tests
run: |
git clone -b main https://github.com/unifyai/Mapping.git --depth 1
git clone -b main${{ matrix.branch }} https://github.com/unifyai/Mapping.git --depth 1
pip install pydriller
cp Mapping/tests.pbz2 ivy/
cd ivy
python scripts/determine_tests/array_api_determine_tests.py
python scripts/run_tests/array_api_run_tests_pr.py new_failures_${{ matrix.branch }}.txt | tee test_results_${{ matrix.branch }}.txt
cd ..
continue-on-error: true

- name: Run Tests
id: tests
run: |
cd ivy
python scripts/run_tests/array_api_run_tests_pr.py
continue-on-error: true
- name: Upload test results
uses: actions/upload-artifact@v3
with:
name: test_results_${{ matrix.branch }}
path: ivy/test_results_${{ matrix.branch }}.txt

- name: Upload New Failures
uses: actions/upload-artifact@v3
with:
name: new_failures_${{ matrix.branch }}
path: ivy/new_failures_${{ matrix.branch }}.txt

- name: Check on failures
if: steps.tests.outcome != 'success'
Expand Down
38 changes: 33 additions & 5 deletions .github/workflows/array-api-intelligent-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,32 @@ on:
permissions:
actions: read
jobs:
display_test_results:
if: ${{ always() }}
runs-on: ubuntu-latest
needs:
- run_tests

steps:
- name: Download all test results
uses: actions/download-artifact@v3

- name: Combined Test Results
run: |
find . -name "test_results_*.txt" -exec cat {} + > combined_test_results.txt
echo "Test results summary:"
cat combined_test_results.txt
run_tests:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
branch: [ 1, 2, 3, 4 ]

steps:
- name: Checkout Ivy 🛎
uses: actions/checkout@v2
uses: actions/checkout@v3
with:
path: ivy
persist-credentials: false
Expand All @@ -29,26 +50,33 @@ jobs:
env:
SSH_DEPLOY_KEY: ${{ secrets.SSH_DEPLOY_KEY }}
run: |
source ./ivy/scripts/shell/clone_mapping.sh main
source ./ivy/scripts/shell/clone_mapping.sh main${{ matrix.branch }}
pip install pydriller pymongo
cp Mapping/tests.pbz2 ivy/
cd ivy
python scripts/determine_tests/array_api_determine_tests.py
python scripts/determine_tests/array_api_determine_tests.py ${{ matrix.branch }}
cd ..
cp ivy/tests.pbz2 Mapping/
cd Mapping
git add .
git commit -m "Update Mapping"
git push origin main
git push origin main${{ matrix.branch }}
continue-on-error: true

- name: Run Tests
id: tests
run: |
cd ivy
python scripts/run_tests/array_api_run_tests.py ${{ secrets.REDIS_CONNECTION_URL }} ${{ secrets.REDIS_PASSWORD }} ${{ secrets.MONGODB_PASSWORD }} ${{ github.run_id }} ${{ steps.jobs.outputs.html_url }}
set -o pipefail
python scripts/run_tests/array_api_run_tests.py ${{ secrets.REDIS_CONNECTION_URL }} ${{ secrets.REDIS_PASSWORD }} ${{ secrets.MONGODB_PASSWORD }} ${{ github.run_id }} ${{ steps.jobs.outputs.html_url }} | tee test_results_${{ matrix.branch }}.txt
continue-on-error: true

- name: Upload test results
uses: actions/upload-artifact@v3
with:
name: test_results_${{ matrix.branch }}
path: ivy/test_results_${{ matrix.branch }}.txt

- name: Check on failures
if: steps.tests.outcome != 'success'
run: exit 1
4 changes: 2 additions & 2 deletions .github/workflows/binaries.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Checkout 🛎️Binaries
uses: actions/checkout@v2
uses: actions/checkout@v4
with:
repository: unifyai/binaries
token: ${{ secrets.IVY_BRANCH_TOKEN }}
path: binaries
persist-credentials: false

- name: Add Tag to Binaries
run: |
Expand Down
26 changes: 26 additions & 0 deletions .github/workflows/dockerfile-gpu-push.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: GPU Dockerfile Push

on:
schedule:
- cron: '0 0 * * *'
workflow_dispatch:

jobs:

build:
runs-on: ubuntu-latest-4-cores

steps:
- name: Checkout 🛎 Ivy
uses: actions/checkout@v3

- name: Login to Docker Hub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push GPU image
run: |
docker build --progress=plain --no-cache -t unifyai/ivy:latest-gpu -f docker/DockerfileGPU .
docker push unifyai/ivy:latest-gpu
4 changes: 2 additions & 2 deletions .github/workflows/dockerfile-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,14 +4,14 @@ on:
push:
branches: [ "main" ]
pull_request:
types: [labeled, review_requested]
types: [review_requested]
branches: [ "main" ]

jobs:

build:
if: ${{(github.event_name == 'push') || contains(github.event.pull_request.labels.*.name, 'Exhaustive CI') || contains(github.event.pull_request.labels.*.name, 'Build Docker Files')}}
runs-on: ubuntu-20.04
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
Expand Down
31 changes: 0 additions & 31 deletions .github/workflows/dockerfile-multicuda-push.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .github/workflows/dockerfile-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:

build:

runs-on: ubuntu-20.04
runs-on: ubuntu-latest

steps:
-
Expand Down
Loading

0 comments on commit bfde3bd

Please sign in to comment.