diff --git a/.devcontainer/build_gpu/devcontainer.json b/.devcontainer/build_gpu/devcontainer.json index 399fc8cf8d1b5..b74cb231c4a78 100644 --- a/.devcontainer/build_gpu/devcontainer.json +++ b/.devcontainer/build_gpu/devcontainer.json @@ -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" } }, diff --git a/.devcontainer/image_gpu/devcontainer.json b/.devcontainer/image_gpu/devcontainer.json index 6824d7ca80037..ca899e132de7b 100644 --- a/.devcontainer/image_gpu/devcontainer.json +++ b/.devcontainer/image_gpu/devcontainer.json @@ -1,7 +1,7 @@ { "name": "Ivy GPU Development Environment (image)", - "image": "unifyai/multicuda:base_and_requirements", + "image": "unifyai/ivy:latest-gpu", "customizations": { "vscode": { "extensions": [ diff --git a/.github/workflows/dockerfile-gpu-push.yml b/.github/workflows/dockerfile-gpu-push.yml new file mode 100644 index 0000000000000..df978d2ee95a9 --- /dev/null +++ b/.github/workflows/dockerfile-gpu-push.yml @@ -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 diff --git a/.github/workflows/dockerfile-multicuda-push.yml b/.github/workflows/dockerfile-multicuda-push.yml deleted file mode 100644 index 1ace6afdc4b36..0000000000000 --- a/.github/workflows/dockerfile-multicuda-push.yml +++ /dev/null @@ -1,31 +0,0 @@ -name: Dockerfile MultiCUDA 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 base image - run: | - docker build --progress=plain --no-cache -t unifyai/multicuda:base -f docker/DockerfileGPUMultiCuda-base . - docker push unifyai/multicuda:base - - - name: Build and push base_and_requirements image - run: | - docker build --progress=plain --no-cache -t unifyai/multicuda:base_and_requirements -f docker/DockerfileGPUMultiCuda . - docker push unifyai/multicuda:base_and_requirements diff --git a/.github/workflows/intelligent-tests-pr.yml b/.github/workflows/intelligent-tests-pr.yml index 9f3137fd4463c..54a72ca61d903 100644 --- a/.github/workflows/intelligent-tests-pr.yml +++ b/.github/workflows/intelligent-tests-pr.yml @@ -1,12 +1,10 @@ name: intelligent-tests-pr on: workflow_dispatch: - pull_request_target: - types: [labeled, opened, synchronize, reopened, review_requested] + pull_request: permissions: actions: read - pull-requests: write jobs: display_test_results: @@ -26,47 +24,18 @@ jobs: cat combined_test_results.txt - name: New Failures Introduced - id: ci_output 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 - { - echo 'MESSAGE<> "$GITHUB_OUTPUT" else - echo "MESSAGE=This pull request does not result in any additional test failures. Congratulations!" >> "$GITHUB_OUTPUT" + echo "This PR does not introduce any new test failures! Yippee!" fi - - name: Find Comment - uses: peter-evans/find-comment@v2 - id: fc - with: - issue-number: ${{ github.event.pull_request.number }} - comment-author: 'github-actions[bot]' - body-includes: - - - name: Create or update comment - uses: peter-evans/create-or-update-comment@v3 - with: - comment-id: ${{ steps.fc.outputs.comment-id }} - issue-number: ${{ github.event.pull_request.number }} - body: | - Thank you for this PR, here is the CI results: - - ------------- - ${{ steps.ci_output.outputs.MESSAGE}} - - - edit-mode: replace run_tests: - runs-on: ubuntu-latest + runs-on: ubuntu-20.04 strategy: fail-fast: false matrix: @@ -93,20 +62,34 @@ jobs: submodules: "recursive" fetch-depth: 100 + - name: Install ivy and fetch binaries + run: | + cd ivy + pip3 install -e . + mkdir .ivy + touch .ivy/key.pem + echo -n ${{ secrets.USER_API_KEY }} > .ivy/key.pem + cd .. + + - 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 id: tests run: | - git clone -b master${{ matrix.branch }} https://github.com/unifyai/Mapping.git --depth 200 + git clone -b master${{ matrix.branch }} https://github.com/unifyai/Mapping.git --depth 1 pip install pydriller GitPython python ivy/scripts/setup_tests/clone-mapping.py cp Mapping/tests.pbz2 ivy/ cd ivy - mkdir .ivy - touch .ivy/key.pem - echo -n ${{ secrets.USER_API_KEY }} > .ivy/key.pem python scripts/determine_tests/determine_tests.py ${{ matrix.branch }} pr set -o pipefail python scripts/run_tests/run_tests_pr.py new_failures_${{ matrix.branch }}.txt | tee test_results_${{ matrix.branch }}.txt + cd .. continue-on-error: true - name: Upload test results diff --git a/docker/DockerfileGPUMultiCuda b/docker/DockerfileGPU similarity index 75% rename from docker/DockerfileGPUMultiCuda rename to docker/DockerfileGPU index 46ea25929c4a5..5eca7bab1a6cc 100644 --- a/docker/DockerfileGPUMultiCuda +++ b/docker/DockerfileGPU @@ -1,16 +1,32 @@ -# uses the base image which has cuda and cudnn installed(multiple versions) and then installs the +# installs multiple versions of cuda and cudnn and then installs the # latest frameworks and the requirements -FROM unifyai/multicuda:base +FROM debian:buster WORKDIR /ivy -ARG fw +# arguments +ARG fw ARG pycon=3.10 +# environment variables ENV DEBIAN_FRONTEND=noninteractive - -# Install miniconda +ENV TZ=Europe/Moscow ENV CONDA_DIR /opt/miniconda/ + +# install base libraries +RUN grep security /etc/apt/sources.list | tee /etc/apt/security.sources.list && \ + apt-get update && \ + apt-get upgrade -o Dir::Etc::SourceList=/etc/apt/security.sources.list -y &&\ + apt-get -y update && \ + apt-get install -y gnupg \ + curl \ + wget \ + software-properties-common \ + gcc \ + nano + + +# install miniconda RUN apt clean && \ rm -rf /var/lib/apt/lists/* && \ apt-get update && \ @@ -21,10 +37,12 @@ RUN apt clean && \ /bin/bash ~/miniconda.sh -b -p /opt/miniconda +# create conda environment ENV PATH=$CONDA_DIR/bin:$PATH RUN conda create --name multienv python==$pycon -y -# to fix protobuf conflicts + +# fix protobuf conflicts ENV PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION python ENV PATH=/opt/miniconda/envs/multienv/bin:$PATH RUN apt-get update && \ @@ -38,44 +56,42 @@ RUN apt-get update && \ pip3 install setuptools==58.5.3 -# Install Ivy Upstream +# install Ivy Upstream RUN git clone --progress --recurse-submodules https://github.com/unifyai/ivy --depth 1 && \ cd ivy && \ cd ivy_tests/array_api_testing/test_array_api && \ pip3 install --no-cache-dir -r requirements.txt -# Install local optional -COPY /docker/multicuda_framework_directory.py . + +# copy library files to workdir +COPY docker/gpu_framework_directory.py . COPY requirements/optional_gpu.txt . COPY requirements/requirements.txt . -#setting torch path early on because torch-scatter needs it +# setting torch path early on because torch-scatter needs it ENV PYTHONPATH "/opt/fw/torch:/opt/miniconda/envs/multienv/bin" + # requirement mappings directs which dependency to be installed and where COPY /docker/requirement_mappings_gpu.json . SHELL ["/bin/bash", "-c"] - -RUN python3 multicuda_framework_directory.py $fw &&\ +# install all libraries based on the mappings +RUN python3 gpu_framework_directory.py $fw &&\ jq -r 'to_entries[] | select(.value != [""]) | .key as $dir | .value[] | @sh "/opt/fw/\($dir) \(.)"' requirement_mappings_gpu.json | xargs -I {} sh -c 'printf "Installing %s\n" $2 && pip install --ignore-installed --target $1 $2 --extra-index-url https://download.pytorch.org/whl/cu118' sh {} - - - RUN sed -i '/numpy/d' requirements.txt &&\ pip install -r requirements.txt &&\ cp ./optional_gpu.txt tmp.txt &&\ jq -r 'to_entries[] | [.key] + .value | select(length > 0 or (. == "")) | .[]' requirement_mappings_gpu.json | sort -u | xargs -I {} sed -i '/{}/d;/jaxlib/d' tmp.txt && pip install -r tmp.txt - - # add all the directories to environment path so that python knows where to find them ENV PYTHONPATH "/opt/fw/mxnet:/opt/fw/numpy:/opt/fw/tensorflow:/opt/fw/jax:/opt/fw/torch:/opt/fw/paddle:/opt/miniconda/envs/multienv/bin" +# test dependencies COPY scripts/test_dependencies.py . RUN python3 test_dependencies.py -fp requirements.txt,optional_gpu.txt && \ rm -rf requirements.txt && \ diff --git a/docker/DockerfileGPUMultiCuda-base b/docker/DockerfileGPUMultiCuda-base deleted file mode 100644 index fa8c4c9895f53..0000000000000 --- a/docker/DockerfileGPUMultiCuda-base +++ /dev/null @@ -1,20 +0,0 @@ -# is used to create a base image where we then manually install cuda and cudnn -FROM debian:buster -WORKDIR /ivy - - -COPY ../docker/multicuda_framework_directory.py . -COPY ../docker/multicuda_requirements.txt . - -ENV DEBIAN_FRONTEND=noninteractive -ENV TZ=Europe/Moscow -RUN grep security /etc/apt/sources.list | tee /etc/apt/security.sources.list && \ - apt-get update && \ - apt-get upgrade -o Dir::Etc::SourceList=/etc/apt/security.sources.list -y &&\ - apt-get -y update && \ - apt-get install -y gnupg \ - curl \ - wget \ - software-properties-common \ - gcc \ - nano diff --git a/docker/build_DockerfileGPUMultiCuda.sh b/docker/build_DockerfileGPUMultiCuda.sh deleted file mode 100644 index f9e0ff9da5d9f..0000000000000 --- a/docker/build_DockerfileGPUMultiCuda.sh +++ /dev/null @@ -1 +0,0 @@ -docker build --progress=plain --no-cache -t unifyai/multicuda:base_and_requirements -f DockerfileGPUMultiCuda .. diff --git a/docker/build_gpu_dockerfile.sh b/docker/build_gpu_dockerfile.sh new file mode 100644 index 0000000000000..ec946c8b97e89 --- /dev/null +++ b/docker/build_gpu_dockerfile.sh @@ -0,0 +1 @@ +docker build --progress=plain --no-cache -t unifyai/ivy:latest-gpu -f DockerfileGPU .. diff --git a/docker/multicuda_framework_directory.py b/docker/gpu_framework_directory.py similarity index 100% rename from docker/multicuda_framework_directory.py rename to docker/gpu_framework_directory.py diff --git a/docker/rebuild_all_dockerfiles.sh b/docker/rebuild_all_dockerfiles.sh index 7af9cb5c2170e..386faff74fae5 100755 --- a/docker/rebuild_all_dockerfiles.sh +++ b/docker/rebuild_all_dockerfiles.sh @@ -1,4 +1,4 @@ #!/bin/bash docker build -t unifyai/ivy:latest --no-cache -f Dockerfile .. -docker build -t unifyai/multicuda:base_and_requirements --no-cache -f DockerfileGPUMultiCuda .. +docker build -t unifyai/ivy:latest-gpu --no-cache -f DockerfileGPU .. diff --git a/docs/overview/contributing/setting_up.rst b/docs/overview/contributing/setting_up.rst index 0a541c646a24d..0b6c0535dbc93 100644 --- a/docs/overview/contributing/setting_up.rst +++ b/docs/overview/contributing/setting_up.rst @@ -715,7 +715,7 @@ Just follow the steps outlined below: - :code:`Default project configuration` - This is the default option, it will set up with the default codespaces environment. - :code:`Ivy Development Environment (build)` - This will set up the development environment of ivy for CPU and build image from :code:`ivy/docker/Dockerfile`. - - :code:`Ivy GPU Development Environment (build)` - This will set up the development environment of ivy for GPU and build image from :code:`ivy/docker/DockerfileGPUMultiCuda`. + - :code:`Ivy GPU Development Environment (build)` - This will set up the development environment of ivy for GPU and build image from :code:`ivy/docker/DockerfileGPU`. - :code:`Ivv Development Environment for Multiver...` - This will set up the development environment of multiversion support with ivy and build image from :code:`ivy/docker/DockerfileMultiversion`. - :code:`Ivy Development Environment (image)` - This will set up the development environment of ivy for CPU and build image from the latest image from dockerhub. - :code:`Ivy GPU Development Environment (image)` - This will set up the development environment of ivy for GPU and build image from the latest image from dockerhub. diff --git a/ivy/functional/backends/jax/experimental/layers.py b/ivy/functional/backends/jax/experimental/layers.py index 122598cd4cfb3..b21543463cf02 100644 --- a/ivy/functional/backends/jax/experimental/layers.py +++ b/ivy/functional/backends/jax/experimental/layers.py @@ -149,7 +149,7 @@ def general_pool( # if dtype is not set here, jax casts it to float64 inputs = jnp.array(inputs, dtype=jnp.float32) if not ivy.is_array(init): - init = jnp.array(init, dtype=jnp.float32) + init = jnp.array(init, dtype=inputs.dtype) promoted_type = jnp.promote_types(inputs.dtype, init.dtype) inputs = inputs.astype(promoted_type) init = init.astype(promoted_type) @@ -703,7 +703,7 @@ def interpolate( out: Optional[JaxArray] = None, ): dims = len(x.shape) - 2 - size = _get_size(scale_factor, size, dims, x.shape) + size, _ = _get_size(scale_factor, size, dims, x.shape) mode = ( "nearest" if mode == "nearest-exact" diff --git a/ivy/functional/backends/tensorflow/experimental/layers.py b/ivy/functional/backends/tensorflow/experimental/layers.py index 00bd0e8fed60c..71afe3b9a3347 100644 --- a/ivy/functional/backends/tensorflow/experimental/layers.py +++ b/ivy/functional/backends/tensorflow/experimental/layers.py @@ -893,7 +893,7 @@ def interpolate( out: Optional[Union[tf.Tensor, tf.Variable]] = None, ): dims = len(x.shape) - 2 - size = _get_size(scale_factor, size, dims, x.shape) + size, _ = _get_size(scale_factor, size, dims, x.shape) remove_dim = False if mode in ["linear", "tf_area", "lanczos3", "lanczos5", "nearest-exact"]: if dims == 1: diff --git a/ivy/functional/frontends/torch/nn/functional/pooling_functions.py b/ivy/functional/frontends/torch/nn/functional/pooling_functions.py index 040b005b68131..75454ec07d2aa 100644 --- a/ivy/functional/frontends/torch/nn/functional/pooling_functions.py +++ b/ivy/functional/frontends/torch/nn/functional/pooling_functions.py @@ -114,6 +114,10 @@ def avg_pool1d( ) +@with_unsupported_dtypes( + {"2.1.0 and below": ("float16",)}, + "torch", +) @to_ivy_arrays_and_back def avg_pool2d( input, diff --git a/ivy/functional/frontends/torch/reduction_ops.py b/ivy/functional/frontends/torch/reduction_ops.py index ea414e1e233a0..6e9aca464b8ed 100644 --- a/ivy/functional/frontends/torch/reduction_ops.py +++ b/ivy/functional/frontends/torch/reduction_ops.py @@ -162,6 +162,10 @@ def median(input, dim=None, keepdim=False, *, out=None): @numpy_to_torch_style_args @to_ivy_arrays_and_back +@with_unsupported_dtypes( + {"2.1.0 and below": ("complex64", "complex128")}, + "torch", +) def min(*input, dim=None, keepdim=False, out=None): if len(input) == 1: input = input[0] diff --git a/ivy/functional/ivy/experimental/layers.py b/ivy/functional/ivy/experimental/layers.py index 2b8a3e9102014..e8b801edd2b01 100644 --- a/ivy/functional/ivy/experimental/layers.py +++ b/ivy/functional/ivy/experimental/layers.py @@ -1849,21 +1849,11 @@ def interpolate( """ input_shape = ivy.shape(x) dims = len(input_shape) - 2 - size = _get_size(scale_factor, size, dims, x.shape) + size, scale_factor = _get_size(scale_factor, size, dims, x.shape) if recompute_scale_factor: - scale_factor = None - elif scale_factor is not None: - scale_factor = ( - [scale_factor] * dims - if isinstance(scale_factor, (int, float)) - else scale_factor - ) - scale_factor = ( - [scale_factor[0]] * dims - if isinstance(scale_factor, (list, tuple)) and len(scale_factor) != dims - else scale_factor - ) - scale = [ivy.divide(size[i], input_shape[i + 2]) for i in range(dims)] + scale = [ivy.divide(size[i], input_shape[i + 2]) for i in range(dims)] + else: + scale = [1] * dims if mode in [ "linear", "bilinear", @@ -1996,7 +1986,7 @@ def _get_size(scale_factor, size, dims, x_shape): ) else: size = (size,) * dims if isinstance(size, int) else tuple(size) - return size + return size, scale_factor def _output_ceil_shape(w, f, p, s): diff --git a/ivy_tests/test_ivy/helpers/hypothesis_helpers/array_helpers.py b/ivy_tests/test_ivy/helpers/hypothesis_helpers/array_helpers.py index 0c639012590e8..51a5dbcf99f8a 100644 --- a/ivy_tests/test_ivy/helpers/hypothesis_helpers/array_helpers.py +++ b/ivy_tests/test_ivy/helpers/hypothesis_helpers/array_helpers.py @@ -1790,22 +1790,18 @@ def arrays_for_pooling( ) if array_dim == 3: kernel = draw(st.tuples(st.integers(1, in_shape[1]))) - new_kernel = kernel if return_dilation: - new_kernel = [] dilations = [] for i in range(len(kernel)): if kernel[i] > 1: max_dilation = (in_shape[i + 1] - kernel[i]) // (kernel[i] - 1) + 1 dilations.append(draw(st.integers(1, max_dilation))) - new_kernel.append(kernel[i] + (kernel[i] - 1) * (dilations[i] - 1)) else: dilations.append(1) - new_kernel.append(kernel[i]) if explicit_or_str_padding or only_explicit_padding: padding = [] for i in range(array_dim - 2): - max_pad = new_kernel[i] // 2 + max_pad = kernel[i] // 2 padding.append( draw( st.tuples( diff --git a/ivy_tests/test_ivy/test_functional/test_experimental/test_nn/test_layers.py b/ivy_tests/test_ivy/test_functional/test_experimental/test_nn/test_layers.py index 81eec1e5f3bf0..6349d46273437 100644 --- a/ivy_tests/test_ivy/test_functional/test_experimental/test_nn/test_layers.py +++ b/ivy_tests/test_ivy/test_functional/test_experimental/test_nn/test_layers.py @@ -131,33 +131,25 @@ def _interp_args(draw, mode=None, mode_list=None): ) ) if draw(st.booleans()): - scale_factor = draw( - st.one_of( - helpers.lists( - x=helpers.floats( - min_value=1.0, max_value=2.0, mixed_fn_compos=mixed_fn_compos - ), - min_size=num_dims - 2, - max_size=num_dims - 2, - ), - helpers.floats( - min_value=1.0, max_value=2.0, mixed_fn_compos=mixed_fn_compos - ), + if draw(st.booleans()): + scale_factor = draw( + st.floats(min_value=max([1 / d for d in x[0].shape[2:]]), max_value=3) ) - ) + else: + scale_factor = [] + for s in x[0].shape[2:]: + scale_factor += [draw(st.floats(min_value=1 / s, max_value=3))] recompute_scale_factor = draw(st.booleans()) size = None else: size = draw( st.one_of( - helpers.lists( - x=helpers.ints( - min_value=1, max_value=3, mixed_fn_compos=mixed_fn_compos - ), + st.lists( + st.integers(min_value=1, max_value=3 * max(x[0].shape)), min_size=num_dims - 2, max_size=num_dims - 2, ), - st.integers(min_value=1, max_value=3), + st.integers(min_value=1, max_value=3 * max(x[0].shape)), ) ) recompute_scale_factor = False diff --git a/scripts/run_tests/run_tests.py b/scripts/run_tests/run_tests.py index 6b7c0c1372bec..3d331333ce467 100644 --- a/scripts/run_tests/run_tests.py +++ b/scripts/run_tests/run_tests.py @@ -2,6 +2,7 @@ import os import sys from pymongo import MongoClient +from pymongo.errors import WriteError import requests import json import old_run_test_helpers as old_helpers @@ -105,7 +106,7 @@ def get_submodule_and_function_name(test_path, is_frontend_test=False): # pull gpu image for gpu testing if device == "gpu": - os.system("docker pull unifyai/multicuda:base_and_requirements") + os.system("docker pull unifyai/ivy:latest-gpu") # read the tests to be run with open("tests_to_run", "r") as f: @@ -151,7 +152,6 @@ def get_submodule_and_function_name(test_path, is_frontend_test=False): ) backend = backend.split("/")[0] + "\n" backend_version = backend_version.strip() - print("Running", command) else: device_str = "" @@ -159,7 +159,7 @@ def get_submodule_and_function_name(test_path, is_frontend_test=False): # gpu tests if device == "gpu": - image = "unifyai/multicuda:base_and_requirements" + image = "unifyai/ivy:latest-gpu" device_str = " --device=gpu:0" os.system( @@ -190,32 +190,35 @@ def get_submodule_and_function_name(test_path, is_frontend_test=False): frontend_version = None if coll[0] in ["numpy", "jax", "tensorflow", "torch", "paddle"]: frontend_version = "latest-stable" - if priority_flag: - print("Updating Priority DB") - old_helpers.update_individual_test_results( - old_db_priority[coll[0]], - coll[1], - submod, - backend, - test_fn, - res, - "latest-stable", - frontend_version, - device, - ) - else: - print(backend_version) - old_helpers.update_individual_test_results( - old_db[coll[0]], - coll[1], - submod, - backend, - test_fn, - res, - backend_version, - frontend_version, - device, - ) + try: + if priority_flag: + print("Updating Priority DB") + old_helpers.update_individual_test_results( + old_db_priority[coll[0]], + coll[1], + submod, + backend, + test_fn, + res, + "latest-stable", + frontend_version, + device, + ) + else: + print(backend_version) + old_helpers.update_individual_test_results( + old_db[coll[0]], + coll[1], + submod, + backend, + test_fn, + res, + backend_version, + frontend_version, + device, + ) + except WriteError: + print("Old DB Write Error") # skip updating db for instance methods as of now # run transpilation tests if the test passed @@ -223,16 +226,19 @@ def get_submodule_and_function_name(test_path, is_frontend_test=False): print(f"\n{'*' * 100}") print(f"{line[:-1]} --> transpilation tests") print(f"{'*' * 100}\n") - sys.stdout.flush() command = f"{command} --num-examples 5 --with-transpile" - os.system("docker cp test-container:/ivy/report.json .") + sys.stdout.flush() + os.system(command) + os.system( + "docker cp test-container:/ivy/report.json" + f" {__file__[: __file__.rfind(os.sep)]}/report.json" + ) # load data from report if generated report_path = os.path.join( __file__[: __file__.rfind(os.sep)], "report.json" ) report_content = {} - print(f"REPORT FILE FOUND : {os.path.exists(report_path)}") if os.path.exists(report_path): report_content = json.load(open(report_path)) @@ -283,8 +289,6 @@ def get_submodule_and_function_name(test_path, is_frontend_test=False): # populate the ci_dashboard db, skip instance methods if function_name: id = test_info.pop("_id") - print(f"ID : {id}") - print(f"TEST INFO : {test_info}") print( collection.update_one({"_id": id}, {"$set": test_info}, upsert=True) )