Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

start formatting #22827

Merged
merged 1 commit into from
Oct 3, 2023
Merged

start formatting #22827

merged 1 commit into from
Oct 3, 2023

Conversation

LMaterne
Copy link
Contributor

PR Description

Related Issue

Close #22826

Checklist

  • Did you add a function?
  • Did you add the tests?
  • Did you follow the steps we provided?

Socials:

@github-actions
Copy link
Contributor

Thanks for contributing to Ivy! 😊👏
Here are some of the important points from our Contributing Guidelines 📝:
1. Feel free to ignore the run_tests (1), run_tests (2), … jobs, and only look at the display_test_results job. 👀 It contains the following two sections:
- Combined Test Results: This shows the results of all the ivy tests that ran on the PR. ✔️
- New Failures Introduced: This lists the tests that are passing on main, but fail on the PR Fork. Please try to make sure that there are no such tests. 💪
2. The lint / Check formatting / check-formatting tests check for the formatting of your code. 📜 If it fails, please check the exact error message in the logs and fix the same. ⚠️🔧
3. Finally, the test-docstrings / run-docstring-tests check for the changes made in docstrings of the functions. This may be skipped, as well. 📚
Happy coding! 🎉👨‍💻

@LMaterne
Copy link
Contributor Author

LMaterne commented Aug 31, 2023

Reformatting Task Checklist

IMPORTANT NOTICE 🚨:

The Ivy Docs represent the ground truth for the task descriptions and this checklist should only be used as a supplementary item to aid with the review process.

LEGEND 🗺:

  • ❌ : Check item is not completed.
  • ✅ : Check item is ready for review.
  • 🆘 : Stuck/Doubting implementation (PR author should add comments explaining why).
  • ⏩ : Check is not applicable to function (skip).
  • 🆗 : Check item is already implemented and does not require any edits.

CHECKS 📑:

    • 🆗 :: Make sure that the aforementioned methods are added into the correct category-specific parent class, such as ivy.ArrayWithElementwise, ivy.ContainerWithManipulation etc.
    • 🆗 :: Add the correct Docstrings to every function and its relevant methods, including those you did not implement yourself. The following should be added:
        • 🆗 :: The function's Array API standard description in ivy/functional/elementwise.py. If the function is not part of the Array API standard then a description of similar style should be added to the same file.
          The following modifications should be made to the description:
          • ✅ : Remove type definitions in the Parameters and Returns sections.
          • ✅ : Add out to the Parameters section if function accepts an out argument.
          • ✅ : Replace out with ret in the Returns section.
    • ✅ : Add thorough Docstring Examples for every function and its relevant methods and ensure they pass the docstring tests.

      Functional Examples in ivy/functional/elementwise.py.

        • ✅ : Cover all possible variants for each of the arguments independently (not combinatorily).
        • ✅ : Vary the values and input shapes considerably between examples.
        • ✅ : Start out simple and get more complex with each example.
        • ✅ : Show an example with:
          • ✅ : out unused.
          • ✅ : out used to update a new array y.
          • ✅ : out used to inplace update the input array x (if x has the same dtype and shape as the return).
        • ✅ If broadcasting is relevant for the function, then show examples which highlight this.

      Nestable Function Examples in ivy/functional/elementwise.py.
      Only if the function supports nestable operations.

        • ✅ : Add an example that passes in an ivy.Container instance in place of one of the arguments.
        • ✅ : Add an example passes in ivy.Container instances for multiple arguments.

      Container Static Method Examples in ivy/container/elementwise.py.

        • ✅ : The example from point (6.f) should be replicated, but added to the ivy.Container static method docstring in with ivy.<func_name> replaced with ivy.Container.static_<func_name> in the example.
        • ✅ : The example from point (6.g) should be replicated, but added to the ivy.Container static method docstring, with ivy.<func_name> replaced with ivy.Container.static_<func_name> in the example.

      Array Instance Method Example in ivy/array/elementwise.py.

        • ✅ : Call this instance method of the ivy.Array class.

      Container Instance Method Example in ivy/container/elementwise.py.

        • ✅ : Call this instance method of the ivy.Container class.

      Array Operator Examples in ivy/array/array.py.

        • ✅ : Call the operator on two ivy.Array instances.
        • ✅ : Call the operator with an ivy.Array instance on the left and ivy.Container on the right.

      Array Reverse Operator Example in ivy/array/array.py.

        • ✅ : Call the operator with a Number on the left and an ivy.Array instance on the right.

      Container Operator Examples in ivy/container/container.py.

        • ✅ : Call the operator on two ivy.Container instances containing Number instances at the leaves.
        • ✅ : Call the operator on two ivy.Container instances containing ivy.Array instances at the leaves.
        • ✅ : Call the operator with an ivy.Container instance on the left and ivy.Array on the right.

      Container Reverse Operator Example in ivy/container/container.py.

        • ✅ : Following example in the ivy.Container.__radd__ docstring, with the operator called with a Number on the left and an ivy.Container instance on the right.

      Tests

        • ✅ : Docstring examples tests passing.
        • ✅ : Lint checks passing.

@ivy-leaves ivy-leaves added the Array API Conform to the Array API Standard, created by The Consortium for Python Data API Standards label Aug 31, 2023
@JPGoodale JPGoodale merged commit b4c4e99 into ivy-llc:main Oct 3, 2023
254 of 266 checks passed
druvdub pushed a commit to druvdub/ivy that referenced this pull request Oct 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Array API Conform to the Array API Standard, created by The Consortium for Python Data API Standards
Projects
None yet
Development

Successfully merging this pull request may close these issues.

inverse
4 participants